[visionegg] Re: Cube mapping?

Wow, that was quick :)

http://developer.nvidia.com/object/cube_map_ogl_tutorial.html

Yes, it's similar to a skybox, but instead of projecting an environment
to surround the scene, I'm trying to get the scene projected onto a
sphere.  I'm not even sure if it's going to work correctly, but I have
gotten some sample code working with pure PyOpenGL.

Here's what I'm working on, basically.  We're doing stimulus for
insects, and have a hemi-spherical rear projection screen with an off-
the-shelf LCD projector pointing at it.  The problem that I've run into
is that anything off-centre from the screen is distorted because of the
sphere.  What I am planning on doing is drawing the scene in 5 different
90 degree wide viewports (+X, -X, +Y, -Y, -Z), and then projecting these
onto an appropriately shaped object to correct for all of the
perspective distortion.  

I've got a feeling that it *might* take a bit of hacking of the
underlying VisionEgg code to do it, but I'm not too worried about
that.  

Hopefully I can get this implemented somewhat cleanly, so I can move
onto actually producing stimulus again :D.

Tony

On Fri, 2005-05-13 at 16:55 -0700, Andrew Straw wrote:
> Hi Tony,
> 
> I'm not sure what you mean by a "cube-mapped sphere" -- do you mean 
> something like a skybox?  (6 faces of a cube, each with their own 
> texture, drawn at infinity to simulate sky or other distant background?) 
>   I haven't implemented anything like that directly, although of course 
> it can be done with 6 TextureStimulus3D instances.
> 
> The cube dimension for texture objects is to support 3D texture maps... 
>     (I haven't really used them myself except a bit of testing when I 
> wrote that part.)
> 
> Cheers!
> Andrew
> 
> tony@xxxxxxxxx wrote:
> > Hi!
> > 
> > I'm doing some work with VisionEgg, and I was just starting to think about
> > implementing a cube-mapped sphere when I noticed that there was a
> > "dimension='cube'" option for the texture objects.  Am I missing something
> > crucial here (like, perhaps, that cube mapped spheres already exist and
> > I'm missing them...)?
> > 
> > I am relatively new to the whole VisionEgg package, and am still working
> > on getting a good, firm hold on the inheritance taxonomy and what each
> > object is actually responsible for.
> > 
> > Any suggestions would be greatly appreciated :)
> > 
> > Tony
> > 
> > ======================================
> > The Vision Egg mailing list
> > Archives: http://www.freelists.org/archives/visionegg
> > Website: http://www.visionegg.org/mailinglist.html
> 
> 
-- 
Tony Arkles <tony@xxxxxxxxx>

======================================
The Vision Egg mailing list
Archives: http://www.freelists.org/archives/visionegg
Website: http://www.visionegg.org/mailinglist.html

Other related posts: