Skip to content

Instantly share code, notes, and snippets.

@freshNfunky
Created February 6, 2017 17:23
Show Gist options
  • Save freshNfunky/4e4b61664192fdddd8b84ceeaa5a6b65 to your computer and use it in GitHub Desktop.
Save freshNfunky/4e4b61664192fdddd8b84ceeaa5a6b65 to your computer and use it in GitHub Desktop.
TangoDeltaPoseController CameraOffset attempt
// line 341 in: private void _UpdateTransformationFromPose(TangoPoseData pose) :
m_colorCamOffs = Matrix4x4.TRS(m_camOffsetXf,m_camOffsetRot, Vector3.one);
Matrix4x4 cTuc = new Matrix4x4();
cTuc.SetColumn(0, new Vector4(1.0f, 0.0f, 0.0f, 0.0f));
cTuc.SetColumn(1, new Vector4(0.0f, -1.0f, 0.0f, 0.0f));
cTuc.SetColumn(2, new Vector4(0.0f, 0.0f, 1.0f, 0.0f));
cTuc.SetColumn(3, new Vector4(0.0f, 0.0f, 0.0f, 1.0f));
m_uwTuc = Matrix4x4.TRS(position, rotation, Vector3.one);
Matrix4x4 uwOffsetTuc = m_uwOffsetTuw * m_uwTuc * m_colorCamOffs * m_colorCamOffs * cTuc;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment