arebil has quit [Quit: My keyboard has gone to sleep. ZZZzzz…]
berndj has joined #openscad
ccox_ has joined #openscad
ccox has quit [Ping timeout: 246 seconds]
ur5us has quit [Ping timeout: 250 seconds]
TheCoffeMaker has quit [Ping timeout: 248 seconds]
TheCoffeMaker has joined #openscad
arebil has joined #openscad
teepee has quit [Remote host closed the connection]
teepee has joined #openscad
arebil has quit [Quit: My keyboard has gone to sleep. ZZZzzz…]
Guest95 has joined #openscad
Guest95 has quit [Client Quit]
arebil has joined #openscad
phryk has joined #openscad
<phryk>
Can I get the width/length/height of a passed object in a function or should I rather just define a module instead of passing objects to functions to modify them?
<J2224>
there is a option of resize but that is not ideal
<J2224>
phryk also i am not sure what you mean by passing objects to functions as in SCAD function deal with numbers not objects like a cube()
<phryk>
Oh, I just assumed that would be possible…
<J2224>
there might be some data conversion of objects in future releases
<phryk>
want to make a function for 45° bevels into which i can pass any cube. But really sounds like I should just define a module instead.
<J2224>
Also there is a functional library that deals all objects as a function
<teepee>
or maybe check existing libraries :)
<phryk>
openscad is already inperformant as hell, i really don't think i want to bloat it up with something like that.^^
<J2224>
either you have a function that defines points which are then converted into an object by a module
<teepee>
phryk: wrong strategy
<phryk>
teepee: please elaborate.
<teepee>
a) library authors often have added some special cases to make things go faster
<J2224>
or you do something like minkowsky (){cube();cylinder(h=1,d=1,d2=0,$fn=4);} which will chamfer it
<teepee>
b) in alsmost all cases it's the geometry calculation that's taking time, so even the huge library written by J2224 is adding maybe a second or so
<phryk>
teepee: for each rendered frame? o_O
<teepee>
huh?
<teepee>
what frame
J2224 is now known as J22
<phryk>
when rotating in the viewport
<teepee>
that has nothing to do with the code anymore
<phryk>
that's what's inperformant for me.
<phryk>
really? that's good to know.
<J22>
no .. but each preview (F5) can have 200ms
<teepee>
then use nightly build and enable the *vbo* options if it's preview
<phryk>
i have openscad from freebsd ports, really not feeling like doing a manual build. also the current project should be simple enough for openscad to remain usable-ish.
<J22>
vbo? is that new?
<phryk>
just pouring an established subwoofer design into code this time. :P
<teepee>
no
<J22>
i don't have a vbo feature :(
<teepee>
hmm? how is it called then?
<J22>
vertex object render?
<teepee>
right it's spelled out, vertex-object
<teepee>
vbo = vertex buffer object or something like that
<teepee>
basically hand over graphics data to GPU in a big buffer
<J22>
(also what is sort stl .. if i have 3mf?)
<teepee>
that's sorting the vertices so it's more obvious for diffs in text mode
<J22>
teepee ok but what do you mean with "diff" and "text mode"
<teepee>
it makes more sense for ASCII STLs, not sure it's useful for BINARY
<teepee>
although the sorting works for binary too of course
<J22>
ah so it is really if i edit the stl files and compare them
<J22>
SCAD didn't have ASCII anymore (iirc)
<J22>
hm F7 is still STL export even i have that nice 3mf button Ü
<dalias>
3mf >_<
<dalias>
such a disgusting format
<teepee>
best one for meshes at this point
<J22>
diffable is not a word .. diff- able maybe
<dalias>
full of invisible application specific cruft that might or might not get interpreted by a program reading the file in ways that break things, that requires manually unzipping and digging around inside to find and figure out what's happening
<dalias>
(same as ms office files, etc.)
<dalias>
stl is really the best format for meshes because there's no room for anything but the mesh
<teepee>
in theory yes, it's based on that container spec
<teepee>
still
<teepee>
1) open, free spec
<teepee>
2) open, free, MIT library which is multi-platform
<dalias>
neither 1 nor 2 has anything to do with the format being good or bad
<teepee>
STL is not a format, it's just some random text some tools may interpret as geometry
<dalias>
sure it is. you can even write a regex to match it :-)
<teepee>
yes it does, I'm refusing to do anything further on AMF
<dalias>
because it's a *regular language*
<J22>
dalias yeah the 3mf from microsoft are not working in slicer/cura
<teepee>
they can shove their spec somewhere as they have it behind a paywall
<dalias>
j22, at least "not working" is a better state than "something mysterious happens when you go to slice because the model author embedded their idiotic slicing settings in the model file"
<dalias>
STL is the ideal format. screw AMF and 3MF
<dalias>
it's ideal because it has no room for anything extraneous
<teepee>
no STL is garbage
<J22>
well not working was meant as UB
<dalias>
expressiveness is an antifeature. the most constrained languages are the best
<teepee>
it was good while nothing else existed but that was when everyone was using fortran ;-)
<dalias>
and regular is just *heart emoji*^10000000
<phryk>
everything is garbage unless i get a general-purpose matter printer that can print nanometer-size circuits. >:F
<J22>
however 3mf is smaller, can have color and a thumbnail. So the problem is how slicer software implemeted it
<J22>
phryk exist .. but is terribly slow
<phryk>
J22: really? i can print a cpu with like 14nm scaling?
<J22>
if you have aeons time
arebil has quit [Quit: My keyboard has gone to sleep. ZZZzzz…]
<J22>
In astronomy an aeon is defined as a billion years (109 years, abbreviated AE).
<phryk>
Thanks, but I absolutely don't want smooth anything. I need to build this stuff by hand. :P
<InPhase>
Your hands like rough edges? :)
<phryk>
my manufacturing capabilities like rough edges. :D
<phryk>
also yes, things being well stackable is a boon IMO :P
<phryk>
if i ever get to build speakers with industrial robots, that's when I'll want smooth edges for things like horn designs, but as long as I'm building them myself, no thank you.^^
<InPhase>
phryk: I often like to just take corners off, to reduce the stabbing damage dice roll. Hence the feature in that library for it.
<othx>
InPhase linked to "Toothbrush / Toothpaste Holder, Philips Sonicare and More by rcolyer" on thingiverse => 5 IRC mentions
<phryk>
yeah, for household items that's undoubtedly nice. but i'm making a big honking PA :P
<phryk>
back to topic: is there something like a ruler module? I want to be able to highlight some dimensions to make them easily readable when viewing the assembly.
<InPhase>
Not really. Although you can construct a series of echos to print key calculated dimensions to console.
<InPhase>
The OpenSCAD philosophy targets shape design rather than engineering document preparation, and follows a calculate-first workflow, but you can record whatever consequences of those calculations you want.
<phryk>
Well, this wouldn't only be useful for documentation, I've often found myself wanting something like this during development.
<InPhase>
You can enable view crosshair and make use of that to assess the locations of various features.
<InPhase>
The crosshair coordinates are displayed.
<phryk>
not accurate but still extremely manual…
<phryk>
I use computers so I *don't* have to calculate shit. :F
<InPhase>
Yes. That is typically done during the calculate steps.
<InPhase>
The design flows from the numbers.
<InPhase>
That crosshair thing doesn't need to be used very often. It's more of a sanity check on a small handful of things to make sure you didn't screw something up.
<phryk>
Yes, but I also need to be able to review the final dimensions easily to actually check for correctness without it being a constant struggle.
<InPhase>
It's a can of worms with things other than trivial shapes. For example, round a square's corners, and suddenly no edge represents its dimensionality. Want to know the curvature radius of the corners? Well they're not even round by the time it gets to the display window. They've already been turned into a series of tiny edges tracing out the curve.
<InPhase>
Programmatic calculation is digested heavily by the time it gets to display form.
<phryk>
a cube defined by outer edges of a cube containing a module would be good enough for me.
<phryk>
but openscad doesn't have *anything* for visually confirmed measurements.
<phryk>
honestly, a module that just takes two coordinates and is displayed in the viewport alongside its length would be the idea minimal tool that would be sufficient for my use.
<J22>
phryk my lib has a "caliper" to add viewable measurements in drawings .. also a 3 way projection module
<phryk>
J22: no idea what the latter is, but do you have a screenshot of the caliper tool?
<dalias>
is there really no newer tag than 2021.01 ?
<dalias>
trying to get distro to package an up-to-date version and they just pointed out to me that this is the latest :(
<J22>
if you have a cube it will give you the 3 views ( side top front) flat side by side like you need in a tech drawing
<dalias>
is there a reason there's not?
<dalias>
aiui current has lots of geometry speed improvements and experimental features i want :)
<phryk>
J22: mhh, usable for displaying lengths, but no calculation taking two vertex points. i think i might look in the source and make a module taking to coordinates out of that…
<teepee>
yes, there's a reason
<teepee>
and no, it's not a technical one
<dalias>
:/
<dalias>
i can relate
<J22>
phryk if you have variables with the size you can feed this into the module - else there is no way to get these information out
<phryk>
J22: huh? vector math?^^
<J22>
oh there is i think it is the line module in that lib that display the length between two points .. but if you have a cube you can't get the dimensions (bounding box) from a geometry
<phryk>
len(v1 -v2)
<phryk>
J22: yeah, that's what i stumbled over earlier with function vs module^^
<J22>
T is short for translate while you can access T(y=5) and Tz (5) is the same like T(z=5)
<AndrewStone[m]>
gotcha, of course! (and yes I mostly read your README, so now I went back and did a search -- they aren't docced there)
<J22>
Tz is not just lazy but using it makes it clear that something is on the same position just on a other level .. as with [0,0,5] this is not always that clear
<J22>
hmm yeah they are in the image .. i really need to put those in text so they get searchable
<J22>
a wiki would probably be even better
<J22>
i think in the example.scad i have short descriptions