discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

STL and how?

I
iznogood
Sun, May 15, 2016 10:27 AM

If you got errors:
DEPRECATED: Imported file (Turntable_V01.stl) found in document root instead
of relative to the importing module. This behavior is deprecated

Tried to find by google and forums how to do insted?
Resides in same library as my scad file
import("Turntable_V01.stl");

Still works watching ( F5) and rendering (F6 ) aslong as you ONLY have the
importline you can also export an stl.

But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only
rendering my add ons???

I am lost, plz guide me right.
/Ice
=============8><=================
import("Turntable_V01.stl");

module plate(){

rotate([0,0,28])translate([19,9,0])cube([20,26,2]);
rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]);

}

difference(){
plate();
color("red")translate([15,32,0])cylinder(h=30, d=4, center=true);
color("red")translate([77,57,0])cylinder(h=30, d=4, center=true);
}

--
View this message in context: http://forum.openscad.org/STL-and-how-tp17312.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

If you got errors: DEPRECATED: Imported file (Turntable_V01.stl) found in document root instead of relative to the importing module. This behavior is deprecated Tried to find by google and forums how to do insted? Resides in same library as my scad file import("Turntable_V01.stl"); Still works watching ( F5) and rendering (F6 ) aslong as you ONLY have the importline you can also export an stl. But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only rendering my add ons??? I am lost, plz guide me right. /Ice =============8><================= import("Turntable_V01.stl"); module plate(){ rotate([0,0,28])translate([19,9,0])cube([20,26,2]); rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]); } difference(){ plate(); color("red")translate([15,32,0])cylinder(h=30, d=4, center=true); color("red")translate([77,57,0])cylinder(h=30, d=4, center=true); } -- View this message in context: http://forum.openscad.org/STL-and-how-tp17312.html Sent from the OpenSCAD mailing list archive at Nabble.com.
DM
doug moen
Sun, May 15, 2016 3:00 PM

I'm trying to figure this out by reading the source code.

The DEPRECATED message is just a warning, not a fatal error. It should only
be issued if the import() statement occurs inside a *.scad file that is
include-d or use-d by another *.scad file, as discussed here:
https://github.com/openscad/openscad/issues/217

This means you haven't shown all of your source code; there should be two
*.scad files involved. The first is a "parent" scad file, which uses or
includes a "child" scad file, which contains an import statement.

The *.stl file should be in the same directory as the "child" scad file,
and not in the same directory as the "parent" scad file. If you do this,
the DEPRECATED message should go away.

Doug Moen

On 15 May 2016 at 06:27, iznogood icedizzy@gmail.com wrote:

If you got errors:
DEPRECATED: Imported file (Turntable_V01.stl) found in document root
instead
of relative to the importing module. This behavior is deprecated

Tried to find by google and forums how to do insted?
Resides in same library as my scad file
import("Turntable_V01.stl");

Still works watching ( F5) and rendering (F6 ) aslong as you ONLY have the
importline you can also export an stl.

But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only
rendering my add ons???

I am lost, plz guide me right.
/Ice
=============8><=================
import("Turntable_V01.stl");

module plate(){

 rotate([0,0,28])translate([19,9,0])cube([20,26,2]);
 rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]);

}

difference(){
plate();
color("red")translate([15,32,0])cylinder(h=30, d=4, center=true);
color("red")translate([77,57,0])cylinder(h=30, d=4, center=true);
}

--
View this message in context:
http://forum.openscad.org/STL-and-how-tp17312.html
Sent from the OpenSCAD mailing list archive at Nabble.com.


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

I'm trying to figure this out by reading the source code. The DEPRECATED message is just a warning, not a fatal error. It should only be issued if the import() statement occurs inside a *.scad file that is include-d or use-d by another *.scad file, as discussed here: https://github.com/openscad/openscad/issues/217 This means you haven't shown all of your source code; there should be two *.scad files involved. The first is a "parent" scad file, which uses or includes a "child" scad file, which contains an import statement. The *.stl file should be in the same directory as the "child" scad file, and not in the same directory as the "parent" scad file. If you do this, the DEPRECATED message should go away. Doug Moen On 15 May 2016 at 06:27, iznogood <icedizzy@gmail.com> wrote: > If you got errors: > DEPRECATED: Imported file (Turntable_V01.stl) found in document root > instead > of relative to the importing module. This behavior is deprecated > > Tried to find by google and forums how to do insted? > Resides in same library as my scad file > import("Turntable_V01.stl"); > > Still works watching ( F5) and rendering (F6 ) aslong as you ONLY have the > importline you can also export an stl. > > But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only > rendering my add ons??? > > I am lost, plz guide me right. > /Ice > =============8><================= > import("Turntable_V01.stl"); > > > module plate(){ > > rotate([0,0,28])translate([19,9,0])cube([20,26,2]); > rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]); > } > > difference(){ > plate(); > color("red")translate([15,32,0])cylinder(h=30, d=4, center=true); > color("red")translate([77,57,0])cylinder(h=30, d=4, center=true); > } > > > > > > > > -- > View this message in context: > http://forum.openscad.org/STL-and-how-tp17312.html > Sent from the OpenSCAD mailing list archive at Nabble.com. > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org > > >
I
iznogood
Sun, May 15, 2016 3:39 PM

