<JordanBrown[m]>
InPhase: Yes, I work for Oracle. No, I do not work at Redwood Shores. I was part of the Sun acquisition, so many of my coworkers are in Santa Clara (at the old Agnew State Mental Hospital). But I am in Los Angeles. I used to work at a building near LAX, but when they shut that building down I went to 100% work-from-home. That was in 2004.
<JordanBrown[m]>
Trivia: Redwood Shores is the headquarters of Northam Robotics in the movie Bicentennial Man.
<JordanBrown[m]>
Trivia: That's no longer Oracle HQ. HQ is now in Austin.
<JordanBrown[m]>
Trivia: In the original Asimov books, the company name was US Robotics. But in the dawn of the personal computer era, a modem company started using that name - as an homage to Asimov's work - and so when they did the movie they didn't want the company in the movie to be confused with the modem company, so renamed it.
<JordanBrown[m]>
Correction: I should have typed "NorthAm", with a capital A.
<JordanBrown[m]>
Actually, I think the original name was "US Robots and Mechanical Men, Inc".
<InPhase>
JordanBrown[m]: Ah, well that's a lot of things corrected. I had no idea Oracle relocated. :)
<JordanBrown[m]>
"relocated" is an interesting word.
<JordanBrown[m]>
I don't know whether any people moved.
<JordanBrown[m]>
But the nominal HQ moved.
<JordanBrown[m]>
Larry moved to Lanai'i.
<InPhase>
JordanBrown[m]: I've lived in Irvine, Pasadena, and Altadena, the latter two while working at UCLA. So I guess we've been proximate at some point. :)
<JordanBrown[m]>
yes
<JordanBrown[m]>
I've been in SoCal since 1979.
<JordanBrown[m]>
And lived in ALtadena from about 1984 to 1987.
<JordanBrown[m]>
Hmm. No, more like 1981 to 1987.
<JordanBrown[m]>
JPL, Ashton-Tate, and then a small startup that nobody has heard of, that eventually evaporated.
<JordanBrown[m]>
Oh, and a place called Locus Computing, that also nobody has heard of (but at least has a Wikipedia page).
<InPhase>
Yeah, I was over near JPL.
<InPhase>
But not working there.
<JordanBrown[m]>
Lake and Washington.
<JordanBrown[m]>
Great place to work. But the pay is awful if you don't have a degree, no matter what work you are actually doing.
<InPhase>
That sounds about like what I'd expect from such a place. :)
<JordanBrown[m]>
I was there during one (or maybe more than one) of the Voyager Saturn encounters. You'd be sitting in the cafeteria watching images come in, one scan line at a time.
<JordanBrown[m]>
I kept expecting a picture to come in with the top half showing an alien spacecraft, and the bottom half static.
<JordanBrown[m]>
I am also amused that when I did a Google search for "northam robotics", I got several hits for Governor Ralph Northam of Virginia announcing some stuff about a robotics startup in Norfolk.
<JordanBrown[m]>
And the pickings must be really slim, because the announcement and press release was about the company investing $101,400 to expand their operation.
ur5us has joined #openscad
ur5us has quit [Ping timeout: 264 seconds]
Red80 has joined #openscad
snaked has quit [Ping timeout: 260 seconds]
Red80 has quit [Client Quit]
snaked has joined #openscad
epony has quit [Ping timeout: 252 seconds]
Virindi has quit [Quit: ZNC 1.8.2+deb2+b1 - https://znc.in]
teepee has quit [Remote host closed the connection]
teepee has joined #openscad
teepee_ has joined #openscad
teepee has quit [Ping timeout: 258 seconds]
teepee_ is now known as teepee
epony has joined #openscad
snaked has quit [Quit: Leaving]
J1A843442 has joined #openscad
J1A8434 has quit [Ping timeout: 252 seconds]
teepee has quit [Remote host closed the connection]
teepee has joined #openscad
Guest77 has joined #openscad
<Guest77>
I used to do a lot with openSCAD and discussed interesting solutions for curved objects using the sweep functions. What is the best forum to discuss openSCAD challenges?
<Guest77>
The old forum seems to be killed years ago.
<Guest77>
regards, Johan Jonker
<J1A843442>
Guest77 there is a reddit .. or here or a mailing list
<teepee>
the mailing list *is* basically what the old forum was too
<teepee>
nabble combined both, but they shut down hosting and development so just the mailing list remains (with some sort of forum style frontend which is not so good)
<J1A843442>
hm less than 2 month for the advent challenges
<teepee>
unfortunately the main author (and also main person of that company?) died so that forum may not seen much improvments either
<teepee>
yeah, thinking about that too :)
<teepee>
scary
<teepee>
maybe first question: what's the scope?
<teepee>
I always was thinking there could be one which has maybe 3 or 4 models in 6 or 8 pieces
<J1A843442>
the piece model is about the advent calendar ? .. thought the same that this would be great if it is from multiple people
<J1A843442>
you know like these folding letter thingies
<teepee>
folding letter?
<J1A843442>
this draw something fold it with marks where to draw next and give to the neighbor
<J1A843442>
in regards of SCAD everybody get a unit cube and has 6 connections of 1/5 of the unit cube circular center of each side ..
<J1A843442>
would be a funny letter case if assembled
<JordanBrown[m]>
Or, by analogy to the folding-drawing game, the first person constructs a model (perhaps in a unit cube, perhaps not) and gives the next person the 2D projections of how that model touches the sides of the cube. That next person uses those 2D projections as the starting point for *their* model.
<J1A843442>
or for a figurine and each body part got his own design .. maybe start with a snowman
<JordanBrown[m]>
I have a possible advent calendar submission in the works. (But the implementation depends on the import-svg-by-id fork.) Should I show it here, or leave it as a surprise?
<teepee>
JordanBrown[m]: posting as expiring pastebin or something like that seems fine, it's not like very top extra secret
<J1A843442>
advent calendar submissions should run on its own with no experimental lib or external help
<teepee>
well, that's what I meant above
<teepee>
so far that was the requirement - release openscad + no external dependencies
<teepee>
nothing wrong in having a different scope this year, we just would need to make a clear note somewhere that the "rules" are
<JordanBrown[m]>
It could be transformed to use standard OpenSCAD. It just imports from an SVG to get the polygons, because it's a lot easier to draw in Inkscape.
<teepee>
JordanBrown[m]: I can also just invite you to the repo that is meant to collect the stuff
<JordanBrown[m]>
I'll just paste the image here. I think that will turn into a link for those on conventional IRC. I don't know what the lifespan is, but if somebody dredges it out of the archives, well, they deserve to have the surprise spoiled :-)
<J1A843442>
you could import the svg as points (inkscape addon )
<J1A843442>
i think it would be a great occasion to promote and show new SCAD features
<teepee>
1) multi-level, flat + hollow, christmas tree (like 3 levels at total of ~30cm). leaving openings to put in one of those enameled wire led strings
<teepee>
2) schwibbogen :)
<teepee>
3) toy train with tracks, optional electronics
<JordanBrown[m]>
And yes, you absolutely can do that model with base OpenSCAD features, but drawing it in OpenSCAD would be a pain in the neck. I traced it in Inkscape, separated out the various parts that should be at different levels, gave each of the paths a name, and then used the import-svc-by-id feature to bring them in and linear-extrude and color them appropriately.
<J1A843442>
a toy train sounds like a perfect multi user project
<JordanBrown[m]>
s/svc/svg
<teepee>
and this makes total sense, using the tool that works
<JordanBrown[m]>
yes
<JordanBrown[m]>
(yes about the train)
<JordanBrown[m]>
another, riffing off something said earlier, might be to supply a stock snowman and then have people come up with accessories to put on the snowman.
<teepee>
you could put that data structure into a json file and use objects :P
<JordanBrown[m]>
Kind of Mr. Potato Head.
<teepee>
which makes me think data = import("file.svg"); might even import some meta data like the layers
<J1A843442>
collaboration was the word i was looking for
<JordanBrown[m]>
The thought did cross my mind. (Not the JSON part, just the "object" part.)
<JordanBrown[m]>
I was talking with InPhase about the possibility of a generic XML import, which would be able to import SVG.
<JordanBrown[m]>
But a more specialized x = import(svg) would be good too, because hand-interpreting SVG paths would be no fun at all.
<teepee>
yes, that sounds like a very big thing for just general svg
<JordanBrown[m]>
We noted that as we have more general import mechanisms we will need to start thinking about privacy. It would be bad if somebody's OpenSCAD program could snarf up random files from your system and somehow exfiltrate them.
<teepee>
hmm, put the password inside a cube and print that via a print service?
<JordanBrown[m]>
The idea we immediately came up with is that the model could embed the private data in a model, and then you hope that the user posts the model on Thingiverse.
<JordanBrown[m]>
But a later idea is more direct - take the data from the file and use it to control subsequent imports from "/net/villain.com/<data>", where villain.com runs a malicious NFS server that collects up the names of the "files" requested and returns empty files.
<J1A843442>
i remember when people shared their whole disc for p2p and you could find lot of .ost files with all mails
<teepee>
for that I have an idea that's much safer - allow "open SVG" and it will convert to openscad code, same would be possible with Text too
<JordanBrown[m]>
Maybe, but only maybe. I don't want to *convert* my drawing to OpenSCAD. I want to *consume* it.
<teepee>
for that we'd need a basic set of 1d primitives, but it would be a very useful option also for decoupling from things like font changes
<JordanBrown[m]>
I want to make a change in Inkscape, save, switch to my OpenSCAD window, F5.
<teepee>
yeah, but it mostly falls out from existing stuff already
<teepee>
it's just neater than meshed polygon export - final result is pretty much the same though
<JordanBrown[m]>
Yes, the "import by id" feature is the only part missing for my project.
<JordanBrown[m]>
With a conversion style, you'd have to make the change in Inkscape, save, switch to OpenSCAD, reload, save the converted file, switch to the other tab where the "framework" lives, F5.
<teepee>
I was thinking of today looking at what changes remain and maybe get that in now, but did not get very far yet
<teepee>
JordanBrown[m]: for that part of the workflow the direct import is definitely the way to go
<JordanBrown[m]>
I haven't looked at the implementation, but operationally it worked great.
<teepee>
it's more the state when posting on thingiverse or archiving the model after print
<teepee>
the implementation is fine as such, the only problem was that it merges layer= and id= as synonyms and that is not a good idea in my view
<JordanBrown[m]>
Concur.
<JordanBrown[m]>
I'm OK with the notion that "a model" might consist of both OpenSCAD files and other files, using whatever tools are appropriate for the job.
<teepee>
especially because the id of the layer is not visible to the user (in inkscape) as far as I can tell
<JordanBrown[m]>
It is certainly visible through the XML editor.
<JordanBrown[m]>
... experimenting ...
<JordanBrown[m]>
... as soon as Inkscape comes up...
<teepee>
you should have an invitation for the github org + the totally secret hush hush santas helpers team :)
<teepee>
there's an integrated xml editor? that probably shows it, but it seems like a bad idea to require that for the normal behavior of the import feature
<JordanBrown[m]>
Edit / XML Editor
<JordanBrown[m]>
But yes, best not to require it.
<JordanBrown[m]>
You do not need it to control the IDs of paths; you can do that with Object Properties.
<JordanBrown[m]>
For layers there doesn't seem to be a really good answer immediately visible - you can use the XML editor to set the ID, or we could respect the Inkscape-specific inkscape:label attribute where they store their layer name.
<teepee>
yes, but not the layer id, so we should read the inkscape:layer property or whatever that's called
<JordanBrown[m]>
Isn't that what I said? (Serious question; I'm using Element as my client and I'm not completely sure that it always sends messages immediately.)
<teepee>
yep, there's no official layer in SVG, even confirmed by someone actually working on the SVG spec in the github discussion :)
<teepee>
you did, but I'm seeing that after my message :)
<JordanBrown[m]>
Huh. My view shows mine first. They're both timestamped 10:03.
<JordanBrown[m]>
But in the absence of an official layer mechanism, it doesn't seem unreasonable to support Inkscape's extension, especially if we play to support others in the future and automagically detect which style is being used.
<peepsalot>
although, i don't think svg technically supports css selectors, but there are xml-specific things like Xpath and Xquery
<JordanBrown[m]>
I don't know enough about SVG structure to have an opinion on whether a more general selector mechanism would be helpful.
<teepee>
yeah that would be cool. I suppose it could be a simple extension to have not only id / layer but also selector
<JordanBrown[m]>
It seems like "id" is obvious enough that it should have first-class support; I wouldn't hold off on supporting it waiting for a more general selector mechanism.
<teepee>
yes, agreed
<teepee>
id selection means "use subtree starting at ID" right?
<InPhase>
teepee, J1A843442, JordanBrown[m]: One idea I had for increased creativity or fun with the calendar would be a pass-the-design game, like where you have one person write each part of a story and you pass it along.
<InPhase>
And since you can edit stuff out of order, a spirit-of-the-game agreement to try to meaningfully utilize the concepts that exist in the design as they are passed in, but innovate new creativity into it from there.
<Scopeuk>
I think we've had grand ideas several times (some sort of assembly that builds over the days etc) but pulling off anything more than the random sample of creativity is difficult and probably needs a project leed
<InPhase>
Door ordering could actually be sequences of this, like maybe 4 doors in a row are 4 innovations of one design, or something like that.
<InPhase>
We've had a few designs that were developed in this manner, but we never really showed the sequence. :)
<InPhase>
(And so far I think only about two hops max.)
<Scopeuk>
I suppose it could be fun on that line to start out with a simple design (all primitives and blocky) then have the days unfold replacing components with something detailed intricate. Alas this is the bit of modeling I'm terrible at
<Scopeuk>
It's a neat concept
<J1A843442>
for(i=[0:24]) import<i.scad>; Ü
<InPhase>
There are multiple ways to go at each step really. Like you could go first and lay out a foundation of an idea. Or you could look at an intricate design and say, "Hey, I think this needs color!" and jazz it up.
<InPhase>
J1A843442: lol
<J1A843442>
InPhase i still have a calendar design where i thought .. maybe you like to find better colors for it (colors are assinged via array)
Guest77 has quit [Quit: Client closed]
<InPhase>
We also don't need to do the whole calendar this way if we don't end up with enough paired interest, or if we get outside contributions. But it could be a component.
<InPhase>
(Or we could jazz up some outside contributions for fun too.)
<J1A843442>
now the cogs of that gear have smiley faces ..
<J1A843442>
maybe if we start with a "submit your contribution to .. " on the website .. and a advent calendar section in the gallery
<InPhase>
Yeah. I've repeatedly said we should have the calendars on the gallery. Maybe I should just put them there instead of repeatedly saying it. :)
<J1A843442>
i think cuz in programming the ! is always in front and as you giving a command to a bot - the brain switches to the "non human language" set
<buZz>
eh?
<InPhase>
And the majority of bots use ! first.
<buZz>
factoid bots dont
<buZz>
they use ? or ! at the end
<buZz>
botsnack!
<othx>
YUM! This is why I love #openscad.
<InPhase>
butshouldntthey?
<InPhase>
It's nice because you wouldn't accidentally type it.
<InPhase>
right?
<InPhase>
othx: right is what I was thinking.
<othx>
InPhase: Okay.
<InPhase>
right?
<othx>
right is what I was thinking.
<InPhase>
ok?
<buZz>
othx: forget right
<othx>
buZz: I've forgotten about right
<InPhase>
:(
<buZz>
spammers--
<buZz>
InPhase: behave
<InPhase>
lol
<InPhase>
I was setting up gifts for the future. :)
<InPhase>
https://openscad.org/gallery.html Feedback please. I feel it's important to list the full title for the primary link to it, for search purposes, so I went with "2019 OpenSCAD Advent Calendar" etc. But I'm also a little sad that it wraps to the next line.
<teepee>
hmm, maybe split into different sections like the book page?
<teepee>
the website layout is really not ideal for anything
<InPhase>
Yeah, I see that works well for the books, but I don't have a mental picture of that for the calendars.
<InPhase>
Unless we'd like, screenshot the calendars, shrink them down, and embed that in an image-heavy list.
<InPhase>
But it's probably nicer for the calendars to exist primarily as their own, as they are nice pages.
<teepee>
yeah, just list of screnshots linking to the real thing
<teepee>
not perfect, but should at least look reasonable
ali1234 has quit [Quit: Leaving]
<JordanBrown[m]>
teepee: sorry, was off looking at something else.
<JordanBrown[m]>
> id selection means "use subtree starting at ID" right?
<JordanBrown[m]>
yes, I would assume so.
<teepee>
that last example on github, shouldn't that read a = module(...) ?
<JordanBrown[m]>
My going-in answer is "it could, but why?".
<JordanBrown[m]>
The real answer is a little more subtle. I assumed that you could utter a module name in expression context and get a reference to that module. I think that's a desirable behavior, but it will require care to avoid namespace issues.
<teepee>
how is it passing the old style module called a as parameter somewhere?
<teepee>
I'm not sure there's a solution for that, and we don't do that for functions yet
<JordanBrown[m]>
Like I said, care would certainly be required in handling the namespace issues, but I *think* that they can be handled.
<teepee>
yes, the problem is if there's a variable called a too
<JordanBrown[m]>
Of course.
<teepee>
function literals work around that topic by not even trying :)
<JordanBrown[m]>
They have a different variation on the problem.
<teepee>
so maybe modules can do that too first and we'll see if there's a nicer option later?
<JordanBrown[m]>
function a() = 0;
<JordanBrown[m]>
a = function () 1;
<JordanBrown[m]>
echo(a());
<JordanBrown[m]>
echo(sin(45));
<JordanBrown[m]>
sin = function(angle) 7;
<JordanBrown[m]>
I need to look at *exactly* what the function stuff does, because I think it comes up with some behaviors that I don't immediately know how to implement... or at least not easily.
<JordanBrown[m]>
But yes, if for whatever reason we can't figure out how to make traditional module names (and builtin module names) work in expression context, we could fall back to requiring that you use anonymous modules and module references.
teepee has quit [Remote host closed the connection]
<JordanBrown[m]>
One comment on the import-svg-by-id feature: if you ask for an id that isn't in the drawing, that should probably be an error. (I had a typo in one of mine...)
<JordanBrown[m]>
To be clear, it isn't the "dp" part that bothers me, it's the "i" part.
<JordanBrown[m]>
since OpenSCAD is dimensionless.
<JordanBrown[m]>
Any idea why we have both "layer" and "layername"?
<teepee>
SVGs are not
<teepee>
nope, using layername gives a deprecation warning
<teepee>
no idea when or why
GuiGUi35 has joined #openscad
<JordanBrown[m]>
Pardon my C++ ignorance, but can std::string take NULL or some other nothing-here indicator, or is an empty string the best you can do?
<teepee>
I would think string can't be null
<peepsalot>
you can make a pointer to string if you want the option to be null. or (std|boost)::optional
<peepsalot>
std::optional requiring c++17 ...
ur5us has joined #openscad
<JordanBrown[m]>
I have really mixed feelings on how many kinds of "empty" there should be. I think JavaScript overdoes it at four, but I'm not sure that one is enough.
<teepee>
for what specifically? the layer name?
<JordanBrown[m]>
and id
<JordanBrown[m]>
I'm not saying that there's a problem
<teepee>
inkscape does not allow empty layer names via GUI
<JordanBrown[m]>
but in C or JavaScript or Python I would use NULL/null/None for "value is not present", and would consider the empty string to be just another string.
<teepee>
I tend to think using empty for none at all is fine
<teepee>
it's possible to give via XML editing I suppose
<JordanBrown[m]>
Like I said, I doubt there is a practical problem.
<teepee>
the C++ way for not present would be the optional peepsalot mentioned
<JordanBrown[m]>
yes
<peepsalot>
also, a Value can be undef, in addition to empty string
<JordanBrown[m]>
yes, but the context here is std::string
<teepee>
with the main question: do we want to support empty id and/or layer
<peepsalot>
i don't really get what the issue is
<JordanBrown[m]>
There's almost certainly no practical issue.
<peepsalot>
if the user doesn't enter a value, then the parameter should be undef
<JordanBrown[m]>
Right. And in the implementation, where it gets turned into std::string, it's currently ending up as the empty string.
<JordanBrown[m]>
Which isn't awful; it just isn't what I would do in C, JavaScript, or Python.
<peepsalot>
then its turned to std::string too soon imo
castaway has quit [Ping timeout: 246 seconds]
<JordanBrown[m]>
At that point it's awfully close to being used in a comparison, so it can't be a lot later.
<epony>
oh, nevermind, indended to type that in a different channel
<teepee>
context is filtering svg import via attributes in the svg file
<teepee>
import("file.svg", layer = "layer-1");
<teepee>
the current code from the PR treats "" same as no-layer and not-specified
Lemniscate has joined #openscad
Furor has quit [Ping timeout: 252 seconds]
<JordanBrown[m]>
Does do the "id selects a subtree" semantic we mentioned?
<teepee>
I think it does yes, according to the test case :)
<JordanBrown[m]>
Is the intent that if you say layer=x,id=y a component is selected only if it is in that layer and it (or an ancestor) has that ID?
<teepee>
it should select the object with id = y but only if it's part of layer = x
<JordanBrown[m]>
ok
<JordanBrown[m]>
The selection logic seems like it's more complicated than it should be, but I'm not immediately coming up with anything better. It seems kind of wrong that the "climb the tree" logic is in two places.
<teepee>
in xml terms, it has some parent with inkscape:label = x and inkscape:groupmode = layer
<JordanBrown[m]>
right
<JordanBrown[m]>
need to go check my paint project
<JordanBrown[m]>
It's not new, but it's bothersome that the context is passed around as a void * instead of type-safely.
J1A84344249 has joined #openscad
<JordanBrown[m]>
Is there a way to get github to show the actual text of the svg file, rather than displaying the resulting image?
<JordanBrown[m]>
I think I would want nonexistent layers and nonexistent IDs to be errors.
J1A843442 has quit [Ping timeout: 252 seconds]
<JordanBrown[m]>
Otherwise, looks reasonable.
<teepee>
click the <> button top right
<JordanBrown[m]>
Oh, a stupid little thing: in shape.h, looks like 42 should be indented.
<teepee>
not sure, I think the namespaces don't introduce indents
<JordanBrown[m]>
Ah, I looked at the <> and it tooltip said "display diff", and I said "I don't want to see the diff, I want to see the whole file".
<teepee>
but I suppose I can run the autoformat anyway :)
<JordanBrown[m]>
If it's not C++ or OpenSCAD convention, shrug... I just looked at { ... } and normally that makes an indent.
<teepee>
yes, namespaces are special as they are often around the whole file and having 3 namespaces indenting 3 times would be annoying
<JordanBrown[m]>
It's unfortunate that std::map did not get "contains" until C++20. I might use .count() instead of .find() for a presence test, but either is OK.
<JordanBrown[m]>
My only substantive question is whether a nonexistent id or layer should be considered an error, or should just yield nothing.
J1A84344249 is now known as J1A84
<teepee>
and boost in ubuntu 18.04 is too old for boost::optional.has_value() very annoying
<JordanBrown[m]>
Having already made a typo that I didn't notice until I noticed that one piece of the model was missing, I'd vote for "error".
<teepee>
it feels like a filter, so error is a bit strange
<JordanBrown[m]>
Is it a filter, or a lookup?
<JordanBrown[m]>
On, more practically, how often would you really want to select a nonexistent layer/id and get nothing?
<JordanBrown[m]>
I mean, I suppose it's possible if you have a bunch of similar files, some of which include a particular component and some of which don't, but that seems pretty exotic.
<JordanBrown[m]>
Also, if you start out with "error" and people come up with use cases, it's easy to back off. Not so much the other way.
snaked has joined #openscad
J1A8431 has joined #openscad
J1A84 has quit [Ping timeout: 252 seconds]
<teepee>
there isn't really a good way to do that with that selection logic
<teepee>
problem is *empty* is not that easy either ;-)
e2k has quit [Ping timeout: 246 seconds]
e2k has joined #openscad
<JordanBrown[m]>
It looks like at import_svg.c 118 you can look to see whether the std::vector has any entries.
<JordanBrown[m]>
Also I don't entirely follow how the selector stuff at 93 et seq works, but it seems to have access to that function's local variables; it could set flags when it matched a layer or an id.
<teepee>
yes, but this will also contain things like svgpage or groups
<teepee>
hmm, yeah, the match count might work
<JordanBrown[m]>
If nothing else it looks like executing like 187 means you have something. And probably 185 and maybe 182.
teepee has quit [Ping timeout: 258 seconds]
teepee has joined #openscad
<linext>
i've been slacking a bit with working on 3dcustomizer.net
<linext>
i made the mouse cursor charge for the entire page while rendering occurs
<linext>
if preview mode could be converted in some way, that would be great, but i realize full opengl is not ready for the web
<linext>
maybe i should look through the code and see if there's anything i can do to make it easier
<linext>
i'm surprised there isn't a way to emulate the opengl commands to run on the CPU