←back to thread

241 points fschuett | 1 comments | | HN request time: 0.207s | source
Show context
ciroduran ◴[] No.45662771[source]
Raylib's author was very happy to announce that you can compile an entire raylib program with no dependencies other than, say, being a win32 app https://x.com/raysan5/status/1980322289527976202
replies(4): >>45663602 #>>45665595 #>>45666276 #>>45667634 #
smlacy ◴[] No.45663602[source]
but ... why?
replies(7): >>45663616 #>>45663685 #>>45664169 #>>45665350 #>>45665446 #>>45667159 #>>45669821 #
zamadatix ◴[] No.45663685[source]
The mantra for the library is "raylib is a simple and easy-to-use library to enjoy videogames programming." It's for hobbyist, learners, tinkerers, or just those that want to enjoy minimalistic graphics programming without having to deal with interfacing with modern machines yourself.

The default Windows installer bundles the compiler and a text editor to make poking at C to get graphics on the screen (accelerated or not) a 1 step process. Raylib is also extremely cross platform, has bindings in about every language, and has extra (also header only, 0 dependency) optional libraries for many adjacent things like audio or text rendering.

When I first started to learn C/C++ in the 2000s I spent more time fighting the IDE/Windows/GCC or getting SDL/SFML to compile than I did actually playing with code - and then it all fell apart when I tried to get it working on both Linux and Windows so I said fuck it and ignored that kind of programming for many years. Raylib is about going the opposite direction - start poking at C code (or whatever binding) and having it break and worry about the environment later when you're ready for something else.

replies(1): >>45665563 #
pjmlp ◴[] No.45665563[source]
I never ever bothered to compile SDL/SFML from source, what is so hard dumping the binaries into a folder, set the include paths for the compiler and linker?

Although I may imagine newbies may face some challenges dealing with compiler flags.

replies(3): >>45665758 #>>45666120 #>>45669139 #
1. fsloth ◴[] No.45666120[source]
Raylib is a pedagogical tool among other things and as such I think a kind of first principles approach has it’s merits.

But I also just use the precompiled libs :)