[OpenSCAD] Semantics CSG ops with respect to color, materials

doug moen doug at moens.org
Thu May 21 10:46:57 EDT 2015


Yes, these are all issues that need to be dealt with at some point in the
3D printer toolchain. However, unless we are inventing a new 3D model file
format, we only worry about supporting features that are present in popular
3D model file formats that we currently export or would like to export in
the future.

You talk about different color spaces (RGB vs CMYK for example), but I
think we are too high up in the toolchain to worry about this. The only
color space supported by AMF is sRGB, which is the standard RGB colour
space that everybody in the computer industry uses. Are there any popular
3D model file formats that support anything other than sRGB? I haven't
found that, but maybe someone else has deeper insight.

Multi-material 3D printers have the potential ability to build objects out
of composite materials that are created on the fly by alternating between
different materials at the sub-millimeter scale, or by fusing together
different materials in varying ratios. And that's fascinating, but what
toolchains exist that let you do this? AMF has some features for supporting
this, but are there any slicers that support these features of AMF? If
there are, then we have a target that we can work towards. If not, then it
might be premature for us to design language features that can't be used by
any toolchain.

Shapeways has designed the SVX voxel file format that supports multiple
materials and RGB colours. It looks like it supports fine grained
composites and objects with fine grained structure. This is a real
toolchain that we could consider supporting. The types of models that would
benefit from this format have huge numbers of triangles, and I wonder if
the OpenSCAD geometry engine is up to the task of creating the necessary
meshes in the first place. To quote Shapeways, *"One promise of 3D printing
is that complexity is free. Sadly with STL files we’ve had the disconnect
that more complexity equals more triangles equals larger files. Above a
certain limit you just can’t use triangles to specify the details you want
in a 3D printed model."*

The Shapeways quote suggests that OpenSCAD needs to move beyond triangular
meshes in order to fully support complex 3D printed models with fine
grained structure. For example, we could support a hybrid system where
coarse grained features are specified by solids, represented by meshes, as
today, but fine grained features are specified "procedurally" by continuous
functions that map (x,y,z) onto materials. OpenSCAD could export this kind
of model to SVX by using an internal slicing engine.

If we use this approach, then we'll have an operation that attaches a
material function to a solid. Then we are left with the problem of
generalizing the CSG operations so that union, intersection, etc of solids
with attached material functions does something predictable, which is not
that different from Bob's original goal at the start of this thread.

As before, I am not sure that the way forward involves defining CSG
operations on colours and materials. What is the union of red and blue? Is
it different from the intersection of red and blue? What is the
intersection of PLA and Ninjaflex? I don't see how these questions make
sense, or that a system that gave answers would be useful. So I would be
happy with a simple CSG implementation that sidesteps these issues, as I
suggested earlier.

On 21 May 2015 at 01:33, MichaelAtOz <oz.at.michael at gmail.com> wrote:

> Focusing on Volumes would support FFF/FDM where multiple nozzles are used
> for
> multi colour/material where each volume represents one material/colour and
> hence any 'bit' of space is one or the other. However, and I'm sure I'm not
> telling you how to suck eggs, it is more complicated.
>
> There are however multiple material/colour extruders  (1)
> <
> http://richrap.blogspot.com/2012/08/3-way-quick-fit-extruder-and-colour.html
> >
> (2) <http://reprap.org/wiki/Diamond_Hotend>   with a single mixing nozzle
> where the properties of a particular 'bit' of space is some combination of
> materials/colours based (in one simplistic way) as a ratio of the inputs,
> but could presumably be expressed in many ways. (I think Don's blog was
> written before these became more available).
>
> Other technology has a white powder base and then uses an ink-jet printer
> to
> colour & bind the layer.
>
> This  paper
> <
> http://reprap.org/mediawiki/images/a/a5/Pia-taubert-material-mixing-report.pdf
> >
> proposes a reprap style six feed mixer with CMY + B + W for full spectrum
> colour output.
>
> color() is currently RGB which is not so suited to FFF/FDM colour
> specification as it is additive (255,255,255 = white, whereas in plastic
> that = black). A subtractive colour space  CMYK
> <http://en.wikipedia.org/wiki/CMYK_color_model>   is more suited to
> FFF/FDM
> colour mixing, but not to the likes of the ink-jet machines. Apparently
> conversion between RGB & CMYK is not straight forward.
>
> Also colour is one attribute of a material, ie blue PLA, red ABS, black
> NijaFlex, white Nylon. The mixing nozzles can combine both materials and
> colours. Other technology can mix material (which is white/transparent)
> with
> different properties, then add colour, so for example, you could have a
> gradual shift of flexibility/hardness, irrespective of the colour pattern
> across that span. (transparency introduces alpha as another property)
>
> Then there is surface colours, I haven't look into this much, but
> Shapeways
> <
> https://www.shapeways.com/tutorials/exporting_to_vrml_and_x3d_for_color_printing
> >
> for example can use either per face colour (easy?) or  UV texture maps
> <http://en.wikipedia.org/w/index.php?title=UV_mapping>  . Which may be
> more
> in the realm of other 3D modelling software.
>
> I don't have the solution, but it looks like material & colour (& alpha?)
> are required, there is probably more that I haven't conceived.
>
>
>
>
>
>
>
> -----
> Unless specifically shown otherwise above, my contribution is in the
> Public Domain; To the extent possible under law, I have waived all
> copyright and related or neighbouring rights to this work. This work is
> published globally via the internet. :) Inclusion of works of previous
> authors is not included in the above.
>
> The TPP is no simple “trade agreement.”   Fight it!
> http://www.ourfairdeal.org/
> --
> View this message in context:
> http://forum.openscad.org/Semantics-CSG-ops-with-respect-to-color-materials-tp12667p12718.html
> Sent from the OpenSCAD mailing list archive at Nabble.com.
>
> _______________________________________________
> OpenSCAD mailing list
> Discuss at lists.openscad.org
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscad.org/pipermail/discuss_lists.openscad.org/attachments/20150521/900562da/attachment-0002.html>


More information about the Discuss mailing list