Rewriting Raylib in JavaScript

  Рет қаралды 25,486

Tsoding Daily

Tsoding Daily

3 ай бұрын

Previous Episodes: • Raylib.js
References:
- Tsoding - raylib.js - github.com/tsoding/raylib.js
- surma.dev/things/c-to-webasse...
- github.com/quick-lint/quick-l...

Пікірлер: 81
@blackhaze3856
@blackhaze3856 3 ай бұрын
Next project: Use raylib with React.
@soniablanche5672
@soniablanche5672 3 ай бұрын
next project: rewrite raylib.js in React
@null-calx
@null-calx 3 ай бұрын
wait until he rewrites React in raylib
@exosdel
@exosdel 3 ай бұрын
Raylib with scratch
@kaiserzico
@kaiserzico 3 ай бұрын
rewrite in rust
@unknown_error101
@unknown_error101 3 ай бұрын
"And unfortunately, I do care" felt
@marciocarvalho5849
@marciocarvalho5849 3 ай бұрын
man, your videos give me hope that being a dev/swe can be fun in spite of all the work bs, thanks from brasil
@NoBrainCode
@NoBrainCode 3 ай бұрын
very big thanks from brazil, no matter what language or project i am always excited to see what he is programming
@prof.dr.davidbuzatto
@prof.dr.davidbuzatto 3 ай бұрын
Totally agree! Take a look in my channel, I'm doing some recreational programming too.
@dickpiano1802
@dickpiano1802 3 ай бұрын
This is quickly becoming the best channel on KZfaq
@sanjaux
@sanjaux 3 ай бұрын
Always been
@mycode0
@mycode0 3 ай бұрын
Always has been
@user-qu7nq3uo3w
@user-qu7nq3uo3w 3 ай бұрын
you fixed lua, now you fixed raylib
@labsendeyshent
@labsendeyshent 3 ай бұрын
And now he will fix Go
@PeterJepson123
@PeterJepson123 3 ай бұрын
Loved the intro about simplicity and completely agree. Simplicity is way more interesting than complexity. Even complicated systems should be built from simple components.
@janhorak5363
@janhorak5363 3 ай бұрын
I really love watching this. I love the way you think about problems and explain it out loud..
@satchelfrost6531
@satchelfrost6531 3 ай бұрын
A while back I had wanted to try out raylib and nob to make a point cloud renderer. I actually made my nob.c file support web via emscripten. I was thinking maybe I should make a pull request for musializer to do the same, now I'm glad I didn't do that. On a separate note, I've been working on a project which uses nob, and sort of copies the raylib API, but instead uses Vulkan as a backend. It's been a fun experiment, but I'm not sure how far it will go. Anyway, thanks for all you do, you are an inspiration.
@kaltwarraith5172
@kaltwarraith5172 3 ай бұрын
Your reaction to the tbl import is exactly my reaction to a lot of modern design choices
@blastygamez
@blastygamez 3 ай бұрын
Idk but ur videos are always so great!! The stuff u do is amazing and we should be thankful 👍
@Mozartenhimer
@Mozartenhimer 3 ай бұрын
These streams got me to try out Raylib now I ❤ Raylib.
@christianbouwense4702
@christianbouwense4702 3 ай бұрын
Same, Raylib is easily the best tech I've ever used, so glad I found it
@mattshu
@mattshu 3 ай бұрын
11:23 perfect curb your trombone ever
@delusionalaar4031
@delusionalaar4031 3 ай бұрын
Love your videos so much. They remind me swe can be fun. Just wish I could watch more.
@oumardicko5593
@oumardicko5593 3 ай бұрын
the more i watch your videos the more i feel stupid xD. keep the good work
@XORfun
@XORfun 3 ай бұрын
Omg thank you for this work!
@MikAlexander
@MikAlexander 3 ай бұрын
DO IT. We were discussing raylib js performance earlier today on discord.
@1Thor61storm8
@1Thor61storm8 3 ай бұрын
About simplicity and using libraries, I would add this to the discussion: I think is not only about going to market faster, it is also a way of externalising the cost of maintaining a production ready piece of code. This allows companies to be lighter, improving margins.
@glowiak3430
@glowiak3430 3 ай бұрын
Will you check out Beef? It's like Java or C#, but with manual memory management, and compiled. And it has a raylib binding.
@anonymousanon4822
@anonymousanon4822 3 ай бұрын
I love these videos but I have a minor complaint. KZfaq seems to compress the hell out of these. More than I notice on any other coding videos. I think it might have to do with how dark it is (which I obviously don't expect you to change). But I heard some time ago that uploading Videos in 4k leads to KZfaq using a better compression algorithm for all the versions, so even the 1080p ends up looking a lot better. Just hearsay, maybe shit changed. And also I get if 4k is entirely impractical for you due to file size or whatever. Just some feedback, do with that what you will. I will watch and enjoy anyways :)
@lolcat69
@lolcat69 3 ай бұрын
I wasted to make a web lang for a long time, should I make a compiler for one of my programming languages to Wasm? I already tried compiling my Brainfuck VM to wasm and it was really simple to implement, so I might check that :)
@testeTestandomuitosTestes
@testeTestandomuitosTestes 3 ай бұрын
I don't know if you read the comments, but it would be possible one day to make a video about Glib who created the GObect library that is used in Gnome. Thank you in advance for your videos, despite having a lot of difficulty following them, I never stop watching them. thanks!!! \o/
@valcron-1000
@valcron-1000 3 ай бұрын
The font rendering will not look the same by default due to the usage of AA. I think you can fix it with a mix of CSS + textRendering = "geometricPrecision"
@11WicToR11
@11WicToR11 3 ай бұрын
is there some other way to implement graphics in browser? Maybe some gpu ? Is anything else possible? Maybe you could write less js and more shaders or sth like that
@christianbouwense4702
@christianbouwense4702 3 ай бұрын
Yeah there are a couple APIs (not sure if API is the correct word), WebGL and WebGPU come to mind. They can be used directly, or you can use libraries that use them like three.js or babylon.js
@gogo-pj2lm
@gogo-pj2lm 3 ай бұрын
41:39 i think it makes sense to use the visibility attribute feature. Build script can then be modified less frequently, making it more stable and "production-ready" 😂
@bladman9700
@bladman9700 3 ай бұрын
next rewrite linux kernel in JS
@alurma
@alurma 3 ай бұрын
Google Linux JS
@liketheninja8658
@liketheninja8658 3 ай бұрын
@@alurma Holy emulator
@DevlogBill
@DevlogBill 3 ай бұрын
Is the developer experience better with C and Raylib? Or if you choose a programming language like Python with Raylib is the developer experience better? Or worse? I am guessing since Raylib was designed with C. Making games with C and Raylib would be easier compared to making games with Python with Raylib since the library was created with C? When making 2D games with either C or Python is the experience the same? Or are there challenges when using a different programming language?
@roberthickman4092
@roberthickman4092 3 ай бұрын
Doesn't the C version already support multiple backends? Can't you work with that without reimplementing everything in JS? Identify what parts of the CRT are being used, replace those, and write a backend that targets webgl directly via the FFI.
@yehbruh667
@yehbruh667 3 ай бұрын
theo mentioned, less go
@edhahaz
@edhahaz 3 ай бұрын
What about performance, surely the browser isn't performant enough with just using the canvas API to port raylib.
@TsodingDaily
@TsodingDaily 3 ай бұрын
From my personal experience Canvas API is pretty fast. I'm pretty sure browsers use hardware acceleration to implement it. Here is my Game implemented entirely using Canvas API tsoding.github.io/snake-c-wasm/
@reidond
@reidond 3 ай бұрын
it directly uses your gpu api with common gl-like api
@julienc.8562
@julienc.8562 3 ай бұрын
Didn’t watch, but i already love the title
@abdelhakimakodadi3073
@abdelhakimakodadi3073 3 ай бұрын
"Why is it important to be able to modify your dependency? Because you're taking control of them" I agree with that but only in the context of open source. In an enterprise context that doesn't translate very well. Because the dependencies are constantly changing (bug fixes, security patches...), and if you do even the slightest modification to a dependency now you have to become a maintainer of a fork of the dependency. Which is not scalable when you have tons of dependencies.
@dixztube
@dixztube Ай бұрын
lol what’s that folder on the bottom
@Alguem387
@Alguem387 3 ай бұрын
what is the sound name wen he goes: turum turum turum turum plimb?
@user-fr1no2ir3r
@user-fr1no2ir3r 3 ай бұрын
Rarenpo stack, Raylib + React + Node + Postgres
@angelcaru
@angelcaru Ай бұрын
Ravapy: Raylib + vanilla JS + python -m SimpleHTTPServer
@victordvickie
@victordvickie 3 ай бұрын
Implementing musializer in raylib.js?
@TsodingDaily
@TsodingDaily 3 ай бұрын
I'm actually low key planning it. But I don't know for sure yet. We will see. :)
@sancobtw
@sancobtw 3 ай бұрын
⁠​⁠@@TsodingDailyI believe implementing the music visualization can be easy by just using the WebAudio API and more but I think that you would port Miniaudio for JS to avoid rewriting the audio support for musializer, anyways I would love to see musializer for web, amazing videos man!
@RicardoValero95
@RicardoValero95 3 ай бұрын
Tsoding strager crossover 51:00
@colonthree
@colonthree 3 ай бұрын
JS literally never gives up unless it is a syntax error. ;w;
@soniablanche5672
@soniablanche5672 3 ай бұрын
that's because everything in javascript is an object (aka dictionary/hashmap/etc) except null and undefined. Even primitive are objects because they get automatically packed into their object version every time you access a property on them. So the errors are generally accessing a member of undefined or null lol
@edhahaz
@edhahaz 3 ай бұрын
How does emscripten even work ?
@TsodingDaily
@TsodingDaily 3 ай бұрын
I have no idea!
@sarmadajmal3602
@sarmadajmal3602 3 ай бұрын
Study content: 58.2 GB woa!!!
@dixztube
@dixztube Ай бұрын
Lmaoooooooooo
@wasile
@wasile 3 ай бұрын
I wonder why is wasm active by default on all browsers and you don't have any option from settings to disable it, you have to run the browser with a parameter to disable it. Let's say Chromium is open source, but Chrome, Firefox and Edge are released by big corporations. For me, it looks like a security issue made on purpose, like the DNS standard let's say.
@anon_y_mousse
@anon_y_mousse 3 ай бұрын
Firefox is open source, and you can configure it to not use wasm from the about:config page.
@Tigregalis
@Tigregalis 3 ай бұрын
wasm is sandboxed and so it's more secure, though? i must not be understanding your angle, what do you mean?
@wasile
@wasile 3 ай бұрын
@@anon_y_mousse ok. Maybe firefox has this option, but edge or chrome doesn't. I'll search the flag in ff.
@wasile
@wasile 3 ай бұрын
@@Tigregalis wasm has a long list of vulnerabilities, and the list contains only a part of them, some of them will never be published. PS: there are a lot of sandboxed environments that give access to the host machine because of some intentional "bugs". Even images metadata are not safe when loading into browsers, so why to give acces to a "sandboxed" environment from my machine to a powerfull thing like wasm? We don't need it anyway...
@anon_y_mousse
@anon_y_mousse 3 ай бұрын
@@wasile And here I was thinking you just didn't like the convoluted garbage in wasm. I'll have to look into this for sure, but it annoys me that if I disable it certain sites don't even load. The fact that it uses binary blobs would ordinarily be a selling point for speed's sake, but I don't believe that a slow startup time on a game is a true stumbling block if we have encapsulation of the runtime environment and proper caching. Outside of games, I see no reason to use it, and even then it's a bit tenuous if the VM were done correctly. All goes along with what I've been saying about wiping the web clean and starting from scratch.
@Dimkar3000
@Dimkar3000 3 ай бұрын
maybe it's not pixels. Maybe it's another size unit of css.
@regfinley7111
@regfinley7111 3 ай бұрын
@11:15.😆😄🤣
@khuntasaurus88
@khuntasaurus88 3 ай бұрын
I thought the title was a shitpost
@pratikbhujel
@pratikbhujel 3 ай бұрын
Raylib with Livewire and Laravel
@Froggie92
@Froggie92 3 ай бұрын
change your chrome dev tools from hamburger to hotdog
@twenty-fifth420
@twenty-fifth420 3 ай бұрын
My imposter syndrome is tingling rn….. 😂
@jan_in_youtube
@jan_in_youtube 3 ай бұрын
There are things that should never be made. You have ruined my trust in you. XD
@ancentropia3418
@ancentropia3418 3 ай бұрын
WHY
Hare Programming Language
1:39:25
Tsoding Daily
Рет қаралды 45 М.
Hiding Data Inside of Executable Files
1:55:14
Tsoding Daily
Рет қаралды 24 М.
Did you find it?! 🤔✨✍️ #funnyart
00:11
Artistomg
Рет қаралды 97 МЛН
ШЕЛБИЛАР | bayGUYS
24:45
bayGUYS
Рет қаралды 632 М.
Monster dropped gummy bear 👻🤣 #shorts
00:45
Yoeslan
Рет қаралды 13 МЛН
This Release is Insane!
1:25:56
Tsoding Daily
Рет қаралды 49 М.
The Truth about Rust/WebAssembly Performance
29:47
Greg Johnston
Рет қаралды 167 М.
You don't need Generics in C
1:37:38
Tsoding Daily
Рет қаралды 55 М.
Is John Carmack Right about UI?!
1:52:02
Tsoding Daily
Рет қаралды 29 М.
New Math Language in Rust (Noq Ep.01)
1:48:44
Tsoding Daily
Рет қаралды 49 М.
How I Stopped Caring and Just Improved My Project (Nob Ep.01)
1:48:36
Tsoding Daily
Рет қаралды 42 М.
Computer Science in TypeScript (NO DEGREE REQUIRED) (Autocell Ep.01)
2:06:54
GPT-4o Deep Dive: the AI that CRUSHES everything
28:11
AI Search
Рет қаралды 61 М.
I made a New Programming Language
3:12:50
Tsoding Daily
Рет қаралды 53 М.
Is C++ better than C?
1:46:10
Tsoding Daily
Рет қаралды 27 М.
🤯Самая КРУТАЯ Функция #shorts
0:58
YOLODROID
Рет қаралды 3,6 МЛН
How about that uh?😎 #sneakers #airpods
0:13
Side Sphere
Рет қаралды 9 МЛН
Теперь это его телефон
0:21
Хорошие Новости
Рет қаралды 1,3 МЛН