News for hackers. Stuff that matters.

vineek

Re:C-Macs – a pure C macOS application on Friday April 19, 2024 @01:03PM (#40089273)
Very nice. In similar fashion, a few years back I set out to create Wuhoo.

Wuhoo loosely stands for W indows U sing H eaders O nly. It is an attempt to create a single-header library (in the spirit of STB) for graphics related window management, compatible with both C and C++.

It works on Windows, Linux and Mac.

https://github.com/ViNeek/wuhoo

Re:Programming breakthroughs we need on Wednesday August 17, 2022 @11:13PM (#32504834)
Very nice article. Literate programming might have some interesting features in this direction. The not so obvious thing is how it can scale.

A very good example of literate programming can be found in the fantastic book Physically Based Rendering [1]. It also has a preface discussing it [2].

The authors write a full physically-based rendering system in a declarative fashion. This approach has also led to a nicely adapted web-based version of the book [3].

Although we have successful examples like TeX and HTML, it would be very interesting to see this approach explored further by a more modern language or programming methodology.

[1] https://pbrt.org/

[2] https://www.pbr-book.org/3ed-2018/Introduction/Literate_Prog...

[3] https://www.pbr-book.org/3ed-2018/contents

Re:Modern C++ Won't Save Us (2019) on Tuesday April 27, 2021 @02:16AM (#26952628)
The ability to occasionally opt-out is both a feature and a necessity because certain systems are inherently unstable and offer varying guarantees. I’m arguing for an opt-in feature in C++. Of course there is no panacea.
Re:Modern C++ Won't Save Us (2019) on Monday April 26, 2021 @04:33AM (#26940497)
I completely agree with the points from this article. It is fundamentally infeasible to make all C and C++ code safe. The main reason, PAST code. There are countless lines of unsafe code already written. However, there is nothing magical about Rust's facilities (e.g. borrow checker) that make them inapplicable to FUTURE C and C++ code. I believe this is the only way forward for C and C++. They need to offer mechanisms that guarantee that any code written today can be provably memory and thread safe. That of course requires yet another tool in the myriad of tools that exist for C and C++.
Re:Graphics Programming Weekly on Monday February 15, 2021 @03:37AM (#26140483)
To get a quick feel for ray tracing, I would also suggest https://rayground.com/. It has a lot of ray tracing projects, ranging from basic samples to complicated scenes. They can all be run in your browser.