ARToolKit | Mailing List Archive |
![]() |
From: | Brian Furtaw <brian@s ......> | Received: | Mar 14, 2001 |
To | FORUM ON AUGMENTED AND VIRTUAL REALITY <ARforum@l ..........> | ||
Subject: | Re: [ARforum] glCopyTexSubImage2D | ||
FORUM ON AUGMENTED AND VIRTUAL REALITY --------------------------- ListBot Sponsor -------------------------- Build a marketing database and send targeted HTML and text e-mail newsletters to your customers with List Builder. http://www.listbuilder.com ---------------------------------------------------------------------- Are you making sure the texture object you are trying to use is still bound? In other words, glBindTexture(GL_TEXTURE_2D, 100); /* define your framebuffer sourced texture */ glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT,0); You can now recall the texture object you just defined with glCopyTexImage2D. So before you try to use the subimage call call glBindTexture again like this, glBindTexture(GL_TEXTURE_2D, 100); glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); This will recall your texture object that you defined before. I picked the number 100 out of thin air it is actually more correct to call glGenTextures to create your texture object names. glGenTextures will make sure textures names do not conflict within the same graphics context. Brian Oliver Bimber wrote: > > FORUM ON AUGMENTED AND VIRTUAL REALITY > > --------------------------- ListBot Sponsor -------------------------- > Build a marketing database and send targeted HTML and text e-mail > newsletters > to your customers with List Builder. > http://www.listbuilder.com > ---------------------------------------------------------------------- > > brian, > > i use(d): > glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT,0); > and tried: > glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); > > but there's no texture in the texture memory...;-) > what's wrong with it? > both commands have almost the same parameters. the only difference is, that the > glCopyTexImage2D command allows to specify the internal > color format (GL_RGBA in my case) and the border flag (0 in my case). glCopyTexSubImage2D > has the xoffset and yoffset parameters (which i played around with and set them to 0,0 or > 1,1). > > glCopyTexImage2D works but glCopyTexSubImage2D doesn't. > what am i doing wrong? > > --oliver > > ______________________________________________________________________ > To unsubscribe, write to ARforum-unsubscribe@l .......... -- ----oOOo---- ----oOOo---- ----oOOo---- ----oOOo---- Brian Furtaw (brian@s ......) Graphics Guru Office:(301)572-3293 Fax: (603)250-0370 12200-G Plum Orchard Drive OpenGL/Performer/OpenInventor/ImageVision Silver Spring, Maryland 20904 Volumizer/Optimizer/React/PCI Device Drivers ______________________________________________________________________ To unsubscribe, write to ARforum-unsubscribe@l .......... |
From: | "Jason Jerald" <jjerald@h ......> | Received: | Mar 14, 2001 |
To | "FORUM ON AUGMENTED AND VIRTUAL REALITY" <ARforum@l ..........> | ||
Subject: | RE: [ARforum] glCopyTexSubImage2D | ||
FORUM ON AUGMENTED AND VIRTUAL REALITY --------------------------- ListBot Sponsor -------------------------- Build a marketing database and send targeted HTML and text e-mail newsletters to your customers with List Builder. http://www.listbuilder.com ---------------------------------------------------------------------- We have spent some time on the problem of getting 2d applications into a 3d world and the biggest problem was updating the framebuffer to texture memory in real time. Our solution was to use Sirius video (On an SGI Onyx) with several hacks including multi-processing, interleaved video multiple times, etc. The end result for is about 15 updates per second and some lag, but these updates are independent of the rest of the world (e.g. the rest of the world renders at its own fps). That is for a 720x486 source(into 1024x512 texture space) but the source can automatically be scaled in the sirius hardware from a higher resolution. We have done it with up to a 1600x1200 source at the same frame rate. Let me know if you want a copy of the paper. An alternative to grabbing the desktop is to use the xvbf. This would allow to render directly to memory instead of the display. Unfortunately there were some bugs at the time that would need to be fixed in order to do this. Not sure if those have been fixed since. Microsoft Task Gallery was using a modified version of Windows 2000 at the time to allow the framebuffer to be directly accessed. I dont think this made it into the final version of Win2000 though. Jason Jason Jerald Human-Centered Systems Department mailto:jjerald@h ...... Information Sciences Laboratory (310) 317-5622 HRL Laboratories http://home.earthlink.net/~jasonjerald > -----Original Message----- > From: Oliver Bimber [mailto:obimber@r .................] > Sent: Wednesday, March 14, 2001 8:06 AM > To: FORUM ON AUGMENTED AND VIRTUAL REALITY > Subject: Re: [ARforum] glCopyTexSubImage2D > > > FORUM ON AUGMENTED AND VIRTUAL REALITY > > --------------------------- ListBot Sponsor -------------------------- > Build a marketing database and send targeted HTML and text e-mail > newsletters > to your customers with List Builder. > http://www.listbuilder.com > ---------------------------------------------------------------------- > > brian, > sorry: my init function with the texture memory allocation did > not get called .... > it does work now. > but i don't get a noticeable speed-up. i measured the average > frame rate of both approaches. > they are the same. > --oliver > > > Brian Furtaw wrote: > > > FORUM ON AUGMENTED AND VIRTUAL REALITY > > > > --------------------------- ListBot Sponsor -------------------------- > > Build a marketing database and send targeted HTML and text e-mail > > newsletters > > to your customers with List Builder. > > http://www.listbuilder.com > > ---------------------------------------------------------------------- > > > > Are you making sure the texture object you are trying to use is still > > bound? In other words, > > > > glBindTexture(GL_TEXTURE_2D, 100); > > /* define your framebuffer sourced texture */ > > > glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE > _HEIGHT,0); > > > > You can now recall the texture object you just defined with > > glCopyTexImage2D. So before you try to use the subimage call call > > glBindTexture again like this, > > > > glBindTexture(GL_TEXTURE_2D, 100); > > > glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); > > > > This will recall your texture object that you defined before. I picked > > the number 100 out of thin air it is actually more correct to call > > glGenTextures to create your texture object names. glGenTextures will > > make sure textures names do not conflict within the same graphics > > context. > > > > Brian > > > > Oliver Bimber wrote: > > > > > > FORUM ON AUGMENTED AND VIRTUAL REALITY > > > > > > --------------------------- ListBot Sponsor -------------------------- > > > Build a marketing database and send targeted HTML and text e-mail > > > newsletters > > > to your customers with List Builder. > > > http://www.listbuilder.com > > > ---------------------------------------------------------------------- > > > > > > brian, > > > > > > i use(d): > > > > glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE > _HEIGHT,0); > > > and tried: > > > > glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); > > > > > > but there's no texture in the texture memory...;-) > > > what's wrong with it? > > > both commands have almost the same parameters. the only > difference is, that the > > > glCopyTexImage2D command allows to specify the internal > > > color format (GL_RGBA in my case) and the border flag (0 in > my case). glCopyTexSubImage2D > > > has the xoffset and yoffset parameters (which i played around > with and set them to 0,0 or > > > 1,1). > > > > > > glCopyTexImage2D works but glCopyTexSubImage2D doesn't. > > > what am i doing wrong? > > > > > > --oliver > > > > > > ______________________________________________________________________ > > > To unsubscribe, write to ARforum-unsubscribe@l .......... > > > > -- > > ----oOOo---- ----oOOo---- ----oOOo---- ----oOOo---- > > > > Brian Furtaw (brian@s ......) > > Graphics Guru Office:(301)572-3293 Fax: (603)250-0370 > > 12200-G Plum Orchard Drive OpenGL/Performer/OpenInventor/ImageVision > > Silver Spring, Maryland 20904 Volumizer/Optimizer/React/PCI Device > > Drivers > > > > ______________________________________________________________________ > > To unsubscribe, write to ARforum-unsubscribe@l .......... > > > ______________________________________________________________________ > To unsubscribe, write to ARforum-unsubscribe@l .......... > ______________________________________________________________________ To unsubscribe, write to ARforum-unsubscribe@l .......... |
From: | "Oliver Bimber" <obimber@r .................> | Received: | Mar 14, 2001 |
To | FORUM ON AUGMENTED AND VIRTUAL REALITY <ARforum@l ..........> | ||
Subject: | [ARforum] glCopyTexSubImage2D | ||
FORUM ON AUGMENTED AND VIRTUAL REALITY --------------------------- ListBot Sponsor -------------------------- Build a marketing database and send targeted HTML and text e-mail newsletters to your customers with List Builder. http://www.listbuilder.com ---------------------------------------------------------------------- brian, i use(d): glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT,0); and tried: glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); but there's no texture in the texture memory...;-) what's wrong with it? both commands have almost the same parameters. the only difference is, that the glCopyTexImage2D command allows to specify the internal color format (GL_RGBA in my case) and the border flag (0 in my case). glCopyTexSubImage2D has the xoffset and yoffset parameters (which i played around with and set them to 0,0 or 1,1). glCopyTexImage2D works but glCopyTexSubImage2D doesn't. what am i doing wrong? --oliver ______________________________________________________________________ To unsubscribe, write to ARforum-unsubscribe@l .......... |
From: | "Oliver Bimber" <obimber@r .................> | Received: | Mar 14, 2001 |
To | FORUM ON AUGMENTED AND VIRTUAL REALITY <ARforum@l ..........> | ||
Subject: | Re: [ARforum] glCopyTexSubImage2D | ||
FORUM ON AUGMENTED AND VIRTUAL REALITY --------------------------- ListBot Sponsor -------------------------- Build a marketing database and send targeted HTML and text e-mail newsletters to your customers with List Builder. http://www.listbuilder.com ---------------------------------------------------------------------- brian, sorry: my init function with the texture memory allocation did not get called .... it does work now. but i don't get a noticeable speed-up. i measured the average frame rate of both approaches. they are the same. --oliver Brian Furtaw wrote: > FORUM ON AUGMENTED AND VIRTUAL REALITY > > --------------------------- ListBot Sponsor -------------------------- > Build a marketing database and send targeted HTML and text e-mail > newsletters > to your customers with List Builder. > http://www.listbuilder.com > ---------------------------------------------------------------------- > > Are you making sure the texture object you are trying to use is still > bound? In other words, > > glBindTexture(GL_TEXTURE_2D, 100); > /* define your framebuffer sourced texture */ > glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT,0); > > You can now recall the texture object you just defined with > glCopyTexImage2D. So before you try to use the subimage call call > glBindTexture again like this, > > glBindTexture(GL_TEXTURE_2D, 100); > glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); > > This will recall your texture object that you defined before. I picked > the number 100 out of thin air it is actually more correct to call > glGenTextures to create your texture object names. glGenTextures will > make sure textures names do not conflict within the same graphics > context. > > Brian > > Oliver Bimber wrote: > > > > FORUM ON AUGMENTED AND VIRTUAL REALITY > > > > --------------------------- ListBot Sponsor -------------------------- > > Build a marketing database and send targeted HTML and text e-mail > > newsletters > > to your customers with List Builder. > > http://www.listbuilder.com > > ---------------------------------------------------------------------- > > > > brian, > > > > i use(d): > > glCopyTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT,0); > > and tried: > > glCopyTexSubImage2D(GL_TEXTURE_2D,0,0,0,0,0,TEXTURE_WIDTH,TEXTURE_HEIGHT); > > > > but there's no texture in the texture memory...;-) > > what's wrong with it? > > both commands have almost the same parameters. the only difference is, that the > > glCopyTexImage2D command allows to specify the internal > > color format (GL_RGBA in my case) and the border flag (0 in my case). glCopyTexSubImage2D > > has the xoffset and yoffset parameters (which i played around with and set them to 0,0 or > > 1,1). > > > > glCopyTexImage2D works but glCopyTexSubImage2D doesn't. > > what am i doing wrong? > > > > --oliver > > > > ______________________________________________________________________ > > To unsubscribe, write to ARforum-unsubscribe@l .......... > > -- > ----oOOo---- ----oOOo---- ----oOOo---- ----oOOo---- > > Brian Furtaw (brian@s ......) > Graphics Guru Office:(301)572-3293 Fax: (603)250-0370 > 12200-G Plum Orchard Drive OpenGL/Performer/OpenInventor/ImageVision > Silver Spring, Maryland 20904 Volumizer/Optimizer/React/PCI Device > Drivers > > ______________________________________________________________________ > To unsubscribe, write to ARforum-unsubscribe@l .......... ______________________________________________________________________ To unsubscribe, write to ARforum-unsubscribe@l .......... |