![rnpnr](/img/default-banner.jpg)
- 65
- 9 993
rnpnr
Registrace 11. 05. 2024
Video
Terminal Emulator (Part 19): Selections
zhlédnutí 58Před 14 dny
Terminal Emulator (Part 19): Selections
Terminal Emulator (Part 18): Keybindings
zhlédnutí 42Před 14 dny
Terminal Emulator (Part 18): Keybindings
Terminal Emulator (Part 17): Using the Emulator
zhlédnutí 69Před 14 dny
Terminal Emulator (Part 17): Using the Emulator
Terminal Emulator (Part 16): Debug Data Dumping
zhlédnutí 50Před 14 dny
Terminal Emulator (Part 16): Debug Data Dumping
Colour Picker (Part 21): Counting CPU Cycles
zhlédnutí 69Před 21 dnem
Reducing the amount of wasted CPU time.
Colour Picker (Part 20): Horizontal Slider Drawing
zhlédnutí 46Před 21 dnem
Moving horizontal slider generation logic into the shader!
Colour Picker (Part 19): Shader Drawing
zhlédnutí 74Před 28 dny
Moving slider generation logic into the shader!
Colour Picker (Part 18): Embedding the Font/Shader!
zhlédnutí 79Před 28 dny
Writing a Metaprogram to embed the Font and Shader in the output binary.
Colour Picker (Part 17): Copy/Pasting!
zhlédnutí 43Před měsícem
Colour Picker (Part 17): Copy/Pasting!
Colour Picker (Part 11): Command Line Parsing
zhlédnutí 42Před měsícem
Colour Picker (Part 11): Command Line Parsing
Terminal Emulator (Part 15): Test Framework
zhlédnutí 224Před měsícem
Terminal Emulator (Part 15): Test Framework
Terminal Emulator (Part 14): Terminal in the Shell
zhlédnutí 88Před měsícem
Terminal Emulator (Part 14): Terminal in the Shell
Terminal Emulator (Part 13): OSC - Operating System Commands
zhlédnutí 42Před měsícem
Terminal Emulator (Part 13): OSC - Operating System Commands
Terminal Emulator (Part 12): Push Buffer Rendering and Colours
zhlédnutí 86Před měsícem
Terminal Emulator (Part 12): Push Buffer Rendering and Colours
Terminal Emulator (Part 11): Raw Memory Live Display
zhlédnutí 86Před měsícem
Terminal Emulator (Part 11): Raw Memory Live Display
Terminal Emulator (Part 10): Rectifying the Framebuffer
zhlédnutí 43Před 2 měsíci
Terminal Emulator (Part 10): Rectifying the Framebuffer
Thank you, these type of content for C is hard to come by these days.
I've done word selection before in SDL2 + C and it was the silliest andHacky kind of solution to handle line wrapped mouse selection. As soon as I saw it working how I thought it would, I became more grateful for the others that came before me handling word selection on other GUI programs. It was less of a pain if monospace fonts, but calculating the width for EVERY SINGLE CHARACTER on screen on top of accounting for LTR or RTL selection just made for something akin to a rube goldberg machine. If I had to handle mouse selection for web content accounting for multiple kinds of hierarchies and divs, I'd lose it!
It definitely took more code than I was expecting and I needed to add a little more to handle wide characters (which I don't think I recorded). I have implemented something similar for proportional fonts in a different program and it boiled down to making an initial guess and then correcting when things didn't line up after accounting for the actual size. Its not so bad if you are caching the glyph's size because they will probably be in the cache when you need to check the first guess and they will definitely be in the cache if you need further adjustments.
❤❤❤😊
Great stuff
❤❤❤❤😊
That's the beauty in UB, sometimes it works and sometimes it doesn't
You will have to remind me where the UB you are referring to is. I'm sure I am sure I am hitting lots of it 😅
❤❤❤😊
You can implement the natural log using Halley's or Newton's method. These methods are pretty fast (not the fastest) and one of the most accurate ones for computing a lot of functions (not just the natural log!). Also be aware that there are some problems when computing exp(x) for x close to zero, take a look at the expm1(x) function.
Thanks! I obviously went into this video with little thought beyond a quick "just use a Taylor Series". I would like to do more of my own implementations of libc and most of the interesting stuff is in math.h.
❤🎉
Do you do this stuff purely as a hobby or do you work in IT?
I do it purely because I love doing it! I would like to get a job doing some sort of high performance programming (eg. game engine, physics simulation) after I finish my Masters (EE, working with Medical Ultrasound) but right now its just a hobby.
part 15 of making a color picker in a black and white terminal
Now I can finally pick the perfect green text colour 😂
Wow❤❤❤❤😊
Really nice stuff, just a heads up, I did notice your playlists are not ordered, this one is even seems to have a random order.
Thanks for the tip! It looks like it might be a youtube bug but it should be fixed.
*❤❤❤
Wow
❤❤❤😊😊
❤❤❤❤
this is great!
hi, may I ask when you started programming?
@@pattyguy I've only been seriously programming since January but I learned to program 10 years ago. Most of the crazy things like hot reloading I only learned about recently.
Can't wait to get through this series :D! Professionally i'm deep in javascript/python work. Trying to get back into lower level stuff!
Thanks for your interest! The latest couple of videos have a been a little slow since I have been trying out new ideas but the pace should pickup again soon.
One can not rely on primitive types here, but you have to implement some custom number representation with arbitrary precision arithmetic. I used this gmp library for that (en.wikipedia.org/wiki/GNU_Multiple_Precision_Arithmetic_Library)
Of course, but the goal was to not use any library for doing that (and do it on the GPU). I started with 32 bit fixed point before I realized OpenGL has functions for doing integer add with carry. If I come back to this project I will use that to do arbitrary precision on the GPU.
Very impressive! How did you learn graphics programming, algorithms and data structures like the ones shown here? Could you recommend some learning resources?
Unfortunately I don't really know of any good resources for OpenGL. learnopengl.com/ will get you started but its full of bad practices. As for data structures I'm not sure which ones you referring to. The most complicated one I used was a Ring Buffer. I mostly picked these up by reading other people's code over time.
@@rnpnr_ Interesting, how's learnopengl full of bad practices? A lot of people seem to recommend it.
What theme are you using for vim? I love the colors
Its something I made, you can find it in my dotfiles here: github.com/rnpnr/dotfiles/blob/master/.config/vis/themes/term.lua and here: github.com/rnpnr/dotfiles/blob/master/.config/sys/etc/portage/savedconfig/x11-terms/st-9999#L97-L119
@@rnpnr_ thanks!
Bro I haven't watched the whole vid but moving a cursor in a terminal doesn't require 2 hour long tutorial
it requires more
Mind turning this into a UI Design series? Like showing us how we would go about creating interactive buttons and sliders etc?🎉
I do this in the next video(s). The audio is missing from the start of the next one but there is audio for where I start handling the mouse input.
@@rnpnr_ ohh great! I jus noticed thank you🙏
Audio starts at 1:04:10 ;_;
Link in the video: web.archive.org/web/20140628114658/www.superfractalthing.co.nf/sft_maths.pdf
How much does a dollar cost?
what's your terminal font?
Go Mono. You can find it here: github.com/golang/image/tree/master/font/gofont/ttfs