I would like to export a Tube
object with VertexColors
defined to 3DS format. Here's a minimum example:
test = Graphics3D[Tube[{{0, 0, 0}, {1, 1, 1}}, VertexColors -> {Red, Blue}]]
Export["test.3ds", test, "3DS"]
However, it appears that Tube
objects are only exportable if they lack the VertexColors
option, this seems to be true for all 3D formats. It seems to me that the simplest solution is to convert a graphic with Tube
objects into the GraphicsComplex
format, which does support VertexColors
upon export.
I'm guessing it might only be possible to use one of the old "extrude" solutions to this problem prior to the Tube
primitive existing. Is this the only way to do it? If so, how can VertexColors
be added to the extrusion methods of old? I'll note that the extrusion method produces 3D surfaces with far more polygons than Tube
does, and with weird vertex normals. This makes the exported objects unnecessarily large and kinda ugly.