HNHacker News
TopNewBestAskShowJobs

morio

339 karma · joined November 3, 2015

submissionscomments
morio··on Sherline Tools Is Going Out of Business
I own a lathe and mill from them, both converted to CNC. Sadly their products have changed little in 30+ years. Their precision parts have a use in some applications but it's vastly overshadowed by the cheap parts available from Asia (including India now).

3D printers, laser cutters and benchtop CNC routers have the taken over the lion share of what hobbyists (and some professionals) used to do with these machines. Mine are just collecting dust while my 3D printers crank out parts every day.

morio··on Rasterizer: A GPU-accelerated 2D vector graphics engine in ~4k LOC
Sorry to be blunt, that C/C++ code is crustyyy. Just to start with run this through an decently complete clang-tidy profile and fix all errors and warnings. That should become part of your build. The longer you hold out on that the harder it will be. Your code has no provisions to handle fuzzed/corrupted content. Maybe a better idea would be to switch this entire code base over to Rust.

Consider modern C++ practices as outlined here: https://github.com/cpp-best-practices/cppbestpractices/blob/...

morio··on Faster, easier 2D vector rendering [video]
I haven't looked at this recently but from what I remember rendering from SDF textures instead from simple alpha textures was 3-4 times slower, including optimizations where fully outside and inside areas bypass the per pixel square root. Of course SIMD is a must, or at least the use _mm_rsqrt_ss.
morio··on Faster, easier 2D vector rendering [video]
Yeah, there is an entire science on how to do font rendering properly. Perceptually you should even take into account if you have white text on black background or the other way as this changes the perceived thickness of the text. Slightly hinted SDFs kind of solve that issue and look really good but of course making that work on CPUs is difficult.
morio··on Faster, easier 2D vector rendering [video]
Not really, it's the same color primaries just without the non-linear transfer function.
morio··on Faster, easier 2D vector rendering [video]
You got a long way to go. Writing a rasterizer from scratch is a huge undertaking.

What's the internal color space, I assume it is linear sRGB? It looks like you are going straight to RGBA FP32 which is good. Think how you will deal with denormals as the CPU will deal with those differently compared to the GPU. Rendering artifacts galore once you do real world testing.

And of course IsInf and NaN need to be handled everywhere. Just checking for F::ZERO is not enough in many cases, you will need epsilon values. In C++ doing if(value==0.0f){} or if (value==1.0f){} is considered a code smell.

Just browsing the source I see Porter Duff blend modes. Really, in 2025? Have fun dealing with alpha compositing issues on this one. Also most of the 'regular' blend modes are not alpha compositing safe, you need special handling of alpha values in many cases if you do not want to get artifacts. The W3C spec is completely underspecified in this regard. I spent many months dealing with this myself.

If I were to redo a rasterizer from scratch I would push boundaries a little more. For instance I would target full FP32 dynamic range support and a better internal color space, maybe something like OKLab to improve color blending and compositing quality. And coming up with innovative ways to use this gained dynamic range.

morio··on Programmer in Berlin: Culture
The majority of US homes use a split phase setup. So 240V is readily available and in fact the only way you can run central AC. Nominal voltage of a single phase is 120V. Technology Connections has an entire video about it.
morio··on C++ proposal: There are exactly 8 bits in a byte
One example from the software side: A common thing to do in data processing is to obtain bit offsets (compression, video decoding etc.). If a byte would be 10 bits you would need mod%10 operations everywhere which is slow and/or complex. In contrast mod%(2^N) is one logic processor instruction.
morio··on I like the RP2040
I find hand soldering QFN is faster, easier and more reliable than (T)QFP once you got enough practice. If you need to rework the QFN part the key is to FLOOD the footprint with good solder flux from a syringe. Do not use one of those flux pens, those do not dispense enough flux.
morio··on Agricultural IoT system sends power through the soil
In the US, the neutral and ground are generally bonded in your breaker panel.
morio··on Car insurance in America is too cheap
To be clear: I already had my old car insured with them for several years, so I just removed the old car and added the new car. I am also 50+ with no negative record and a garage in a single family home.
morio··on Car insurance in America is too cheap
I concur, bought insurance for a new car early January and got it instantly using esurance.com (Allstate) by just entering my VIN. Yes, I am in SF/Bay Area.
morio··on Money pours into new fabs and facilities
Ok, I'll bite. Uploaded my gerbers using https://instantdfm.bayareacircuits.com/ Site does not respond for 10 minutes+ which is is not a good start. It's instant on the Chinese sites.

Quote for 100 boards (ENIG) on Bay Area Circuits, 10 days lead time, excluding shipping: $1000 ($1244 for 5 days lead time)

Todays quote for exact same 100 boards (ENIG) on pcbway.com, _including_ DHL shipping cost, 2 days lead time: $148 (shipping to Bay Area is usually 2 days with DHL, so really 4 days lead time). I've never had any quality issues and my boards have fine pitch 0.4mm BGA parts.

Yeah no, not even close. Certainly not marginally higher.

It's slightly cheaper than oshpark.com, they want $15 a board.

