Realistic Silk material -Cycles

Here is my attempt at a realistic silk.
A bit of an odd node setup but it looks the best from the testing i did.

silk.blend (2.3 MB)

2 Likes

Generally speaking, you should not add the translucent shader, but rather mix it in.
Also I would use translucent on thin parts and sss on thick parts.
The aniso shading indicates a very unlikely woven. Woven fabrics (I believe) require two aniso shaders, one for each of the main direction the pattern generates visually (i.e. a 40degree rotation offset between the two, not sure what silk is again), driven by the UV tangents. Even if you don’t bother setting up the pattern itself.

Here is an OSL script I downloaded somewhere that is excellent for setting up a lot of wave patterns/masks, if you want to go that route. Look up what the silk pattern is and try to match it - I recently had tons of fun with it, although the real work begins once the pattern is done and saved:

/*
 * MAWeave.osl by Michel J. Anders (c)2012
 * from https://github.com/sambler/osl-shaders
 *
 * license: cc-by-sa
 *
 * original script from -
 * http://blenderthings.blogspot.com.au/2012/12/a-fabric-osl-shader-for-blender-cycles.html
 *
 */


// greatest common divisor
int gcd(int A, int B){
    int a=A, b=B;
    if (a == 0) { return b; }
    while (b != 0) {
        if (a > b) {
            a = a - b;
        } else {
            b = b - a;
        }
    }
    return a;
}

// smallest common multiple (assumes a, b > 0 )
int scm(int a, int b){ return a*b/gcd(a,b); }

shader MAweave(
        vector Vector = vector(0),
        color WarpColor = color(0.8,0,0),
        color WeftColor = color(0,0.8,0),
        int skip = 1,
        int underrun = 1,
        int overrun = 1,
        float WarpWidth = 0.8,
        float WeftWidth = 0.8,
        output color Color = 0,
        output int Index = 0,
        output float Dist = 0)
{
    int ny = underrun + overrun;
    int nx = scm(skip,ny);
    
    float x = mod(Vector[0],1.0);
    float y = mod(Vector[1],1.0);
    
    int ix = int(floor(x*nx));
    int iy = int(floor(y*ny));
    
    float cx = mod(x*nx,1.0);
    float cy = mod(y*ny,1.0);
    
    int top;
    top = ((iy+skip*ix)%ny) < overrun;
    
    float lx = (1-WarpWidth)/2;
    float hx = 1-lx;
    float ly = (1-WeftWidth)/2;
    float hy = 1-lx;
    
    if (top) {
        if ( cx > lx && cx < hx ){
            Index = 1;
            Color = WarpColor;
            Dist = abs(0.5-cx);
        } else if (cy > ly && cy < hy ){
            Index = 2;
            Color = WeftColor;
            Dist = abs(0.5-cy);
        }
    } else {
        if (cy > ly && cy < hy ){
            Index = 2;
            Color = WeftColor;
            Dist = abs(0.5-cy); 
        } else if ( cx > lx && cx < hx ){
            Index = 1;
            Color = WarpColor;
            Dist = abs(0.5-cx); 
        }
    }
}

That said, if it works for you and you’re happy with it, then just go for it.

see this post

happy cl

Thanks for the replies… Im attempting to make something like the example silk with the wave and noise texture, but using principled shader rather than just plain gloss mixed with the velvet. I think i was miles off with my original shader which looked more like pvc plastic of some kind.

Update here’s how to get a gorgeously smooth silk. Key point is look at my sheen and specular values… The mixing with velvet and Translucency are not so important and you might find other or simpler methods.

5 Likes

I tried to use this. But didn’t get the velvet shader in the shading area. Everything else worked. Thanks for the nice guide.

Velvet (plus Oren-Nayar diffuse and Anisotropic) are not supported by Eevee yet.

1 Like