discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Question regarding exporting to .PNG

J
jessaskey
Tue, Dec 19, 2017 12:16 AM

Hello...Im attempting to export to .png via the command line (using .com
under Windows)...An example command line I use is...C:\Program
Files\OpenSCAD\openscad.com -o C:\folder\038.png C:\folder\038.scadThis
succeeds and produces a valid .png file, however the render is incomplete
and only has some of my objects. It also happens very quickly in comparison
to exporting to an .STL which makes me think that OSCAD is just using
something cached perhaps?I tried adding an extra parameter '--render' to
'force' a render...        C:\Program Files\OpenSCAD\openscad.com -o
C:\folder\038.png --render C:\folder\038.scadbut that is not even valid
according to the output.What am I doing wrong here?thank you!Jess

--
Sent from: http://forum.openscad.org/

Hello...Im attempting to export to .png via the command line (using .com under Windows)...An example command line I use is...C:\Program Files\OpenSCAD\openscad.com -o C:\folder\038.png C:\folder\038.scadThis succeeds and produces a valid .png file, however the render is incomplete and only has some of my objects. It also happens very quickly in comparison to exporting to an .STL which makes me think that OSCAD is just using something cached perhaps?I tried adding an extra parameter '--render' to 'force' a render... C:\Program Files\OpenSCAD\openscad.com -o C:\folder\038.png --render C:\folder\038.scadbut that is not even valid according to the output.What am I doing wrong here?thank you!Jess -- Sent from: http://forum.openscad.org/
M
MichaelAtOz
Tue, Dec 19, 2017 12:44 AM

Do the --render before the -o.
That could be a bug...


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!

Sent from: http://forum.openscad.org/

Do the --render before the -o. That could be a bug... ----- 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! -- Sent from: http://forum.openscad.org/
TP
Torsten Paul
Tue, Dec 19, 2017 12:51 AM

On 19.12.2017 01:44, MichaelAtOz wrote:

Do the --render before the -o.
That could be a bug...

That or it might be only available in the snapshot versions.

ciao,
Torsten.

On 19.12.2017 01:44, MichaelAtOz wrote: > Do the --render before the -o. > That could be a bug... > That or it might be only available in the snapshot versions. ciao, Torsten.
M
MichaelAtOz
Tue, Dec 19, 2017 12:59 AM

I just ran it with 2015.03-02.


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!

Sent from: http://forum.openscad.org/

I just ran it with 2015.03-02. ----- 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! -- Sent from: http://forum.openscad.org/
TP
Torsten Paul
Tue, Dec 19, 2017 1:07 AM

On Linux it does not make any difference where the --render is located.

Example SCAD:

color("red") cube(10);

openscad -o test.png test.scad

=> red cube

openscad --render -o test.png test.scad

=> yellow cube

openscad -o test.png --render test.scad

=> yellow cube

openscad -o test.png test.scad --render

=> yellow cube

So maybe that's a problem with the OPENSCAD.COM wrapper?

What happens when using OPENSCAD.EXE?

ciao,
Torsten.

On Linux it does not make any difference where the --render is located. Example SCAD: color("red") cube(10); openscad -o test.png test.scad => red cube openscad --render -o test.png test.scad => yellow cube openscad -o test.png --render test.scad => yellow cube openscad -o test.png test.scad --render => yellow cube So maybe that's a problem with the OPENSCAD.COM wrapper? What happens when using OPENSCAD.EXE? ciao, Torsten.
M
MichaelAtOz
Tue, Dec 19, 2017 1:24 AM

tp3 wrote

What happens when using OPENSCAD.EXE?

Same.
In my case I use a square() - so preview is a yelow cube, render is a
cyan/red bordered square.

-o ... --render ...  produces the help info
--render -o ... ...  produces rendered square


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!

Sent from: http://forum.openscad.org/

tp3 wrote > What happens when using OPENSCAD.EXE? Same. In my case I use a square() - so preview is a yelow cube, render is a cyan/red bordered square. -o ... --render ... produces the help info --render -o ... ... produces rendered square ----- 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! -- Sent from: http://forum.openscad.org/
MM
Michael Marx
Tue, Dec 19, 2017 1:28 AM