morio··on The 1990s Amiga with Video Toaster has a VFX cool factor that endures today
The short answer is yes. The long answer is that most of the VideoToaster software and hardware were specifically designed for the Amiga hardware architecture and therefore did not easily port to other systems. The extension card was Zorro II and the performance critical software was written in 68k assembly. In some cases the assembly code is written in such a way that it depends on cycle exact sync with the video signal. Original source code is on github.com, search for OpenVideoToaster.
morio··on The state of open-source in 3D printing in 2023
You can buy Prusa MK3 kits from Aliexpress for half the price of the original. I bought a kit from Prusa and one knockoff from Aliexpress. Parts wise they are 100% the same and perform the exact same way. Do I feel bad about it? Kind of. The Chinese seller certainly did not put R&D into any of it. And being in China makes sourcing much easier.
morio··on Opening the North American charging standard
Huh? CCS1, CCS2 and NACS are DC. You are probably thinking Type 2 (Europe) which is indeed 3 phase and j1772 (US) which is single phase.
morio··on Does Rust belong in the Linux kernel?
> Rust is massively more expressive.

The question is not if Rust is more expressive but if C is expressive enough for the Linux kernel. So far there is no evidence that Rust adds any value here. And if C is missing certain features, they can be added. It looks like ISO is looking at that very thing in C2x and beyond.

morio··on Apple CEO Tim Cook 'secretly' signed $275B deal with China in 2016
Sadly anything can be politicized these days.
morio··on California's Dixie Fire Is Now the 2nd Largest in State History
These extreme fire events extend across the entire Northern hemisphere right now (Oregon, Washington, Montana, Greece, Turkey, Siberia etc.). Blaming California specific forest management practices is disingenuous at best.
morio··on size_t-to-int vulnerability in Linux’s filesystem layer
What kind of false positives are you seeing with gcc?

Personally I have never seen gcc spitting out a false positive. IMO it's always a good idea to explicitly downcast even if you know that it's 'safe'. That way someone else will see instantly what's going on. The fact that Rust requires it should tell us something.

morio··on Why doesn't capitalism produce good kettles?
Huh? You just pointed out what capitalism is about.
morio··on Texas was minutes away from months-long power outages, officials say
There are many failure points but one are the high voltage carrying power lines themselves.

As they reach their capacity they start to droop quite a bit, which in itself can cause issues like touching something they usually would not.

Because HV lines are made from aluminum they loose some of their strength as they are heated up. Above 100C or so the aluminum anneals which means strength is lost. Now you just need some wind shaking those lines and the whole thing breaks. If you have reached that point you likely have to replace the entire length of the HV line.

Of course the cold weather counters some of this. But only to a certain point.

If just one HV line fails you now have to deal with the cascading effect as the current is load balanced on the remaining HV lines.

morio··on States bring action against Google under federal and state antitrust laws [pdf]
Thanks for the link. Though as a Google employee you should probably refrain from any further public comments.
morio··on Raspberry Pi 400 Desktop PC
I agree 100% with this. I have a fairly large tinker shop with 20-30 different machines and initially bet on the Pi platform to do CNC/Octoprint/robotics/etc controls, thinking I should standardize. Most of the Pis failed with storage issues eventually; be it eMMC, microSD or USB flash drives. Since then I've moved on to x86 based industrial motherboards which ended up costing about the same when you include everything. Zero problems since then. And boot times are now measured in seconds, not minutes.
morio··on Petit Fat File System Module
The site does not have a valid SSL certificate. Some browsers will block it.
morio··on Petit Fat File System Module
Never said it should be a requirement. But downloading a .zip file from a site which does not have a valid SSL certificate nor supports SSL in the first place does not instill confidence. Software security is a thing.
morio··on Petit Fat File System Module
Why does the author not just put it on github/gitlab/... instead of only offering a .zip? It's 2020 last time I checked.
morio··on Logic board with 20 USB3 ports
I develop hardware. At any given time I have 3 programmers, various charger cables, usb to serial cables, logic analyzers, a mouse, a spacemouse (for CAD), flash drives, 2 x label printer (strip and shipping) and various other stuff plugged into my 12 port hub. And I still have to switch them out due to lack of ports. And hubs don't play well with high speed USB3 based logic analyzers.
morio··on Plywood: A New Cross-Platform Open Source C++ Framework
Browsing over the code I'd say it's solid and seems to have been used in production. Just about the right amount of abstraction for practical use.

Some parts could be replaced by standard C++ library functionality by now. My biggest issue so far: Use of bare pointers, especially in parser code. This should not appear in new code written in 2020. I'm kind of baffled by that as he seems to use stuff like std::move.

This is no replacement for either Unreal or Unity for sure, it's pretty basic in functionality.

morio··on DHS plans urgently needed to address identified challenges before 2020 elections [pdf]
Agreed, I see a lot of "if Estonia can do online voting, why can't we?" When I talk to some of these people, who work in the SV as software engineers, I realize not everyone has a wide ranging context on security and privacy. Not everyone religiously attends or watches DEFCON presentations...

There is also a continuous push to make results available faster, basically instantly. The media is as guilty as everyone else here. Like we can't wait for a few days for results.

Lastly reducing the amount of total paid workers and volunteers in the field to reduce costs likely looks like a shiny object in many managers eyes.

Page 1 of 2Next →