Jump to content

GI in VOPs?


stu

Recommended Posts

Hi all. Long time lurker, first time poster.

Has anyone taken a crack at doing some sort of hybrid GI shader using VOPs that properly handles diffuse intereflection? I'm growing impatient waiting for prman 11. :D

stu

Link to comment
Share on other sites

  • Replies 75
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Hey, longtime lurker :P ...

I take it you missed the thread about the radiant shader that's shown on the main odforce page.....

the thread is in "general chat" under radiosity render..

cheers...

re-majorkudos for anonymous....what a painfully generic name! :D

hope they didn't pick on him at school.....

Link to comment
Share on other sites

Hi sirogi,

Yeah, I had a look at that - really cool stuff. It's basically just making everything reflective and scattering (back off Pixar) the rays and as a result the shader reacts unexpectedly when affected by direct lighting.

stu

Link to comment
Share on other sites

true, it is a first stab at the subject, but nothing prevents it from being spiced up with more niceties, like the focus of the scattered reflection, or even iterating past the first level rays to get a more accurate spill...

or even modulate the contribution bu thet lighting model color...I see a lot of (*slow*) possibilities...

soo may ways to make your renders LAAaast! :P

just thought it could be a good starting point...

Link to comment
Share on other sites

It's a great starting point, and addresses what I think is the single most glaring omission within the VEX rendering world - an in the box GI renderer. As soon as I heard about VOPs, the GI possibilites were the first things that occured to me. That and ambient occlusion. :D

I wonder if this shader's approach could be applied to a subsurface scattering paradigm?

stu

Link to comment
Share on other sites

Hi there,

I have taken sirogi's VOPnet adaptation of the Radiant shader and created a VOP type from it.

Take a look at it.

To install it, just download and in Houdini go to File>Install Op Type.. and then a new Radiance VOP should appear! Enjoy!

Who's gonna attempt Ambient Occlusion? It's not too difficult... A guy at D2 did it for renderman recently (but I can't post it, of course)

VOP_radiance.optype

Link to comment
Share on other sites

hey Jason, thanks a bunch for your post! :)

I kept working on it and drove myself crazy, or sick...or both....anyways, I figured I"d post some of the pics I got with it...I meant to practice and separte the passes to give more flexibility during the compositing phase: it worked!!! almost drove me nuts, there are too many ways to combine those suckers, all of the...err.."interesting" ;)

tell me what you think....

PS: just for fun, I added a "focus" parameter to the random function that scatters "N", and an overall mixing control between "straight" lambert shading and the reflective "trick"....the stuff you can do with this thing!

...so you can go from REALLY diffuse to sharp reflections...think about texturemapping the channel to simulate varying degrees of wear and tear to the surface....

err...sorry...was talking to myself...

CHeers!!

PS: nevermind the black balls, didn't take care of those...

PPS: yes, the Lambert shading pass (the one before last) shouldn't have colors :)

post-9-1034982745.jpg

Link to comment
Share on other sites

Good stuff, sirogi!

Yeah, I also set up a render that broke the components up into separate layers as well (specular reflection, direct shadows, etc.) It works fairly well (obviously sirogi!).

Thanks for the tip on the shader that handles ambient occlusion. I noticed that it works in a similar way to the radiant shader.

I'd like to see one that works the way the ILM guys describe the process in the 2002 siggraph notes, by basically projecting along the normal to see if there is a nearby surface and generating a map based on that information (The parts of the model that turn up positive for a collision with a nearby normal are black on the generated map. ie. they don't receive as much ambient light).

Has anyone tried this with VOPs yet?

stu

Link to comment
Share on other sites

When I install sirogi's new VOP type (Thank you!!!) and just pump it through a Surface VOP by plugging its _diff output into the Cf of Output 1, the surface doesn't pick up any scattered (nondirect) light. What part of the process am I missing?

Also, when I just unzip his .hip file and do a render, I get a very dark image (presumably, once again, becasue the surfaces aren't receiving bounced rays).

Ideas?

stu

Link to comment
Share on other sites

just pump it through a Surface VOP by plugging its _diff output into the Cf of Output 1, the surface doesn't pick up any scattered (nondirect) light. What part of the process am I missing?

oookay...here's where the cheating begins....when you use that VOP (just like using the radiant shader or chang's implementation...) your lights are actually objects to whom you assign constant Shaders! in the scene file I-well...that Chang made, really :) - you'll see a phantomed "Dome_env" object...that's what's responsible for lighting the scene....you also have a few other options in a flat plane lighting (area light) or the curve shown in the radiant example...

:) either that or you need to go into the optype and toggle the condition of the "if" VOP (if it's true, set it to false, and vice versa....)

so, bottom line, make sure you have some sort of constant shaded object that casts the "light"....(you can assign to them constant colored texmaps for added fun...)

Also, when I just unzip his .hip file and do a render, I get a very dark image (presumably, once again, becasue the surfaces aren't receiving bounced rays).

aha! "do a render"....errr....as for rendering directly from the hipfile...it's kinda tricky....if you look in ROPs, all the separate passes I posted were mantra renders with pre and post scripts to set the shaders on the objects, and turn shadow generation on and off...kinda hacked, for testing purposes, not really a turnkey solution.....

so all the passes you saw are not part of one shader, but rather different setups using the same shader, because I have yet to decide of a good compositing algorithm to merge them all in one definitive shader (combining the lambertian and the bounce is kinda tricky...not to mention the shadows behave differently....)

so be really careful with which output driver (ROP) you're rendering....the whole thing is pretty much still R&D (read: mucking around)...

unfortunately, the houdini setup we have at school broke again (cannot recognize the basic nodes I used to make the VOPS etc...)....so all I had was that one day to make the whole thing, can't even go back and tweak or finalize it!....

and just to be on the safe side, I actually kept playing around with the file after I gave it to Jason, so why don't you try the new attachment and tell me if that works... (assume the whole blurb above related to THIS current attachment)

please tell me how it goes...

cheers!

radiantsmpl12b.zip

Link to comment
Share on other sites

What's intereresting is that I'm finding that objects will either spill colour or receive it at render time, but not both.

Example: in the first file, the phong shaded spheres didn't catch any bounce light (obviously) but threw lots of colour onto the radiant objects, and the objects that had the radiant shader applied to them caught lots of bounce colour, but didn't spill any colour (green cube onto ground, eg.)

stu

Link to comment
Share on other sites

he he he...yup.... ;)

I saw that too while making the initial tests.....

but you'll also notice in the third of the image sequence (the spill pass), that it got fixed and you'll see some red and green spill on the white center sphere from its neighbours....but the render scripts take care of assigning the right materials with the right shaders for that to happen...again...it was more of a case of saying:"ok, it can be done" rather than the definitive answer....it'll be a while...

Link to comment
Share on other sites

I think that's about the last hurdle that you have to overcome in regards to the bounce stuff (texture maps, spec hits, etc. are gravy). Yay!!!

Great stuff sirogi, keep it up!!!

ps. It'd be nice if sesi had a system up and running out of the box - the fact that VEX is a natural raytracer is just begging for this.

Link to comment
Share on other sites

was playing with texturemapping the environment dome....and ...well...see for yourself....

guess now would be a good time to get into HDRI...or at least fake some...I'm thinking that maybe COPS2 can output floating point images...

now where did I put those chrome balls... :)

hmmm....notice how much more vibrant those small balls are?....guess it has to do with the way we sample all objects equally with the same way regadless.......any ideas for adaptative sampling guys? :)

(....without making it slower..pls pls pls!)

post-9-1035358409.jpg

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...