Pinned toot
Pinned toot
s-ol boosted

@nff do you know how to drone like this? I would love to learn drone in general, this sounds sooo fun

hmmm, I can create rects from Janet just fine, but all other svg elements don't show up. But I'm using the exact same C++ methods to create them and it works?? (spoiler: i'm probably not, I just haven't found the difference yet)

First proper Janet scripts are running within Inkscape! :)

made a little toolbar for selecting the script file to run, and got my first lines of janet code executed by inkscape! No API that interacts with the canvas yet though.

Code is now up at

Inkscape is is quite a big repo (1.8G .git dir), so if you want to be gentle on my server maybe get the master branch from gitlab and then pull mine ;)

/cc @KnowPresent

The glitch when rotating is probably because my code redraws the document every frame, and normally it seems inkscape just snapshots the canvas and rotates a pixel image.

When zooming etc there is also noticeable lag on all UI. I think I'm still doing something wrong in some of the IMGUI code and could probably shave off a frame or so by doing stuff in the right order. Also I'm pretty sure that it doesn't redraw at even close to 60fps, which would minimize the effects of that as well

I also finally figured out all the different transforms going on from GDK-event-space to viewport space and to document space. Thanks to that I now have two virtual layers that svg elements can be added to; either in document-space (like the black rectangle) or in UI-space (like the square handles).

Notice how the handles don't scale or rotate as the viewport is zoomed and rotated, while the black rectangle does.

here's the 'script' running that interaction. My arrow is not showing up yet :D

More good progress today :)

The script is still hardcoded and in C++, but with the other progress of today that could/should change soon :)

/** @brief Equality operator.
* This tests for exact identity (as opposed to are_near()). Note that due to numerical
* errors, this test might return false even if the points should be identical. */
bool operator==(const Point &in_pnt) const {
return (_pt[X] == in_pnt[X]) && (_pt[Y] == in_pnt[Y]);

I guess it's just precision? seems odd though, even

(= (geom/point 1 1) (geom/point 1 1))

is false

good progress, just a little weirdness on the comparison...

Got a basic janet binding to Inkscape's Geom::Point working (only basic arithmetic right now).

ok, WSL is decently awesome; gets kakoune to run with my full config in a matter of 10min + a reboot

Thinking I might go with, or maybe Lua and
There was some good Lisp/Scheme suggestions, but I'm not good at the car/cdr stuff and it wasn't clear how to add custom types with operator overloading, which I definitely want (for vectors, transforms).

Janet's C API is really clean and it seems simple to implement, so I'm thinking I'll go with that. Lua is obviously also proven but I never worked with its C API

The i7-6700 die is 122mm² big (, which makes an almost exactly 11mm edge length, assuming it is square.

11mm / 20nm = 550 000 discernable details on each axis

550 000 * 0.2mm = 110m

so that's it, the printout would be a square 110m on each side, or a bit more than a hectar.

And you would still have to crouch down to see the 0.2mm details everywhere...

I don't know much about CPU series, so I'll just pick a random Intel CPU from WikiChip: lets go with the i7-6700. It's rather recent but by far not the latest and smallest.

It's manufactured using Intel's "14nm process". Sizes of different features produced using this process can be found here:

So apparently "fins" are super small, but they don't seem terribly important (?) so let's use the Gate Length as our minimal feature: 20nm.

Show more

Revel in the marvels of the universe. We are a collective of forward-thinking individuals who strive to better ourselves and our surroundings through constant creation. We express ourselves through music, art, games, and writing. We also put great value in play. A warm welcome to any like-minded people who feel these ideals resonate with them. Check out our Patreon to see our donations.