Nabble has been dropping CRLF every so often (or it could be my email reader...), that looked
confusing.
That was:

-o ... --render ...  produces the help info
--render -o ... ...  produces rendered square

-----Original Message-----
From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of MichaelAtOz
Sent: Tue, 19 Dec 2017 12:25
To: discuss@lists.openscad.org
Subject: Re: [OpenSCAD] Question regarding exporting to .PNG

tp3 wrote

What happens when using OPENSCAD.EXE?

Same.
In my case I use a square() - so preview is a yelow cube, render is a
cyan/red bordered square.


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!

Sent from: http://forum.openscad.org/


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

Nabble has been dropping CRLF every so often (or it could be my email reader...), that looked confusing. That was: > -o ... --render ... produces the help info > --render -o ... ... produces rendered square > -----Original Message----- > From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of MichaelAtOz > Sent: Tue, 19 Dec 2017 12:25 > To: discuss@lists.openscad.org > Subject: Re: [OpenSCAD] Question regarding exporting to .PNG > > tp3 wrote > > What happens when using OPENSCAD.EXE? > > Same. > In my case I use a square() - so preview is a yelow cube, render is a > cyan/red bordered square. > > > > > > > ----- > 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! > -- > Sent from: http://forum.openscad.org/ > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
J
jessaskey
Tue, Dec 19, 2017 1:31 AM

Okay, I tried it 4 ways... both EXE and COM and then with --render before and
after the -o switch and parameter... looks like --render has to be
first!!!!!! No difference between .com and .exe.1. "C:\Program
Files\OpenSCAD\openscad.exe" -o C:\folder\038.png --render
C:\folder\038.scad        RESULT: Outputs usage - invalid?2. "C:\Program
Files\OpenSCAD\openscad.com" -o C:\folder\038.png --render
C:\folder\038.scad    RESULT: Outputs usage - invalid?3. "C:\Program
Files\OpenSCAD\openscad.exe" --render -o C:\folder\038.png
C:\folder\038.scad    RESULT: This Works!!!!4. "C:\Program
Files\OpenSCAD\openscad.com" --render -o C:\folder\038.png
C:\folder\038.scad    RESULT: This Works!!!Not sure about my post
formatting.... Im trying 'as HTML' this time... fingers crossed!!  Im using
Chrome.

--
Sent from: http://forum.openscad.org/

Okay, I tried it 4 ways... both EXE and COM and then with --render before and after the -o switch and parameter... looks like --render has to be first!!!!!! No difference between .com and .exe.1. "C:\Program Files\OpenSCAD\openscad.exe" -o C:\folder\038.png --render C:\folder\038.scad RESULT: Outputs usage - invalid?2. "C:\Program Files\OpenSCAD\openscad.com" -o C:\folder\038.png --render C:\folder\038.scad RESULT: Outputs usage - invalid?3. "C:\Program Files\OpenSCAD\openscad.exe" --render -o C:\folder\038.png C:\folder\038.scad RESULT: This Works!!!!4. "C:\Program Files\OpenSCAD\openscad.com" --render -o C:\folder\038.png C:\folder\038.scad RESULT: This Works!!!Not sure about my post formatting.... Im trying 'as HTML' this time... fingers crossed!! Im using Chrome. -- Sent from: http://forum.openscad.org/
J
jessaskey
Tue, Dec 19, 2017 1:37 AM

The HTML checkbox didn't seem to help... sorry about that.

--
Sent from: http://forum.openscad.org/

The HTML checkbox didn't seem to help... sorry about that. -- Sent from: http://forum.openscad.org/
MM
Michael Marx
Tue, Dec 19, 2017 1:37 AM

Aaargh

cmd options> -o ... --render ...

produces the help info

cmd options> --render -o ... ...

produces rendered square

Like so:

"C:\Program Files\OpenSCAD\openscad.exe" -o 2d_exe.png 2d.scad

Compiling design (CSG Products normalization)...

Normalized CSG tree has 1 elements

(yellow = preview)

"C:\Program Files\OpenSCAD\openscad.exe" -o 2d_exe.png --render 2d.scad

