The library was born to evercome this problem and to let the user quickly setup an entire "look" for a character and then quickly save it
and load it.
The library is written to handle simple shaders, but the design is toght keeping flexibility in mind, the result is a nice and flexible library which is easy to expand and implement new features.
Here you can find the documentation:
https://giordi91.github.io/
and here the source code :
https://github.com/giordi91/animShader
Here a code example:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
from shaders import shader_lambert from shaders import shader_blinn #declare a shader lamb = shader_lambert.Lambert("test") lamb.translucenceDepth = 0 bl = shader_blinn.Blinn() lamb.color = [1,0,0] lamb.color = "C:/Users/Marco/Desktop/perlinNoise.png" lamb.color = "C:/Users/Marco/Desktop/checker.jpg" lamb.transparency = [0.5,0.5,0.5] lamb.save() lamb.translucenceDepth = 2 lamb.name = "LOL" #declare a matcher from matcher import shader_set_matcher from matcher import shader_wild_card_matcher m1 = shader_set_matcher.Set_matcher("cubes") m2 = shader_wild_card_matcher.Wild_card_matcher("*Cube?") m2.get_meshes() #declare a look from shader_look import look l = look.Look() l.add_sublook([m1,m2],lamb) l.apply_look() #save the look l.save() #load the look l.load("path_to_the_look_file") |
This is an open source project.
Means that every feedback and comment will help make the library better.
Of course and code help is most welcome aswell.
Cheers
M.
PS:
Tested in Maya 2014 both windows and linux.
Should be compatible with all other maya version and os
Please use the Feature Requests to give me ideas.
Please use the Support Forum if you have any questions or problems.
Please rate and review in the Review section.