void setup()
{
size(500,500,P3D);
}
void draw()
{
background(0);
translate(200, 200, 0);//坐标翻译,可以理解成立体平移
rotateX(mouseX);//旋转X轴
rotateY(mouseY);//旋转Y轴
box(100);//绘制一个立体的box
}
一个简单的代码,process2.21,winxp中,不能运行,显示错误为:
Could not run the sketch (Target VM failed to initialize).
For more information, read revisions.txt and Help → Troubleshooting.
/////
将size(500,500,P3D);
换成size(500,500);
能运行,显示错误为:
translate(), or this particular variation of it, is not available with this renderer.
rotateX() can only be used with a renderer that supports 3D, such as P3D or OPENGL.
问题再于系统不支持P3D,不知如何解决? |