考虑以下因素:
cAxes = {{{0, 0, 0}, {0, 0, 1}}, {{0, 0, 0}, {0, 1, 0}}, {{0, 0,0}, {1, 0, 0}}};
Graphics3D[{Line /@ cAxes}, Boxed -> False]
这 3 条线的样式如何不同?
最佳答案
上面的答案很好,但我想展示一些替代方案。
我证明可以使用 Style
来实现此目的,并且 Tube
是 Line
的一个有趣的替代方案。
cAxes = {{{0, 0, 0}, {0, 0, 1}}, {{0, 0, 0}, {0, 1, 0}}, {{0, 0,
0}, {1, 0, 0}}};
tubes = Tube@# ~Style~ #2 & ~MapThread~ {cAxes, {Red, Green, Blue}};
Graphics3D[tubes, Boxed -> False]
关于graphics - 在 Mathematica 中使用 Graphics3D 的线条样式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8115641/