"We offer new support options and therefor the forums are now in read-only mode! Please check out our Support Center for more information." - Vuforia Engine Team

Re sizing QCARSampleGLView

Hello, I want to resize the QCARSampleGLView(GLSurfaceView) and place it at any part of the screen eg vertical-center align. Please help me out. Thanks

This isn't a use case we test, but if you change the size and position of the view you'll need to update the configureVideoBackground method in native (e.g. ImageTargets.cpp). You can set the size and position of the VideoBackgroundConfig structure to match your new drawing rectangle.

rpandey91

Mon, 11/14/2011 - 07:15

Hi Kim, Thanks for your reply. I have changed the camera surface size by giving the height and width in the addContentView.

Try changing main.xml to use a RelativeLayout. Then you should be able to use gravity settings to center things. You'll have to play around with it, I haven't tried this. - Kim

rpandey91

Tue, 11/15/2011 - 13:50

Hi Kim, I have tried a lot, but there is no parent defined for mGlView. When i tried to find getLeft() of getRight(), it was showing 00. Still have no clue get it into the center. Rahul

Try getting this to work with a non-QCAR project first. Again, this isn't a use case we currently support. It should be possible, but I can't verify at this time. - Kim