代号小一

看不到子标题【表情】

导航

关于VR边纹理材质的渲染

前段时间经常渲染白模线框的图,写了这个脚本方便工作,后来又加了中英文适配,今天贴上来.

fn YY_edgestex =
(
    vr = renderers.current
    case of
    (
        (vr材质 != undefined) : (mat = vr材质())
        (vr_材质 != undefined) : (mat = vr_材质())
        (VRayMtl != undefined) : (mat = VRayMtl())
    )
    mat
    mat.diffuse = color 255 255 255
    case of
    (
        (VR边纹理 != undefined):(mat.texmap_diffuse = VR边纹理())
        (VR_边纹理 != undefined):(mat.texmap_diffuse = VR_边纹理())
        (VRayEdgesTex != undefined):(mat.texmap_diffuse = VRayEdgesTex())
    )
    mat.texmap_diffuse.pixelWidth = 0.5
    mat.texmap_diffuse.edgesColor = color 0 0 0
    vr.options_overrideMtl_on = true
    vr.options_overrideMtl_mtl = mat
)

 

posted on 2015-07-08 16:24  代号小一  阅读(1717)  评论(1编辑  收藏  举报