2D over 3D

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

2D over 3D

Postby JJ » Thu Nov 20, 2008 3:18 pm

Hi

I am porting an application based on the sdk 3.0, and I am having
countless problems...

now, I am struggling trying to put 2D graphics on top of a 3D scene...

After a lot of headache, I managed to create a opengl context, which
now works, but when I try to put 2D graphics on top of it, this is
what happens:

public void drawFrame(GL10 gl)
{
//view is a SurfaceView, and the value is not null !
mySurfaceHolder=view.getSurfaceHolder();

Canvas c=mySurfaceHolder.lockCanvas();

//this is where I wanted to place my 2D drawing, but
after the above line, this is
//what I got in the Log:
//11-20 12:52:02.508: ERROR/SurfaceComposerClient(490): eLocked set
when entering lock_layer(), //layer=1 (lcblk=0x410420a0),
state=00000020
//11-20 12:52:02.598: ERROR/SurfaceHolder(490): Exception locking
surface

mySurfaceHolder.unlockCanvasAndPost(c);

}

Any help would be very appreciated

Thanks!
JJ
Developer
Developer
 
Posts: 35
Joined: Tue May 13, 2008 1:18 pm

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 8 guests