By Stevan
on Fri, 03/01/2013 - 23:51
Hi, a bit of a newbie to Vuforia. I have just downloaded and installed the Vuforia SDK 2.0.31 with Eclipse under Win7. I am able to run the sample "ImageTargets", but am unable to change to the front-facing camera. I am testing on an Asus Transformer TF300T btw. I have tried changing to "QCAR::CameraDevice::CAMERA camera = QCAR::CameraDevice::CAMERA_FRONT;" under ImageTargets.cpp but to no avail.
I was just wondering whether I was missing something: whether I need to amend another piece of code, add some code to the java class, or maybe it's a known problem with Asus TF300T tablets or TEgra 3 chips?
Any help would be very much appreciated.
How to use front-facing camera under Vuforia SDK 2.0.31
Hi, you also need to initialize the camera with the desired parameter:
in ImageTarget.cpp you should find a line of code like:
QCAR::CameraDevice::init ( )
you should adjust it to:
How to use front-facing camera under Vuforia SDK 2.0.31
Hi AlessandroB, thanks for getting back to me so quickly.
Looks like from the sample code, the camera is initialised on the next line:
How to use front-facing camera under Vuforia SDK 2.0.31
Hi, your camera initialization code is actually correct, i.e. this is the correct code to enable the front camera:
JNIEXPORT void JNICALL
How to use front-facing camera under Vuforia SDK 2.0.31
Hi AlessandroB, tried again but no luck. Managed to build and test with FrameMarkers sample but still accessing default back camera. Guess it must be a device issue.
How to use front-facing camera under Vuforia SDK 2.0.31
Hi, running ndk-build from cygwin is just the perfect procedure, so no problem with that;
How to use front-facing camera under Vuforia SDK 2.0.31
Hi Alessandro, here are the device details:
Hope this helps. Let me know if you need any further details.
How to use front-facing camera under Vuforia SDK 2.0.31
Ok, thanks, I will bring it up to our team for investigation. I'll keep you updated.