Y
Hacker News
new
|
ask
|
show
|
jobs
by
ryandrake
2102 days ago
I've always liked this illustration: Code to draw a triangle in 1. OpenGL 1.x, 2. OpenGL 3+, 3 Vulkan [1].
1:
http://sol.gfxile.net/temp/hellotriangle.png
4 comments
gw
2102 days ago
It is pretty wild, though mine wasn't quite as bad. It ended up clocking in at 650 lines. I guess part of that is because nim doesn't have braces...
https://github.com/oakes/vulkan_triangle_nim/blob/master/src...
link
monocasa
2101 days ago
It's decidedly not optimized for hello world style examples, but it's a lot nicer once you have a non trivial codebase, IMO.
link
gameswithgo
2102 days ago
supposedly code the draw doom 4 is less with vulkan than opengl though
link
Reelin
2101 days ago
> glfwCreateWindow(..., "The spinning triangle that took 1397 lines of code", ...);
I get it, Vulkan is low level, but still.
link