Usage: C:\Program Files\OpenSCAD\openscad.exe [ -o output_file [ -d deps_file ] ]\

                                          [ -m make_command ] [ -D var=val [..] ] \

                                          [ --help ] print this help message and exit \

                                          [ --version ] [ --info ] \

                                          [ --camera=translatex,y,z,rotx,y,z,dist | \

                                            --camera=eyex,y,z,centerx,y,z ] \

                                          [ --autocenter ] \

                                          [ --viewall ] \

                                          [ --imgsize=width,height ] [

--projection=(o)rtho|(p)ersp] \

                                          [ --render | --preview[=throwntogether] ] \

                                          [

--colorscheme=[Cornfield|Sunset|Metallic|Starnight|BeforeDawn|Nature|DeepOcean] ] \

                                          [ --csglimit=num ]\

                                          filename

(help)

"C:\Program Files\OpenSCAD\openscad.exe" --render -o 2d_exe.png 2d.scad

(cyan/red 2d)

-----Original Message-----

From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of Michael Marx

Sent: Tue, 19 Dec 2017 12:29

To: 'OpenSCAD general discussion'

Subject: Re: [OpenSCAD] Question regarding exporting to .PNG

Nabble has been dropping CRLF every so often (or it could be my email reader...), that looked

confusing.

That was:

-o ... --render ...  produces the help info

--render -o ... ...  produces rendered square

-----Original Message-----

From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of MichaelAtOz

Sent: Tue, 19 Dec 2017 12:25

Subject: Re: [OpenSCAD] Question regarding exporting to .PNG

tp3 wrote

What happens when using OPENSCAD.EXE?

Same.

In my case I use a square() - so preview is a yelow cube, render is a

cyan/red bordered square.


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!

--


OpenSCAD mailing list


OpenSCAD mailing list

Aaargh cmd options> -o ... --render ... produces the help info cmd options> --render -o ... ... produces rendered square Like so: "C:\Program Files\OpenSCAD\openscad.exe" -o 2d_exe.png 2d.scad Compiling design (CSG Products normalization)... Normalized CSG tree has 1 elements (yellow = preview) "C:\Program Files\OpenSCAD\openscad.exe" -o 2d_exe.png --render 2d.scad Usage: C:\Program Files\OpenSCAD\openscad.exe [ -o output_file [ -d deps_file ] ]\ [ -m make_command ] [ -D var=val [..] ] \ [ --help ] print this help message and exit \ [ --version ] [ --info ] \ [ --camera=translatex,y,z,rotx,y,z,dist | \ --camera=eyex,y,z,centerx,y,z ] \ [ --autocenter ] \ [ --viewall ] \ [ --imgsize=width,height ] [ --projection=(o)rtho|(p)ersp] \ [ --render | --preview[=throwntogether] ] \ [ --colorscheme=[Cornfield|Sunset|Metallic|Starnight|BeforeDawn|Nature|DeepOcean] ] \ [ --csglimit=num ]\ filename (help) "C:\Program Files\OpenSCAD\openscad.exe" --render -o 2d_exe.png 2d.scad (cyan/red 2d) > -----Original Message----- > From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of Michael Marx > Sent: Tue, 19 Dec 2017 12:29 > To: 'OpenSCAD general discussion' > Subject: Re: [OpenSCAD] Question regarding exporting to .PNG > > Nabble has been dropping CRLF every so often (or it could be my email reader...), that looked > confusing. > That was: > > > -o ... --render ... produces the help info > > --render -o ... ... produces rendered square > > > > -----Original Message----- > > From: Discuss [mailto:discuss-bounces@lists.openscad.org] On Behalf Of MichaelAtOz > > Sent: Tue, 19 Dec 2017 12:25 > > To: discuss@lists.openscad.org > > Subject: Re: [OpenSCAD] Question regarding exporting to .PNG > > > > tp3 wrote > > > What happens when using OPENSCAD.EXE? > > > > Same. > > In my case I use a square() - so preview is a yelow cube, render is a > > cyan/red bordered square. > > > > > > > > > > > > > > ----- > > 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! > > -- > > Sent from: http://forum.openscad.org/ > > > > _______________________________________________ > > OpenSCAD mailing list > > Discuss@lists.openscad.org > > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org > > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org