Jump to content


Help with Reflection cube maps on glass transparent surface.


4 replies to this topic

#1 Nicholas Christopher

    Member

  • Members
  • PipPip
  • 77 posts

Posted 15 July 2007 - 05:20 PM

My title says it all.

Trying to get Reflection cube maps to work on a transparent 'glass' like surface.

Anyone know of an example of this to help me find my errors, or to literally change my approach.

Having numerous issues, here are two of them:

I got the cube map extension working, and rendering it to a surface. 

The problem is when I rotate the camera, at a certain point the texture will flip, or change abruptly the way it is being projected onto the surface.


The other is the texture scale is constant to the camera. no matter how far

I move away from the surface the reflected result is the same. 



NC
Nicholas Christopher
Architecture software development, and modeling
http:\\www.arconovum.com

#2 Reedbeta

    DevMaster Staff

  • Administrators
  • 4782 posts
  • LocationBellevue, WA

Posted 15 July 2007 - 06:56 PM

I have a dynamic reflection/refraction demo in OpenGL on my website, but it's a little dated (uses pbuffers instead of framebuffer objects, and GLSL instead of Cg, I believe).
reedbeta.com - developer blog, OpenGL demos, and other projects

#3 gz0

    New Member

  • Members
  • Pip
  • 5 posts

Posted 16 July 2007 - 01:33 PM

Your demo is nice reed, on my computer the cube map textures are somewhat fubared though ;)

op, how are you setting your texture coordinates? Are you using shaders?

Here are some resources that might help:
http://www.ozone3d.n...xturing_p04.php
http://developer.nvi...l_tutorial.html
http://developer.nvi...re_Mapping.html

gl
;-)

#4 Reedbeta

    DevMaster Staff

  • Administrators
  • 4782 posts
  • LocationBellevue, WA

Posted 16 July 2007 - 04:43 PM

gz0 said:

on my computer the cube map textures are somewhat fubared though

Yeah, I've seen that problem too, the cube map textures aren't rendered but are full of randomish bits. Seems to happen with nVidia cards (I originally developed the demo on ATI). I guess I'm setting up the pbuffers wrong somehow. Anyway, I'm not too inclined to fix it, seeing as no one uses pbuffers anymore... :)
reedbeta.com - developer blog, OpenGL demos, and other projects

#5 Nicholas Christopher

    Member

  • Members
  • PipPip
  • 77 posts

Posted 17 July 2007 - 01:50 AM

thanks RB, gz0.

btw RB: "textures are somewhat fubared" same for me on my NV.


Quote

how are you setting your texture coordinates? Are you using shaders?

I assume this is aimed at me, and not RB. no shaders, and no coords either.

Most examples I have found let opengl deal with texture coords when using cubemaps.

btw: I have tried texture coords to no avail.
Nicholas Christopher
Architecture software development, and modeling
http:\\www.arconovum.com





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users