Hello, Maybe in the RegisterViewPortCallBack you can set the siDisplayCallback to siPreEndFrame or siEndFrame so it is drawn after all other elements in the scene
Hope it helps ben From: [email protected] Date: Fri, 12 Apr 2013 10:21:32 +0800 Subject: Re: needing help with writing a custom display callbacks To: [email protected] Thanks Nicolas for the prompt reply. I tried disabling depth testing, lighting and cull face but it still draws behind the 3D object. I know swapping buffers is not allowed since Softimage closes itself after that. --Angeline TanJunior TD One Animation On 12 April 2013 00:35, Nicolas Burtnyk <[email protected]> wrote: Hi Angeline, You can try disabling depth testing before drawing your 2d stuff, using glDisable(GL_DEPTH_TEST). -Nicolas On Thu, Apr 11, 2013 at 3:16 AM, Angeline <[email protected]> wrote: Hi everyone, I've been working on display callbacks and am having some trouble. I am trying to display some information for the animators at One Animation. >From my understanding of opengl render sequence, 3D objects are render before >2D displays: // drawing 3D world push GL_PROJECTIONloadIdentityset ortho push GL_MODELVIEWloadIdentity clear color and depth buffer // draw 2D information pop GL_MODELVIEW pop GL_PROJECTION I placed my 2D drawing codes in the function below based off the Sample Display Callback example from the Softimage SDK. void MyClearScreenBuffer_Execute ( XSI::CRef, LPVOID * ); The problem I'm facing is that the 2D information is drawing behind the 3D objects. Thanks Angeline Junior TD One Animation -- Angeline Tan Junior TDOne Animation

