Python 我的对象的透明度不是';t 2017年在玛雅工作

Python 我的对象的透明度不是';t 2017年在玛雅工作,python,maya,mel,Python,Maya,Mel,我正在使用Maya 2017。我可以为我的对象指定颜色。但问题是,我不能用透明度做任何事情 我的物体是一个球体,我把它涂成红色。然后我转到透明通道并选择一个棋盘格。我单击“棋盘格”,但视口中对象的透明度没有任何更改。即使我在键盘上按6 有人能帮我吗?退出Maya并重新打开它。在新场景中,将此MEL代码粘贴到脚本编辑器的输入字段,然后按执行蓝色按钮。这将创建一个新的polySphere,并为其指定Phong着色器。然后,只需使用alpha通道读取预乘RGBA纹理(以png格式),就像您在图片中看到

我正在使用Maya 2017。我可以为我的对象指定颜色。但问题是,我不能用透明度做任何事情

我的物体是一个球体,我把它涂成红色。然后我转到透明通道并选择一个棋盘格。我单击“棋盘格”,但视口中对象的透明度没有任何更改。即使我在键盘上按
6


有人能帮我吗?

退出Maya并重新打开它。在新场景中,将此MEL代码粘贴到
脚本编辑器的
输入字段
,然后按
执行
蓝色按钮。这将创建一个新的polySphere,并为其指定Phong着色器。然后,只需使用alpha通道读取预乘RGBA纹理(以
png
格式),就像您在图片中看到的那样。仅通过
Color
频道上传(
Transparency
将自动连接)

如果没有帮助,请尝试启用
传统默认视口
选项,而不是
Viewport 2.0


打开您的
首选项…
并在
显示部分下,将渲染引擎更改为
OpenGL-Legacy…
,然后重新启动Maya。

退出Maya并再次打开它。在新场景中,将此MEL代码粘贴到
脚本编辑器的
输入字段
,然后按
执行
蓝色按钮。这将创建一个新的polySphere,并为其指定Phong着色器。然后,只需使用alpha通道读取预乘RGBA纹理(以
png
格式),就像您在图片中看到的那样。仅通过
Color
频道上传(
Transparency
将自动连接)

如果没有帮助,请尝试启用
传统默认视口
选项,而不是
Viewport 2.0

打开您的
首选项…
并在
显示
部分下,将渲染引擎更改为
OpenGL-Legacy…
,然后重新启动Maya

polySphere -r 3 -sx 25 -sy 25 ;
shadingNode -asShader phong ;
sets -renderable true -noSurfaceShader true -empty -name phong1SG ;
connectAttr -f phong1.outColor phong1SG.surfaceShader ;
assignCreatedShader "phong" "" phong1 "pSphere1" ;
sets -e -forceElement phong1SG ;

defaultNavigation -createNew -destination "phong1.color" ;
createRenderNode -allWithTexturesUp "defaultNavigation -force true -connectToExisting -source %node -destination phong1.color" "" ;
defaultNavigation -defaultTraversal -destination "phong1.color" ;

shadingNode -asTexture -isColorManaged file ;
shadingNode -asUtility place2dTexture ;

connectAttr -f place2dTexture1.coverage file1.coverage ;
connectAttr -f place2dTexture1.translateFrame file1.translateFrame ;
connectAttr -f place2dTexture1.rotateFrame file1.rotateFrame ;
connectAttr -f place2dTexture1.mirrorU file1.mirrorU ;
connectAttr -f place2dTexture1.mirrorV file1.mirrorV ;
connectAttr -f place2dTexture1.stagger file1.stagger ;
connectAttr -f place2dTexture1.wrapU file1.wrapU ;
connectAttr -f place2dTexture1.wrapV file1.wrapV ;
connectAttr -f place2dTexture1.repeatUV file1.repeatUV ;
connectAttr -f place2dTexture1.offset file1.offset ;
connectAttr -f place2dTexture1.rotateUV file1.rotateUV ;
connectAttr -f place2dTexture1.noiseUV file1.noiseUV ;
connectAttr -f place2dTexture1.vertexUvOne file1.vertexUvOne ;
connectAttr -f place2dTexture1.vertexUvTwo file1.vertexUvTwo ;
connectAttr -f place2dTexture1.vertexUvThree file1.vertexUvThree ;
connectAttr -f place2dTexture1.vertexCameraOne file1.vertexCameraOne ;
connectAttr place2dTexture1.outUV file1.uv ;
connectAttr place2dTexture1.outUvFilterSize file1.uvFilterSize ;

defaultNavigation -force true -connectToExisting -source file1 -
destination phong1.color ;
window -e -vis false createRenderNodeWindow ;
connectAttr -force file1.outColor phong1.color ;