Console #166 -- Interview with Ray of raylib: easy-to-use library for videogames programming
Featuring pingfs, CodeMirror, and Trilium Notes
🤝 Sponsor
This space is reserved for sponsors that support us to keep the newsletter going! Want to support Console? Send us a note at osh@codesee.io
🏗️ Projects
Browse through open source projects on OpenSourceHub.io, add your project to get more exposure and connect with other maintainers and contributors!
💻 CodeMirror
CodeMirror is a versatile text editor implemented in JavaScript for the browser. It is specialized for editing code, and comes with over 100 language modes.
language: JS stars: 26026 issues: last commit: 1 day
repo: github.com/codemirror/codemirror5
site: codemirror.net/5
✉️ pingfs
pingfs "True cloud storage" is a filesystem where the data is stored only in the Internet itself, as ICMP Echo packets (pings) travelling from you to remote servers and back again.
language: C stars: 2823 last commit: 2020
repo: github.com/yarrick/pingfs
✍🏻 Trilium Notes
Trilium Notes is a hierarchical note-taking application with focus on building large personal knowledge bases.
language: JS stars: 22033 last commit: 1 day
repo: github.com/zadam/trilium
🎮 raylib
raylib is a simple and easy-to-use library to enjoy videogames programming.
language: C stars: 13948 last commit: today
repo: github.com/raysan5/raylib
site: raylib.com
Join thousands of other open-source enthusiasts and developers in the Open Source Hub Discord server to continue the discussion on the projects in this week's email!
🎙️ Interview with Ray of raylib: easy-to-use library for videogames programming
Hey Ray! Thanks for joining us! Let us start with your background.
I’m from a town near Barcelona, in Spain. I’m an Electronic Engineer with a Master's degree in Electronics. At some point in my student career I decided to change path and I got a Video games Development Master degree in UPC, Barcelona.
Right after my studies, I got a job at Electronic Arts, as an Integration (Localization) Engineer. I’ve been in the videogames industry since then, for the last 10 years more involved in gamedev education and personal projects.
I learned to program in the Electronic Engineering career, mostly to code low-level hardware like microcontrollers and PLCs.
I like C, I’ve been coding with it extensively for the last 10 years, but I also like C# and JS. The framework I like the most is XNA/MonoGame, I started making games with it. raylib is highly influenced by XNA and C#.
What’s your most controversial programming opinion?
No strong opinions on programming, it’s a very extensive world, anyone can enjoy it in the way they want.
What is your favorite software tool?
I like raylib a lot. Besides that, I like Notepad++, I think it’s an amazing editor.
If I gave you $10 million to invest in one thing right now, where would you put it?
Undoubtedly, in raylib technologies. I’d love to build a sustainable business around raylib, providing high-performant tools and technology to companies requiring it but unfortunately at this moment, I do not have enough resources to make it sustainable.
Why was raylib started?
It was a tool created for education. When I started teaching gamedev programming to young art students, I needed a simple and easy-to-use tool to teach coding, but I couldn’t find one that fit my needs and methodology, so I created raylib. I wanted students to actually write code with the minimum abstraction layers, to teach what a compiler is and how computers work in the lower level.
How does raylib work?
raylib is a thin layer over OpenGL. It basically initializes a windows and a graphics device with an OpenGL context where users can draw. It also provides several simple functions to draw shapes, text, models… raylib makes many assumptions to make things as easy as possible for the user.
What motivated you to write raylib in plain C
Because I decided to teach a non-object-oriented language to my students and C was a good candidate. I had used it previously in microcontroller programming and I really enjoyed it.
Where did the name for raylib come from? Is it because of your name?
Yes, my nickname is Ray, a short from Raymon, English version of my name Ramon. I used RAY on the arcades for the high-scores because most games were limited to 3 letters. Many arcade machines in my town were filled with RAY in the high-score table! I decided to use that same nick for Ray’s library, so raylib. I also decided to stylize it all lowercase because I’ve seen many C libraries use to do it.
My favorite games at that time were The King of Fighters series (specifically 97 and 98) and also Metal Slug series.
Who, or what was the biggest inspiration for raylib?
raylib is highly inspired by BGI library and XNA library.
Are there any overarching goals of raylib that drive design or implementation? If so, what trade-offs have been made in raylib as a consequence of these goals?
Simplicity, I try to keep raylib as simple as possible for the user but also the source code for anyone willing to review it.
About tradeoffs, skipping parameters from some functions or predefining some values internally. Also passing parameters by value vs reference. Many many hours of design and redesign, simplicity imply a high development cost.
What is the most challenging problem that’s been solved in raylib, so far?
I’m especially proud of rlgl module, an abstraction layer over multiple OpenGL versions that let the users program in the old immediate-mode-style while using modern OpenGL.
What was the most surprising thing you learned while working on raylib?
Probably that C could be compiled to WebAssembly to run on web. :D
The raylib examples collection is extensive, with over 120 code examples. How did you curate and develop these examples?
They were developed and reviewed for 10 years. I just put many hours in the process.
What is your typical approach to debugging issues filed in the raylib repo?
I categorize them first, and I try to prioritize them by severity. Sometimes I just dispatch the easy-fix ones first.
What is the release process like for raylib?
No hard milestones, just keep working on it with some future wishlist for the project and when I fix some specific issues or add some desired new features I get ready for a new release. The release process is really costly and time-consuming. Many things to test, review and do. I got a tasks list only for the new version release process.
What has been the most rewarding aspect of maintaining raylib so far?
Undoubtedly, the community and the great adoption of the library. Many users all around the world show amazing projects on raylib Discord daily. Seeing those projects and the developers enjoying them is really fulfilling.
How do you balance your work on open-source with your day job and other responsibilities?
For the last 10 years I tried to balance my work as a teacher with raylib/tools development, but the projects grew too much and it was very difficult. Two years ago, I quit teaching to work full time on my startup project: raylib technologies.
On raylib technologies I develop tools and technology for gamedev using raylib and other libraries created by me. It helps to maintain and improve raylib while building interesting tools using it. Unfortunately, this model is not sustainable and lately I’m considering getting another day job.
Have you ever experienced burnout? How did you deal with it?
I don’t think so, but there are moments when I feel more productive and creative than others. Some days I can work many hours and do a lot of things while other days I hardly do anything. I also try to do activities that do not involve electronic devices to disconnect, such as woodwork, playing guitar or cooking.
Do you think any of your projects do more harm than good?
Hopefully, my projects don’t do any harm! Most of my projects are tools for games development, maybe they can stress some user when things do not work as expected… :D
What is the best way for a new developer to contribute to raylib?
Read the documentation, check the examples, try it, create some small game with it, check the open issues…
How do you prioritize new features and improvements for raylib? What factors influence your decision-making process?
Keeping the library simplicity and maintainability is the main goal, so, I try to minimize complexity (avoid big new features) and focus on issues solving.
What motivates you to continue contributing to raylib?
Seeing it growing and being used by more people all around every day is a good motivation. Using it for commercial tools development also helps.
Are there any other projects besides raylib that you’re working on?
Yes, there is a full ecosystem of tools and libraries I work on and maintain, some use raylib and others not.
Libraries: raygui, rres, rpng, rini, rlkv…
Tools: rFXGen, rGuiStyler, rGuiLayout, rGuiIcons, rrespacker, rTexViewer, rTexPacker, rImageShield, rInstallFriendly, rIconPacker, rQuizzer, rTextEditor…
Do you have any other project ideas that you haven’t started?
I get many new ideas almost daily, but I try to only start projects that I will finish (or at least to some degree).
Where do you see software development heading next?
I see software is more bloated and less performant every day, considering actual hardware. I got my doubts if that model is sustainable and how long it could last.
Where do you see open-source heading next?
I neither see the open-source current model as a sustainable alternative. Software development is never free, it always implies a high cost for someone. Many great open-source projects are abandoned due to lack of funding.
What is one question you would like to ask another open-source developer that I didn’t ask you?
Do you think the open-source model is sustainable?
Want to join the conversation about one of the projects featured this week? Drop a comment, or see what others are saying!
Interested in sponsoring the newsletter or know of any cool projects or interesting developers you want us to interview? Reach out at osh@codesee.io or mention us @ConsoleWeekly!