简体   繁体   English

如何在 vpython 中旋转 object 轨迹?

[英]How to rotate a object trail in vpython?

I want to write a program to simulate 5-axis cnc gcode with vpython and I need to rotate trail of the object that's moving.我想编写一个程序来用 vpython 模拟 5 轴 cnc gcode,我需要旋转正在移动的 object 的轨迹。 Any idea how that can be done?知道怎么做吗?

It's difficult to know exactly what you need, but if instead of using "make_trail=True" simply create a curve object to which you append points.很难确切地知道您需要什么,但如果不使用“make_trail=True”,只需创建一条曲线 object,您 append 指向该曲线。 A curve object named "c" can be rotated using the usual way to rotate an object: c.rotate(.....).一条名为“c”的曲线 object 可以使用通常的方式旋转 object:c.rotate(.....)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM