We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProcessing DevelopmentLibraries,  Tool Development › useful shading library
Page Index Toggle Pages: 1
useful shading library? (Read 1297 times)
useful shading library?
Jun 28th, 2007, 3:33pm
 
Hey Smiley

I've been playing with simple 'transformation-independent' depthshading and I'm wondering if it might be useful to anyone else.

A simply library can be found on http://klep.name/software/processing/depthshader/

Comments are welcome!

Regards,
Robert
Re: useful shading library?
Reply #1 - Jun 28th, 2007, 4:41pm
 
sounds nice, but i can't view the examples:
"(Unsupported major.minor version 49.0)"

i think you have to recompile the library for a lower target to let us pre-java-1.5-people view and use it.

F
Re: useful shading library?
Reply #2 - Jun 28th, 2007, 5:13pm
 
fjen wrote on Jun 28th, 2007, 4:41pm:
sounds nice, but i can't view the examples:
"(Unsupported major.minor version 49.0)"

i think you have to recompile the library for a lower target to let us pre-java-1.5-people view and use it.
F


I hope it's fixed now, apparently OSX defaults to 1.5 these days.

RK
Re: useful shading library?
Reply #3 - Jun 28th, 2007, 8:18pm
 
Yes, it works now for us pre-java-1.5-folk. I like it and it's straight forward to use.

Have you considered different falloff types besides linear
(inverse, inverse square etc.)?. To give a different look and feel. Fairly easy to add it myself, I know. Just thinking out loud. Smiley

Thanks.
Re: useful shading library?
Reply #4 - Jun 28th, 2007, 11:16pm
 
Right now, it's really just something I threw together, haven't even thought of implementing different methods of mapping the depth yet Smiley

Indeed it's quite easy to add yourself, but implementing it in the class itself (or perhaps in subclasses) would be quite nice!

Thanks for the idea, and I'll keep you posted on any updates.

Regards,
Robert
Re: useful shading library?
Reply #5 - Jun 29th, 2007, 4:18pm
 
You could consider making the falloff an interface so that people can implement their own depth mappings and replace the default one easily.
Re: useful shading library?
Reply #6 - Jun 29th, 2007, 9:39pm
 
I've put something together.

The demo now has five different mapping types, selectable with 1-5. The fourth mapping is just silly, but I've included it to show how a mapper can be constructed.

The demo is at http://klep.name/software/processing/depthshader/demo/
Check out the .pde there to see how to make your own mapper, I'm not even sure the ones I came up with are that useful.

RK
Re: useful shading library?
Reply #7 - Jul 6th, 2007, 9:53pm
 
The mappings interface makes it very useful indeed.

Thanks!
Bas
Page Index Toggle Pages: 1