By AugmentedTech
on Thu, 11/07/2013 - 11:22
Hi.
I ahve been using Vuforia for a month or so and have found it great on a few phones, but recently started testing on two three tablets.
On a Nexus 7 it is fine, but on a Galaxy Note and Sony Tablet S the video size returned from
cameraDevice.getVideoMode(QCAR::CameraDevice::MODE_DEFAULT);
is 0,0 within configureVideoBackground, therefore several things downstream fail.
I've tried using the following code
QCAR::State state = QCAR::Renderer::getInstance().begin(); QCAR::Frame frame = state.getFrame(); const QCAR::Image image = frame.getImage( 0 ); int videoWidth = image->getWidth(); int videoHeight = image->getHeight();
as suggested in another post but I'm getting a compilation error.
Thanks.
cameraDevice.getVideoMode returning 0,0
Hi, are you using that code in a special way ?
are the samples working on Nexus 7 and Sony Tablet S ?
cameraDevice.getVideoMode returning 0,0
I don't believe it is used in a special way; the only exception is that I'm getting the FOC from QCAR and returning it to Java for use in the renderer.
I've just tried the ImageTargetsBuilder sample and it also crashed; The logcat output is;
cameraDevice.getVideoMode returning 0,0
The samples invoke the configureVideoBackground() function in the startCamera (which is called when the App is resumed) and in the updateRendering() which is called when the screen changes.
Do the original samples show the correct behaviour and values (without code modifications) ?
cameraDevice.getVideoMode returning 0,0
Unfortunately not. An unmolested ImageTargets produces the below logcat for 'QCAR';
cameraDevice.getVideoMode returning 0,0
Thanks for doing this test;
so when you run the unmodified Image Targets sample you get (0,0).. what do you observe on screen ? do you see a black screen or similar issue ?
cameraDevice.getVideoMode returning 0,0
Yes...
Either the black screen persists and the application stays open, or it crashes after further initilisation steps.
cameraDevice.getVideoMode returning 0,0
Thanks for the info;
could you also provide these info:
- exact Device Model number (ideally for both the the Sony and the Galaxy Note); you can find the Model number in the Device Settings (usually under "About Phone" or similar)
cameraDevice.getVideoMode returning 0,0
Hi
The Sony is 'Sony Talbet S', build TISU0033410, Android 4.0.3, OpenGL ES 2.0 14.01002
Samsung Galaxy Note 10.1 (GT-N8000)- Android 4.1.2
Nexus 7 – Android 4.3
cameraDevice.getVideoMode returning 0,0
Thanks for the info:
the message:
cameraDevice.getVideoMode returning 0,0
Okay, have just re-imported the ImageTargets sample to Eclipse, run it and am now getting a video size!
It appears that something in the programme flow is messing with the initilisation then - I apologise for the miss-direction.
cameraDevice.getVideoMode returning 0,0
Glad to hear that the issue is solved.
I'm not sure of what in your code may have broken this functionality, perhaps a threading issue.