找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 2688|回复: 15

[贴图+更新]XE的SY灯和萌单某只的卡通渲染效果=.=

[复制链接]
发表于 2007-6-28 09:00:41 | 显示全部楼层 |阅读模式
3DGS中的效果。。。水银灯模型是某论坛模型区的强人做的。。萌单某人是模型网下的。。卡通渲染脚本是AUM的资源里面拿来的。。。唉唉。。。

PS,这角度真。。。[s:5]

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

×
发表于 2007-6-28 10:53:55 | 显示全部楼层
衣服很像....
发表于 2007-6-28 10:55:13 | 显示全部楼层
只看縮略圖還以爲是阿布臉的SY燈
发表于 2007-6-28 11:36:27 | 显示全部楼层
那个本来就是大阿布~~  [s:7]

对了… = =b 为什么3DS中的卡通渲染只有明暗没有阴影…… 最上火的地方……唉
发表于 2007-6-28 11:40:58 | 显示全部楼层
汞灯
发表于 2007-6-28 11:49:30 | 显示全部楼层
[s:5] 冷……………………
 楼主| 发表于 2007-6-28 13:22:48 | 显示全部楼层
material mtl_toon
{
    skin1=bmp_normalizationcube;
    skin2=bmp_toonlookup;
    event=mtl_toon_init;
    effect
    "
    texture entSkin1;
    texture mtlSkin1;
    texture mtlSkin2;
    matrix matWorldViewProj;
    matrix matWorld;
    vector vecSkill41;
    vector vecSunDir;

    technique toon
    {
        //-------------------------------paint
        pass p0
        {
            texture[0]=<mtlSkin1>;
            texture[1]=<mtlSkin2>;
            texture[2]=<entSkin1>;

            addressU[1]=clamp;

            magFilter[2]=linear;
            minFilter[2]=linear;
            mipFilter[2]=linear;

            vertexShaderConstant[0]=<matWorldViewProj>;
            vertexShaderConstant[4]=<matWorld>;

            vertexShaderConstant[16]=<vecSunDir>;

            vertexShader=
            asm
            {
                vs.1.1
                         dcl_position v0
                dcl_normal v3
                dcl_texcoord0 v7
                dcl_texcoord1 v8

                m4x4 oPos,v0,c0      // transform position to clip space
                m3x3 r0,v3,c4      // transform normal to world space
                dp3 r0.w,r0,r0      // renormalize it
                rsq r0.w,r0.w
                mul r0,r0,r0.w
                mov oT0.xyz,r0.xyz  // output normal to oT0
                mov oT1.xyz,-c16    // output light direction to oT1
                mov oT2.xy,v7.xy    // output uvs to oT2
            };
            pixelShader=
            asm
            {
                ps.1.3
                tex t0            // fetch normalized normal
                texdp3tex t1,t0_bx2 // light.normal=u -> use u to lookup in t1
                                                   // _bx2 -> 0..1 of normcube will be   -1..1
                 tex t2            // sample color map
                mul r0,t2,t1        // modulate with shading
            };
        }
        //--------------------------------------------ink
        pass p1
        {
            cullMode=cw;
            vertexShaderConstant[0]=<matWorldViewProj>;
            vertexShaderConstant[16]=<vecSkill41>; // outline_thickness, 0, 0, 0
            vertexShader=
            asm
            {
                vs.1.1
                dcl_position v0
                dcl_normal v3
                dcl_texcoord0 v7
                dcl_texcoord1 v8

                mov r0,v0
                mul r1,c16.x,v3          // scale normal
                add r0.xyz,r0.xyz,r1.xyz  // shell offset
                                                         //(vertex position + scaled normal)
                m4x4 oPos,r0,c0          // transform position to clip space
            };
            pixelShader=
            asm
            {
                ps.1.3
                def c0,0,0,0,1          // outline rgba
                 mov r0,c0
             };
         }
     }
    ";
}


毕竟是教程的脚本,代码还有待改进
 楼主| 发表于 2007-6-29 17:48:32 | 显示全部楼层
OMG,邪恶地更新了。。。。邪恶的卡通渲染啊。。。 [s:5]
发表于 2007-6-29 17:52:18 | 显示全部楼层
cg模型网..
是那里应该没有错
咱也有这个模型...
那里FF的model 很多...
发表于 2007-6-29 20:00:33 | 显示全部楼层
问:萌是什么?
答:萌就是LOLI魂
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|Archiver|幻想森林

GMT+8, 2026-10-31 21:05 , Processed in 0.011153 second(s), 17 queries .

Powered by Discuz! X3.5

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表