Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Vuforia Videoplayback issue - Video is playing inverted

Im working on a project combining Vuforia ImageTarget and VideoPlayback. I have 'N' number of targets and it have corresponding videos . For some imageTargets the video is flipped. I can't find any solution for this issue. Here is my VideoPlaybackRenderer

int videoPlaybackTextureID[] = new int[VideoPlayback.NUM_TARGETS];

// Keyframe and icon rendering specific
private int keyframeShaderID = 0;
private int keyframeVertexHandle = 0;
private int keyframeNormalHandle = 0;
private int keyframeTexCoordHandle = 0;
private int keyframeMVPMatrixHandle = 0;
private int keyframeTexSampler2DHandle = 0;

// We cannot use the default texture coordinates of the quad since these
// will change depending on the video itself
private float videoQuadTextureCoords[] =  { 0.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f, 0.0f, 1.0f, };


private Float videoQuadTextureCoordsTransformed[] =  {0.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f, 0.0f, 1.0f,};


List<Float[]> videoQuadTextureCoordsTransformedList = new ArrayList<Float[]>();


// Trackable dimensions
Vec3F targetPositiveDimensions[] = new Vec3F[VideoPlayback.NUM_TARGETS];
like image 654
gStephin Avatar asked Apr 25 '17 04:04

gStephin


1 Answers

looks like you need to select the object video and then apply something like this: example you select a cube.

this will rotate the cube 180 degrees without modifying any of the other rotational axis'

cube.transform.rotation = new Quaternion(cube.transform.rotation.x, cube.transform.rotation.y, cube.transform.rotation.z, 180);
like image 194
Levi De Haan Avatar answered Oct 17 '22 22:10

Levi De Haan