Oren-Nayar-Blinn material model Blender version.
Moderators: jesterKing, stiv
I'm sorry if this is a stupid question, but I downloaded this file
http://hotlink.reblended.com/broken/tuh ... indows.zip
I installed it, and tried to find the new material settings, but I can't find them. Where exactly can you switch between phong, blinn and toon?
http://hotlink.reblended.com/broken/tuh ... indows.zip
I installed it, and tried to find the new material settings, but I can't find them. Where exactly can you switch between phong, blinn and toon?
That is because variables are re-used in the material data-structure:One thing I don't like much though: when you switch to blinn and then back to phong it doesn't restore your old phong settings (in particular, spec and hard have been modified).
(blinn)IOR=(phong)spec
(blinn)SpecRough=(phong)hard
and since the ranges are different in the different material models, they will get changed to fit those ranges when the material model is switched.
I could fix the problem by giving them completely different variables in the material data-structure, but that seems like a waste of space to me. Of course, if there is enough demand, I will change it anyway.

Besides, in the plugin system the parameters will be completely dynamic anyway, so it will be a moot point. The current modification is really just something to keep people occupied and happy while I work on the bigger project of mine: the material plugin system.
Why not just map the values through an (invertible) function thatcessen wrote:and since the ranges are different in the different material models, they will get changed to fit those ranges when the material model is switched.
maps the one range onto the other when changing shading models?
Then a quick switch between models would be less destructive.
I would say that unless the new shading paramaters control something
very similar to what the old ones do you should use new variables
(waste or not)... or create 3 whole new "sub-class-like" material structures
(one for each shading model), and a "super-class-like" material
structure with a void pointer that points to one of these 3 types.
(a bt harder, and a bit more drastic, but probably a better design
in the long run).
Chris
That's what I was originally going to do. At the moment, though, I can't figure out a good way to determine when the material model is switched. At the moment, it is setup as follows:Why not just map the values through an (invertible) function that
maps the one range onto the other when changing shading models?
Then a quick switch between models would be less destructive.
- 1) user selects material model
2) button usage causes refresh of the material buttons window
3) whenever there is a refresh, the material parameters are clipped according to the current material.
I am thinking of simply putting a variable into the material data-structure that indicates the material-model before the last refresh, and then on each refresh it would only do the mappings if it is not equal to the current material-model.
(And, of course, that would also give the neccessary information to reverse the mapping of the previous material. Perhaps there would be single intermediate mapping range of zero to one.)
Anyway, thanks very much for the feedback, Hos. It is very helpful!

Hey all!!
Cessen, look at this!
http://www.deathfall.com/article.php?sid=2081
yours and mine testrender !!
very cool =)
Do you have a very late Tuhopuu for Linux ?
Cessen, look at this!
http://www.deathfall.com/article.php?sid=2081
yours and mine testrender !!
very cool =)
Do you have a very late Tuhopuu for Linux ?
Could you post the results? I would absolutely *love* to see some scenes rendered with my material additions.kflich wrote:it took me minutes to replace my old cell shaded (using textures) scenes to new toon shading, and the results are excellent.

Wow, publicity!ztonzy wrote:Cessen, look at this!
http://www.deathfall.com/article.php?sid=2081
yours and mine testrender !!
very cool =)

That depends on what you mean by "very late". I have a build that's about a week old (so it's pretty recent):ztonzy wrote:Do you have a very late Tuhopuu for Linux ?
http://www.brunslo.com/cessen/blender_s ... mic.tar.gz
I suppose I should probably re-name the file to "tuhopuu_linux_dynamic.tar.gz" or something, but I'm too lazy to change it at the moment.

Well, I think it might be easier to do the other way I mentioned: especially for an arbitrary number of material models (as it will be with the plugin system).green wrote:You can have a function that executes every time a drop down list box (the phong, blinn, toon drop down button for example) gets used.
Ie the button has an event number that gets used where you can call a function from.
But I will keep it in mind as an alternate possibility if my idea doesn't work out. Or, perhaps, I will use it in combination with the other method.
Thanks for all of the feedback!

-
- Posts: 35
- Joined: Sun Dec 15, 2002 10:52 pm
I'm so looking forward to this finding its way into a stable release. I must say, I really think you're on the right track with the open shader thing. If the whole Blinn thing can be done so somehow the parameters translate into the standard renderers or Yafray seamlessly that would be brilliant, but one step at a time.
You're certainly giving me faith that Blender will develop in ever more useful ways now the source has opened, I was concerned no one would know what to do, but this has had me bouncing up and down with excitement!
I'm dead impressed. Keep it up.
You're certainly giving me faith that Blender will develop in ever more useful ways now the source has opened, I was concerned no one would know what to do, but this has had me bouncing up and down with excitement!
I'm dead impressed. Keep it up.
-
- Posts: 71
- Joined: Mon Oct 21, 2002 12:53 am
- Location: Bucks, England
A small bug, but great nonetheless
Wow, just downloaded the demo Tohupuu (I think that's how it's sopelt...) branch, and those new shading models are great!! Very good work Cessen.
One little bug I've found though - when using the Toon shader, even if you switch anti-aliasing on, you still get jaggies on the edge of toon shaded objects (to see what I mean, insert a light, a sphere, give the sphere a toon material, put OSA on - any value will do - and render). Is this to augment the toonish look of it, or is it jjust something that hasn't been implemented yet?
LethalSideParting
One little bug I've found though - when using the Toon shader, even if you switch anti-aliasing on, you still get jaggies on the edge of toon shaded objects (to see what I mean, insert a light, a sphere, give the sphere a toon material, put OSA on - any value will do - and render). Is this to augment the toonish look of it, or is it jjust something that hasn't been implemented yet?
LethalSideParting
-
- Posts: 442
- Joined: Wed Oct 23, 2002 2:47 pm