• Advertisement
Sign in to follow this  
  • entries
    22
  • comments
    28
  • views
    17273

Raytracing on SM3?

Sign in to follow this  

155 views

Just a quickie thought: Would it be feasible to do raytracing in the pixel shader in SM3.0? Like, render a fullscreen quad and basically run a raytracing program on each pixel like one would do on the CPU?
Sign in to follow this  


2 Comments


Recommended Comments

For simple raytracing? Sure is. I've written a shader which traces a ray from the camera to intersect with a sphere, calculate a reflection vector, and lookup in a reflection map. Per-pixel perfectly reflective spheres. The problem is really with things that reflect more than once...

Share this comment


Link to comment
Yeah, but that's still a reflection map. I'm talking about storing, in some constant registers, the entire scene (e.g. sphere of radius w at location xyz) and literally running a raytracing program on the pixel shader to get perfect reflections and all that.

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Advertisement