One step further.
Made an add.scad file with just a line ( below ).
Then instead of importing I included the file.
Results are the same the things I add will be viewed when I do F6 but looks
nice all toghether in preview (F5).
But no errors or warnings
The stl file can be found here:
http://www.thingiverse.com/thing:37222/#files
Then It may solve something?
/Ice

============ 8><========= add.scad =========

import("Turntable_V01.stl");

---======

============8><========== turn_modified.scad===

include<add.scad>

module plate(){

rotate([0,0,28])translate([19,9,0])cube([20,26,2]);
rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]);

}

difference(){
plate();
color("red")translate([15,32,0])cylinder(h=30, d=4, center=true);
color("red")translate([77,57,0])cylinder(h=30, d=4, center=true);
}

---===========

--
View this message in context: http://forum.openscad.org/STL-and-how-tp17312p17314.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

One step further. Made an add.scad file with just a line ( below ). Then instead of importing I included the file. Results are the same the things I add will be viewed when I do F6 but looks nice all toghether in preview (F5). But no errors or warnings The stl file can be found here: http://www.thingiverse.com/thing:37222/#files Then It may solve something? /Ice ============ 8><========= add.scad ========= import("Turntable_V01.stl"); ======================================= ============8><========== turn_modified.scad=== include<add.scad> module plate(){ rotate([0,0,28])translate([19,9,0])cube([20,26,2]); rotate([0,0,28])translate([84,2,0])cube([18.5,26,2]); } difference(){ plate(); color("red")translate([15,32,0])cylinder(h=30, d=4, center=true); color("red")translate([77,57,0])cylinder(h=30, d=4, center=true); } ============================================ -- View this message in context: http://forum.openscad.org/STL-and-how-tp17312p17314.html Sent from the OpenSCAD mailing list archive at Nabble.com.
MK
Marius Kintel
Sun, May 15, 2016 4:54 PM

On May 15, 2016, at 06:27 AM, iznogood icedizzy@gmail.com wrote:

But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only
rendering my add ons???

On May 15, 2016, at 06:27 AM, iznogood <icedizzy@gmail.com> wrote: > > But my goal were to modify the turntable ( F5 ) looks good ( F6 ) only > rendering my add ons??? This sounds a bit like this issue from the FAQ: https://en.wikibooks.org/wiki/OpenSCAD_User_Manual/FAQ#Why_is_my_imported_STL_file_only_showing_up_with_F5_but_not_F6.3F -Marius
I
iznogood
Sun, May 15, 2016 5:27 PM

Yup!
There it was.
A crappy STL-file ( they should not publish those... )
So sorry to bother you all but I have learned a lot.
I think I do my own from the beginning in openscad.
A shortcut is not always a shortcut.
Thanks again all.
/Lennie

--
View this message in context: http://forum.openscad.org/STL-and-how-tp17312p17316.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

Yup! There it was. A crappy STL-file ( they should not publish those... ) So sorry to bother you all but I have learned a lot. I think I do my own from the beginning in openscad. A shortcut is not always a shortcut. Thanks again all. /Lennie -- View this message in context: http://forum.openscad.org/STL-and-how-tp17312p17316.html Sent from the OpenSCAD mailing list archive at Nabble.com.
MK
Marius Kintel
Sun, May 15, 2016 9:24 PM

On May 15, 2016, at 13:27 PM, iznogood icedizzy@gmail.com wrote:
A crappy STL-file ( they should not publish those… )

Keep reporting those btw., and link to the files if you can.
Our longer-term goal is to be more robust at importing problematic files, e.g. through auto-repair, so the more examples we have, the better we can test this in the future.

-Marius

> On May 15, 2016, at 13:27 PM, iznogood <icedizzy@gmail.com> wrote: > A crappy STL-file ( they should not publish those… ) Keep reporting those btw., and link to the files if you can. Our longer-term goal is to be more robust at importing problematic files, e.g. through auto-repair, so the more examples we have, the better we can test this in the future. -Marius