PDA

View Full Version : shader preview


mas
12-26-2002, 01:57 PM
How do I make a preview of my own shader in which I will be able to see them in shader library? much like those that come with maya custom shader. Mine has no preview

Merry christmas

stunndman
12-26-2002, 11:08 PM
as far as i can see from the one's that have a preview they either have a corresponding jpg (xyz.ma <-> xyz.jpg) file in the same directory or a .swatch file in a subdirectory named .mayaSwatches

Jozvex
12-26-2002, 11:55 PM
Hi,

1.Create your shader

2.Create a preview object (default is just a sphere)

3.Apply shader to object

4.Render

5.Right click on the render and go to: 'View > Grab Swatch to Hypershade/Visor'

6.Drag a region around the render

7.Middle-mouse drag the render onto your shader in the Hypershade

That's it!

mas
12-27-2002, 05:53 PM
Hi Jozvex
This way it puts only a snapshot of the shader in the folder where you drag it. If you right click on it you can't import the shader, but just the snapshot. in Maya's custom shader library the shaders contain both the shader and preview as well.
I noticed the preview of the shader is in .mayaSwatches folder, which is a Swatch Image File format. Then the question is how can I make such file format?

Sibben
12-28-2002, 06:17 PM
I have done this but it was a while ago. It is an image in .iff format of a certain resoultion (32x32 or sumethin').

I don't beleive it's the .swatches file. It has some other extension. Check the shader library folders.

augustus
12-31-2002, 12:34 PM
Just use a jpeg file and chage its ext. to .swatch

sammokablamo
12-05-2004, 07:05 PM
I'm having a broblem when I want to use "Grab Swatch to Hypershade/Visor" and drag the swatch to items in the Character poses tab in the Visor. The custom icon shows up initially but when I save it and open it again; the swatch disappears. This is a technique used in Jae-jin Choi's character animation book as a means of having a nice preview icon of your facial poses when dragging them to the trax editor. I've searched all over the internet; google, alias' site, various forums, but haven't been able to find anything so if someone could help me out I'd be extremely grateful.

CGTalk Moderation
01-14-2006, 01:00 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.