Topic locked

ImageTargets Sample show dark screen

May 6, 2013 - 4:30pm #1

Hi,
I followed the Get Started tutorial.
ImageTargets sample build and deployed properly on my Android device (version 4.0.4).
But running its application shows dark screen for few second and back to 'start button' interface.
When I turn my device to look the printed target, I can see a teapot. but a background screen still dark.

something I miss in the tutorial??? Help please...

ImageTargets Sample show dark screen

May 29, 2013 - 11:25pm #13

Glad to help.

 

ImageTargets Sample show dark screen

May 29, 2013 - 2:23pm #12

AlessandroB wrote:

I mean "immediatly after"

in the default sample code, they are located outside the "for" loop, i.e. they are place after the "}" ..

Also, if you are using glDrawaArrays, put them immediatly after glDrawArrays (before the "}" )

 

IT'S WORKS..!!!!

Thank a lots Bro...

You save My time... :)

ImageTargets Sample show dark screen

May 28, 2013 - 10:30pm #11

I mean "immediatly after"

in the default sample code, they are located outside the "for" loop, i.e. they are place after the "}" ..

Also, if you are using glDrawaArrays, put them immediatly after glDrawArrays (before the "}" )

 

ImageTargets Sample show dark screen

May 28, 2013 - 3:06pm #10

Hi @AlessandroB,

I'm sorry I don't understand what do you mean of 'move those lines to right after the line of code "glDrawElements()"'.
cause I see that 3 line of glDisableVertex codes are came after glDrawElements() in imageTargets.cpp by default.

can you tell me clearly please.?

 

*I use glDrawArrays

ImageTargets Sample show dark screen

May 23, 2013 - 8:05am #9

Ok, so, if you take the Image Targets sample, look at the renderFrame() function in ImageTargets.cpp, you should see these lines:

 

glDisableVertexAttribArray(vertexHandle);
glDisableVertexAttribArray(normalHandle);
glDisableVertexAttribArray(textureCoordHandle);
 
could you move those lines to right after the line of code "glDrawElements()" ?
 

ImageTargets Sample show dark screen

May 22, 2013 - 5:32pm #8

Hi @AlessandroB,

After I checked my device with System Info Droid, Antutu Benchmark, end else, I know that My device support OpenGl ES 2.0.

But, Why I get above problem when I set USE_OPENGL_ES_1_1 to 'false'?

Here is my device spesification :

[img]http://s14.postimg.org/5pp91qq35/Adv_S5v5.png[/img]

and I think, the problem show in log cat here :

[img]http://s13.postimg.org/6thn2izcn/error.png[/img]

What should I do to solve the problem.?

 

ImageTargets Sample show dark screen

May 8, 2013 - 5:10am #7

thanks sanylop22,

the trick you mention works in Unity; I think Mobiro is programming natively in Android.

But thanks for sharing.

 

ImageTargets Sample show dark screen

May 8, 2013 - 5:10am #6

Hi @sanylop22, I can't find Build setting in File tab in Eclipse.

Where File do you mean?

ImageTargets Sample show dark screen

May 8, 2013 - 4:57am #5

The problem is 24bit or 32bit (buffer)

Go to File->Build Settings -> Android ->Player Settings -> Use 24bit

That solve my problem! 

ImageTargets Sample show dark screen

May 7, 2013 - 11:51pm #4

Ok, glad to hear it is solved.

ImageTargets Sample show dark screen

May 7, 2013 - 5:22pm #3

Hi @Alessandro,

I'm sorry, I'm not make that little test yet.

ImageTargets running well on my device now, after I set USE_OPENGL_ES_1_1 to true.

Thanks for your advice

ImageTargets Sample show dark screen

May 6, 2013 - 11:22pm #2

Hi, can you make this little test:

  • uninstall the App from your device
  • disable Internet connection (disable Wifi and any network connection)
  • Reinstall the App
  • Run 

Do you still see the same result after doing this ?

 

Topic locked