Writing a BATCH RENDERER in ONE HOUR!

preview_player
Показать описание


Code ► Coming Soon!

This video is sponsored by Hostinger.
Рекомендации по теме
Комментарии
Автор

Next: Writing a text renderer in ONE HOUR! let's

casvanmarcel
Автор

Cherno out here motivating me to get stuff done

abdel
Автор

7:00 that is actually a thing and is called "pakinson's law". Impressive how you came up with this yourself :)

whythosenames
Автор

I think the check for "TextureSlotIndex > 31" should be inside the "textureIndex == 0.0f" check. Because otherwise if you have use use all the textures and want to draw another quad with an already existing texture it will start a new batch, wouldn't it?

damokls
Автор

21:29 I'm a little curious. "GPUs like floats" - could someone tell me how/why?

mmmm
Автор

Could you please post the code that SHOULD have accompanied this video, you are mentioning it at 08:24 ?

iseedumbpeople
Автор

Hey, I have a question about more dynamic batch rendering. I watched your video on dynamic geometry, and in it you essentially apply your position updates (ie position transforms) before adding the vertex positions to the buffer.



If I have some more complicated transformations (rotation/scale/whatever), and the transformations are passed into the vertex shader as a transformation matrix and applied there, how do I handle batching objects that have different transformations? Are objects with different transformations supposed to have different draw calls? Or should I pre-apply all the transformations in code and just upload the transformed positions into the vertex buffer? Or is there some way to store the relevant transformation matrices in another buffer and access them by some ID in the shader?

Wicked
Автор

i made a 3d batch renderer in opengl 3.3 that draws cubes using this as a reference. Thank you for making educational content! the quality of your videos are amazing <3

Data_Corruption
Автор

great video ! Keep up the good work ! Definitely want to see some optimization and performance, love that part !

oblivionronin
Автор

Is the code of this episode available now?

royzhong
Автор

Im beginning to see a pattern here. And i like it.

pankaka
Автор

been 3 years, hope the code is still "Coming Soon!"

kamiltrzcinski
Автор

To be honest. It would probably be worse to use a HashSet or similar for checking if the texture is already used. On paper O(1) is better than O(n), but that's only because we drop constants when calculating the time complexity of functions. If you include all the extra work of computing a hash and such then it ends up being slower than a linear search.

I would imagine that if you bounded the loop with the constant MaxTextures then the compiler might do unrolling or something and make it even faster.

To be honest though, you're better off profiling before doing anything like that.

Hector-bjls
Автор

Parkinson's law - "work expands so as to fill the time available for its completion"

tymbarkowychlopak
Автор

Is there any reason to manage your buffer dynamically like this instead of just allowing the stl or whatever variation of the standard library to do it for you? The Optimizations for std::vector seem to work rather well and is much easier to use then going at it with your own iterator here. Idk, does it really effect performance that much or is vector or an equivalent as good here?

seditt
Автор

can we get an update on hazel...
on the dev branch..

sumloser
Автор

I followed this video and wrote the code but for some reason, it is showing a blank screen with an imgui panel

anonymoussloth
Автор

Cherno love your videos. The code is still missing though.

JaymzBond
Автор

Is there a benefit to using a class as a namespace like that rather than just a namespace with functions? Is it just a style thing? Template parameters of the class could make a difference I guess, or maybe it's easier to change to a class with instances or something later? Just curious.

biggiefrosty
Автор

you forgot to talk about Renderer2D::End() and Renderer2D::Flush()

williankoessler
welcome to shbcf.ru