Log in or register to post comments

Some questions..

October 28, 2010 - 1:19am #1

hi~ thank you for releasing your awesome SDK!!

I've tried to use it for several days. some questions for the SDK are here.

1. How can i use SDK for OpenGL 1.1?
-> For doing this, I tried to define USE_OPENGL_ES_1_1 in every cpp files in sample/Shared, sample/ImageTarget. but compile error was occured. i want to know how to use it for openGL 1.1.

2. camera errors..
-> i've modified the image target sample more simply. i got errors like below

10-28 07:23:11.436: DEBUG/QCARCore(21159): INFO: QCAR has been successfully initialized
10-28 07:23:11.436: DEBUG/QCARCore(21159): INFO: QCAR SDK version 0.9.7
10-28 07:23:11.465: DEBUG/ViewFlipper(375): updateRunning() mVisible=false, mStarted=true, mUserPresent=true, mRunning=false
10-28 07:23:11.475: DEBUG/QCAR(21159): InitQCARTask::onPostExecute: QCAR intitialization successful10-28 07:23:11.475: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_Shared_QCARSampleActivity_initApplicationNative
10-28 07:23:11.475: INFO/QCAR(21159): Using OpenGL ES 2.0
10-28 07:23:11.475: INFO/QCAR(21159): Using opaque GLView, depth buffer size: 16, stencil size: 0
10-28 07:23:11.475: DEBUG/QCARCore(21159): INFO: Tracker starts loading
10-28 07:23:11.535: DEBUG/QCARCore(21159): INFO: Tracker finished loading (no errors)
10-28 07:23:11.535: DEBUG/QCAR(21159): LoadTrackerTask::onPostExecute: execution successful
10-28 07:23:11.575: DEBUG/dalvikvm(21159): GC freed 893 objects / 67856 bytes in 42ms
10-28 07:23:11.585: ERROR/QCAR(21159): ===========APPSTATUS_INITED==========
10-28 07:23:11.585: DEBUG/dalvikvm(21159): +++ not scanning '/system/lib/libwebcore.so' for 'startCamera' (wrong CL)
10-28 07:23:11.585: DEBUG/dalvikvm(21159): +++ not scanning '/system/lib/libexif.so' for 'startCamera' (wrong CL)
10-28 07:23:11.585: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_Shared_QCARSampleActivity_startCamera
10-28 07:23:11.585: DEBUG/CameraService(52): CameraService::connect E (pid 21159, client 0x1e230)
10-28 07:23:11.585: DEBUG/CameraService(52): Client::Client E (pid 21159)
10-28 07:23:11.585: DEBUG/QualcommCameraHardware(52): createInstance: E
10-28 07:23:11.735: DEBUG/mm-camera(52): vfe_init, s->sensor.b_gain_init_bias = -0.250000
10-28 07:23:11.735: INFO/QualcommCameraHardware(52): startCamera: camsensor name s5k3e2fx, flash 1
10-28 07:23:11.735: INFO/QualcommCameraHardware(52): Set zoom=0
10-28 07:23:11.735: DEBUG/QualcommCameraHardware(52): createInstance: X created hardware=0x350d8
10-28 07:23:11.775: DEBUG/CameraService(52): Client::Client X (pid 21159)
10-28 07:23:11.775: DEBUG/CameraService(52): CameraService::connect X
10-28 07:23:11.785: DEBUG/CameraService(52): getParameters(antibanding=auto;antibanding-values=off,50hz,60hz,auto;effect=none;effect-values=none,mono,negative,solarize,sepia,posterize,whiteboard,blackboard,aqua;flash-mode=off;flash-mode-values=off,auto,on;focus-mode=auto;focus-mode-values=auto,infinity;jpeg-quality=100;jpeg-thumbnail-height=384;jpeg-thumbnail-quality=90;jpeg-thumbnail-width=512;max-zoom=5;picture-format=jpeg;picture-format-values=jpeg;picture-size=2048x1536;picture-size-values=2592x1944,2048x1536,1600x1200,1024x768,512x384;preview-format=yuv420sp;preview-format-values=yuv420sp;preview-frame-rate=15;preview-size=720x480;preview-size-values=1280x720,800x480,720x480,640x480,576x432,480x320,384x288,352x288,320x240,240x160,176x144;whitebalance=auto;whitebalance-values=auto,incandescent,fluorescent,daylight,cloudy-daylight;zoom=0;zoom-supported=true)
10-28 07:23:11.795: DEBUG/CameraService(52): setParameters(picture-size-values=2592x1944,2048x1536,1600x1200,1024x768,512x384;zoom=0;antibanding=auto;zoom-supported=true;whitebalance=auto;jpeg-thumbnail-height=384;jpeg-quality=100;preview-format-values=yuv420sp;jpeg-thumbnail-quality=90;focus-mode=auto;preview-format=yuv420sp;preview-size=480x320;picture-format-values=jpeg;flash-mode-values=off,auto,on;preview-frame-rate=26;flash-mode=off;effect-values=none,mono,negative,solarize,sepia,posterize,whiteboard,blackboard,aqua;focus-mode-values=auto,infinity;picture-size=2048x1536;max-zoom=5;effect=none;jpeg-thumbnail-width=512;whitebalance-values=auto,incandescent,fluorescent,daylight,cloudy-daylight;picture-format=jpeg;preview-size-values=1280x720,800x480,720x480,640x480,576x432,480x320,384x288,352x288,320x240,240x160,176x144;antibanding-values=off,50hz,60hz,auto)
10-28 07:23:11.795: INFO/QualcommCameraHardware(52): Set zoom=0
10-28 07:23:11.895: DEBUG/CameraService(52): startPreview (pid 21159)
10-28 07:23:11.895: DEBUG/CameraService(52): startCameraMode(0) (pid 21159)
10-28 07:23:11.895: DEBUG/CameraService(52): mSurface is not set yet.
10-28 07:23:11.895: DEBUG/CameraService(52): startPreviewMode (pid 21159)
10-28 07:23:11.895: INFO/QualcommCameraHardware(52): initPreview E: preview size=480x320
10-28 07:23:11.895: DEBUG/QualcommCameraHardware(52): mBufferSize=230400, mAlignedBufferSize=233472
10-28 07:23:11.916: DEBUG/QualcommCameraHardware(52): frame_thread E
10-28 07:23:12.040: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_Shared_QCARSampleActivity_startCamera success!!
10-28 07:23:12.075: DEBUG/Camera-JNI(21159): dataCallback(16, 0x1b1e00)
10-28 07:23:12.085: DEBUG/libEGL(21159): loaded /system/lib/egl/libGLES_android.so
10-28 07:23:12.095: DEBUG/libEGL(21159): loaded /system/lib/egl/libEGL_adreno200.so
10-28 07:23:12.105: DEBUG/libEGL(21159): loaded /system/lib/egl/libGLESv1_CM_adreno200.so
10-28 07:23:12.105: DEBUG/libEGL(21159): loaded /system/lib/egl/libGLESv2_adreno200.so
10-28 07:23:12.116: DEBUG/Camera-JNI(21159): dataCallback(16, 0x132fe8)
10-28 07:23:12.116: WARN/Camera-JNI(21159): Out of buffers, clearing callback!
10-28 07:23:12.116: INFO/QCAR(21159): Creating OpenGL ES 2.0 context
10-28 07:23:12.125: DEBUG/QCAR(21159): GLRenderer::onSurfaceCreated
10-28 07:23:12.125: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_Shared_QCARSampleRenderer_initRendering
10-28 07:23:12.125: DEBUG/QCAR(21159): GLRenderer::onSurfaceChanged
10-28 07:23:12.125: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_Shared_QCARSampleRenderer_updateRendering
10-28 07:23:12.125: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_ImageTargets_GLRenderer_renderFrame
10-28 07:23:12.125: DEBUG/QCAR(21159): Java_com_qualcomm_QCARSamples_ImageTargets_GLRenderer_renderFrame 1
10-28 07:23:12.245: INFO/DEBUG(20800): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
10-28 07:23:12.245: INFO/DEBUG(20800): Build fingerprint: 'google/passion/passion/mahimahi:2.1-update1/ERE36B/24827:user/release-keys'
10-28 07:23:12.245: INFO/DEBUG(20800): pid: 21159, tid: 21169 >>> com.infraware.AR.ARNavigation 10-28 07:23:12.245: INFO/DEBUG(20800): signal 11 (SIGSEGV), fault addr 00000000
10-28 07:23:12.245: INFO/DEBUG(20800): r0 00000000 r1 ffffffef r2 00000215 r3 00000163
10-28 07:23:12.245: INFO/DEBUG(20800): r4 00000000 r5 00000244 r6 00136610 r7 0041a450
10-28 07:23:12.245: INFO/DEBUG(20800): r8 0041a46c r9 42b72f5c 10 46714d6c fp 0010c2b8
10-28 07:23:12.245: INFO/DEBUG(20800): ip 80b056b8 sp 46714d10 lr 80a5b340 pc 00000000 cpsr 80000010
10-28 07:23:12.275: INFO/DEBUG(20800): #00 pc 00000000
10-28 07:23:12.275: INFO/DEBUG(20800): #01 pc 0005b33c /data/data/com.infraware.AR.ARNavigation/lib/libQCAR.so
10-28 07:23:12.275: INFO/DEBUG(20800): #02 pc 0005c1e8 /data/data/com.infraware.AR.ARNavigation/lib/libQCAR.so
10-28 07:23:12.275: INFO/DEBUG(20800): code around lr:
10-28 07:23:12.275: INFO/DEBUG(20800): 80a5b330 e08000c4 e08e10c1 e1a0e00f e59cf000
10-28 07:23:12.275: INFO/DEBUG(20800): 80a5b340 e8bd8070 000a9b94 00000244 e2400008
10-28 07:23:12.275: INFO/DEBUG(20800): 80a5b350 eaffffff e3a03001 e5c030d8 e12fff1e
10-28 07:23:12.275: INFO/DEBUG(20800): stack:
10-28 07:23:12.275: INFO/DEBUG(20800): 46714cd0 0041a454 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cd4 afd0090b /system/lib/libstdc++.so
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cd8 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cdc 80a766ac /data/data/com.infraware.AR.ARNavigation/lib/libQCAR.so
10-28 07:23:12.286: INFO/DEBUG(20800): 46714ce0 0041a3e8 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714ce4 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714ce8 0041a3e8 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cec 0041a454 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cf0 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cf4 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cf8 0041a46c [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714cfc 0041a46c [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d00 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d04 00000000
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d08 df002777
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d0c e3a070ad
10-28 07:23:12.286: INFO/DEBUG(20800): #01 46714d10 0041a3e8 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d14 46714d34
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d18 00136610 [heap]
10-28 07:23:12.286: INFO/DEBUG(20800): 46714d1c 80a5c1ec /data/data/com.infraware.AR.ARNavigation/lib/libQCAR.so
10-28 07:23:12.446: INFO/WindowManager(67): WIN DEATH: Window{447b9088 com.infraware.AR.ARNavigation/com.infraware.AR.ARNavigation.ARNavigationActivity paused=false}
10-28 07:23:12.446: INFO/ActivityManager(67): Process com.infraware.AR.ARNavigation (pid 21159) has died.

I think the pattern that i use for SDK is as same as image target sample. i don't know why it occured. The point app is dead is the function "QCAR::Renderer::getInstance().begin()"

renderFrame has nothing to do except for rendering::getinstance()::begin() and end().

please help

Re: Some questions..

October 28, 2010 - 6:34am #2

I can answer the first question now. The following flag is in the Android.mk file (located in the project's jni folder):

USE_OPENGL_ES_1_1 := false

Setting this to true will define USE_OPENGL_ES_1_1 and link against the correct OpenGL library. You also need to set the correct flag in the Java-side initialization, QCAR.GL_11 vs QCAR.GL_20. The ImageTargets project does this for you, by querying native for the OpenGL version.

I need to look into the second question further. In the meanwhile, could you possibly share some of your code changes that cause the error? Either here in the forum or mail it to

.

- Kim

Log in or register to post comments