Quantcast

text() 2D or 3D?

classic Classic list List threaded Threaded
26 messages Options
12
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

text() 2D or 3D?

TheNewHobbyist
Hi all,

Hope this is an OK place to post this.

I'm loving the addition of the text() module but I'm a little confused as far as the documentation goes. On this page of the documentation it looks like text() should be generating 2D outlines for extrusion (http://en.wikibooks.org/wiki/OpenSCAD_User_Manual/Text).

But when I preview text in in OpenSCAD on my Mac it appears to be extruded (by 1mm). It this the intended functionality?

http://i.imgur.com/HfhRv6L.png
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Laura Taalman
Oh, I think I know this one. In "F5" it looks like the text has a thickness, but if you press "F6" it should be shown how it really is, as a 2D object. 

Laura/mathgrrl

On Wed, Mar 25, 2015 at 11:50 PM, TheNewHobbyist <[hidden email]> wrote:
Hi all,

Hope this is an OK place to post this.

I'm loving the addition of the text() module but I'm a little confused as
far as the documentation goes. On this page of the documentation it looks
like text() should be generating 2D outlines for extrusion
(http://en.wikibooks.org/wiki/OpenSCAD_User_Manual/Text).

But when I preview text in in OpenSCAD on my Mac it appears to be extruded
(by 1mm). It this the intended functionality?

http://i.imgur.com/HfhRv6L.png




--
View this message in context: http://forum.openscad.org/text-2D-or-3D-tp12217.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org



--
Dr. Laura Taalman

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

shadowwynd
In F5 (preview mode), all 2D shapes have a 1mm thickness just for preview purposes.  In F6, 2D elements have no thickness.

linear_extrude(10) text("Hello");

makes an extruded text.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

TheNewHobbyist
Ah, yeah rendering does render as pictured in the documentation. 

Is this a limitation of the preview render? It seems a little confusing to have it render two different ways.

On Wed, Mar 25, 2015 at 11:01 PM, shadowwynd <[hidden email]> wrote:
In F5 (preview mode), all 2D shapes have a 1mm thickness just for preview
purposes.  In F6, 2D elements have no thickness.

linear_extrude(10) text("Hello");

makes an extruded text.





--
View this message in context: http://forum.openscad.org/text-2D-or-3D-tp12217p12219.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

MichaelAtOz
Administrator
TheNewHobbyist wrote
Is this a limitation of the preview render? It seems a little confusing to
have it render two different ways.
Yes, it was a design choice some time ago and has been the topic of some discussion re the confusion it can generate. There have been proposals to make it something like 0.001 thick. Pending.
Admin - PM me if you need anything,
or if I've done something stupid...

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.
Obviously 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/ time is running out!
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Greg Frost
Something that seems like a bug is that if you scale a 2d shape with just a single argument it scales in z too.

But perform some 2d operation on it (like offset() and it returns back to 1mm thick.

> On 26 Mar 2015, at 6:45 pm, MichaelAtOz <[hidden email]> wrote:
>
> TheNewHobbyist wrote
>> Is this a limitation of the preview render? It seems a little confusing to
>> have it render two different ways.
>
> Yes, it was a design choice some time ago and has been the topic of some
> discussion re the confusion it can generate. There have been proposals to
> make it something like 0.001 thick. Pending.
>
>
>
> -----
> 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/text-2D-or-3D-tp12217p12221.html
> Sent from the OpenSCAD mailing list archive at Nabble.com.
>
> _______________________________________________
> OpenSCAD mailing list
> [hidden email]
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Dave92F1
This post was updated on .
In reply to this post by MichaelAtOz
FWIW, I came here just to understand the same thing - why is the supposedly zero-thickness 2D text rendering as if it has a thickness around 1 mm?

Changing it to 0.001 mm (1 micron) or even less would probably be a big improvement in obviousness.

If that's not happening, a warning printed on the console would be very helpful - something like:

   WARNING: 2D text rendered as 1 mm thick for preview purposes only.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

shadowwynd
All 2-D shapes such a square and circle and polygon have a preview render of 1 mm. You can linear extrude this to whatever thickness you require.

Sent from my iPhone

> On Feb 5, 2017, at 8:08 PM, Dave92F1 <[hidden email]> wrote:
>
> mm?

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

MichaelAtOz
Administrator
Rattling the skeletons in the closet?

I think 2D should be previewed very thin (probably a technical choice of exact number), AND in teal, or whatever that rendered 2D colour is. Without the red edges that rendering does, to highlight it is previewed.

Interesting comment above re 2D previews actually scaling in Z, that should, at best not, or at least generate a warning.
Admin - PM me if you need anything,
or if I've done something stupid...

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.
Obviously 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/ time is running out!
tp3
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

tp3
In reply to this post by Dave92F1
On 02/06/2017 02:08 AM, Dave92F1 wrote:
> Changing it to 0.000001 mm (1 micron) would probably be a big
> improvement in obviousness.
>
While I don't know the details, I do suspect the reason for that
1 unit display is technical and based on limitations/behavior of
the preview display mode.

I'm pretty sure it can be improved by using 0.01 or something
similar (https://github.com/openscad/openscad/issues/1566),
setting it to a very small value might cause Z-fighting or other
issues so we'd just swap one problem with a slightly different
one.

ciao,
  Torsten.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
-- Torsten
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

nophead
cube([10,10, 0.0000001]);
square(5);

Previews correctly and shows the madness of it.

On 6 February 2017 at 08:12, Torsten Paul <[hidden email]> wrote:
On 02/06/2017 02:08 AM, Dave92F1 wrote:
> Changing it to 0.000001 mm (1 micron) would probably be a big
> improvement in obviousness.
>
While I don't know the details, I do suspect the reason for that
1 unit display is technical and based on limitations/behavior of
the preview display mode.

I'm pretty sure it can be improved by using 0.01 or something
similar (https://github.com/openscad/openscad/issues/1566),
setting it to a very small value might cause Z-fighting or other
issues so we'd just swap one problem with a slightly different
one.

ciao,
  Torsten.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
tp3
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

tp3
On 02/06/2017 11:05 AM, nop head wrote:
> cube([10,10, 0.0000001]);
> square(5);
>
> Previews correctly and shows the madness of it.
>
That's not really an example that could show issues.
With both sides same color, it's obviously fine as
there's nothing to interfere.

Also it might depend on the combination of OS, graphics
card and graphics driver".

Try:

cube([10,10, 0.0000001]);
color("yellow")
    translate([0, 0, 0.00001])
        cube([10,10, 0.0000001]);
square(5);

The yellow "cube" is obviously totally above the other
one. Yet looking from below, I'm getting some nice
Z-Fighting artifacts. From above it's mostly fine, but
even in that direction I'm getting a very small amount
of flickering. I guess that's mostly due to order of
the rendering.
( If the attached image does not make it to the forum
post, see http://imgur.com/AUoQJ3A ).

ciao,
  Torsten.


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

Screenshot from 2017-02-06 12-05-05.png (111K) Download Attachment
-- Torsten
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Ronaldo
polyhedron([[0,0,0],[0,10,0],[10,10,0],[10,0,0]],[[0,1,2,3]]);

No z-fighting, zero thickness.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

nophead
Any surfaces in OpenSCAD that are close cause Z fighting. But a single surface does not, as it has nothing to fight with, as long as back faces are culled.

So I don't think Z fighting is a reason not to make 2D objects very thin.

On 6 February 2017 at 11:25, Ronaldo Persiano <[hidden email]> wrote:
polyhedron([[0,0,0],[0,10,0],[10,10,0],[10,0,0]],[[0,1,2,3]]);

No z-fighting, zero thickness.

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org



_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
tp3
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

tp3
On 02/06/2017 12:58 PM, nop head wrote:
> Any surfaces in OpenSCAD that are close cause Z fighting. But
> a single surface does not, as it has nothing to fight with,
> as long as back faces are culled.
>
> So I don't think Z fighting is a reason not to make 2D objects
> very thin.
>
I think it is a reason to not make it *very* thin. The current
thickness is confusing, going to the other extreme and causing
different issues seems not a good idea.

I simply suggest to see how a not-so-extreme change works out.

ciao,
  Torsten.


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
-- Torsten
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

nophead
Yes but very thin causes no problems. Very close causes problems but I don't see how that is more likely with thin.

Anyway 0.1 would be a lot better than 1 at the scales I work with but perhaps not for others.

On 6 February 2017 at 12:03, Torsten Paul <[hidden email]> wrote:
On 02/06/2017 12:58 PM, nop head wrote:
> Any surfaces in OpenSCAD that are close cause Z fighting. But
> a single surface does not, as it has nothing to fight with,
> as long as back faces are culled.
>
> So I don't think Z fighting is a reason not to make 2D objects
> very thin.
>
I think it is a reason to not make it *very* thin. The current
thickness is confusing, going to the other extreme and causing
different issues seems not a good idea.

I simply suggest to see how a not-so-extreme change works out.

ciao,
  Torsten.


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

jon_bondy

Could the thickness be configurable, as well as the displayed color?


On 2/6/2017 8:19 AM, nop head wrote:
Yes but very thin causes no problems. Very close causes problems but I don't see how that is more likely with thin.

Anyway 0.1 would be a lot better than 1 at the scales I work with but perhaps not for others.

On 6 February 2017 at 12:03, Torsten Paul <[hidden email]> wrote:
On 02/06/2017 12:58 PM, nop head wrote:
> Any surfaces in OpenSCAD that are close cause Z fighting. But
> a single surface does not, as it has nothing to fight with,
> as long as back faces are culled.
>
> So I don't think Z fighting is a reason not to make 2D objects
> very thin.
>
I think it is a reason to not make it *very* thin. The current
thickness is confusing, going to the other extreme and causing
different issues seems not a good idea.

I simply suggest to see how a not-so-extreme change works out.

ciao,
  Torsten.


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org



_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


No virus found in this message.
Checked by AVG - www.avg.com
Version: 2016.0.7998 / Virus Database: 4756/13899 - Release Date: 02/06/17



_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Ronaldo
In reply to this post by nophead
nophead wrote
Any surfaces in OpenSCAD that are close cause Z fighting. But a single
surface does not, as it has nothing to fight with, as long as back faces
are culled.

So I don't think Z fighting is a reason not to make 2D objects very thin.
I don't think, either. My intention here is to show that 2D models may be well represented without thickness.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

Dave92F1
I didn't mean to restart a war.

Just throwing a warning about the 1 unit rendering would be fine with me.

But silently rendering a 2D object as 3-dimensional is highly misleading to the newbie.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: text() 2D or 3D?

MichaelAtOz
Administrator
scale should automatically set z component to 1 for 2D objects #1646 covers the scale issue I mentioned, and shows how it is a problem. Being thinner would help, but fixing scale would be better.

> But silently rendering a 2D object as 3-dimensional is highly misleading to the newbie.

Not just newbies, it still gets me from time to time...

I imagine the change of thinness is not overly complex, perhaps it could be 0.01 for now, then see if it trips up anyone in the future, before going to more complex solutions?
Admin - PM me if you need anything,
or if I've done something stupid...

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.
Obviously 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/ time is running out!
12
Loading...