Graphics Programming Interview Question Tutorial

  Рет қаралды 2,048

Suboptimal Engineer

Suboptimal Engineer

Күн бұрын

Пікірлер: 10
@bossgd100
@bossgd100 Жыл бұрын
graphics programmers interview: draw a checkboard html programmers interview: reverse this binary tree
@wall-wrecker-my6ss
@wall-wrecker-my6ss Жыл бұрын
sounds like false
@kolupsy
@kolupsy Жыл бұрын
I was looking at the article and was pretty proud of myself for being able to answer most of the generalist interview question while being able to provide more in-depth information or explanations to a topic.
@SuboptimalEng
@SuboptimalEng Жыл бұрын
That's pretty good! I've still got to learn more before I can answer all the questions.
@dusha3030
@dusha3030 Жыл бұрын
It may be dumb but couldn't we just do this ? mod(floor(10.0*uv.x) + floor(10.0*uv.y), 2.0);
@SuboptimalEng
@SuboptimalEng Жыл бұрын
I expanded my code to keep it simple for someone who might not be familiar with writing shaders. I’d definitely go with your approach if I was doing code golf!
@Po4to
@Po4to Ай бұрын
My take was to fract() vertical and horizontal black & white gradients and round() the values: below .5 would be black, above - white. Then subtract the value of the vertical gradient from the horizontal, and get an abs() value of that, These would give one of four results: abs(1 - 0) = 1, ergo white abs(0 - 1) = abs(-1) = 1, ergo also white abs(0 - 0) = 0, ergo black abs(1 - 1) = 0, ergo also black But even going full brut, with just fragColor = vec4(abs(round(fract(vec3(uv.x/.3))) - round(fract(vec3(uv.y/.3)))), 1); I would not win this golf match ;) Still, this kind of problems is very thought-provoking. I'm new to webGL and not very advanced in coding or math either - but I'm having a lot of fun and that pushes me to learn more.
@SuboptimalEng
@SuboptimalEng Ай бұрын
That’s a smart way to solve the same problem. Thanks for sharing! Writing shaders is so fun because it combines art with math and programming 😁
@alexfrozen
@alexfrozen 8 ай бұрын
Compare speed and size with this one: vec3 color = smoothstep(-.01,.01,vec3(sin(uv.x*10.)*sin(uv.y*10.)));
@SuboptimalEng
@SuboptimalEng 8 ай бұрын
I kept my code verbose to help with the video explanation! It can easily be written better and your code is a good example 🤓
What is Gaussian Blur?
7:30
Suboptimal Engineer
Рет қаралды 9 М.
Introduction to shaders: Learn the basics!
34:50
Barney Codes
Рет қаралды 378 М.
Почему Катар богатый? #shorts
0:45
Послезавтра
Рет қаралды 2 МЛН
Andro, ELMAN, TONI, MONA - Зари (Official Music Video)
2:50
RAAVA MUSIC
Рет қаралды 2 МЛН
What is WebGPU?
14:09
Suboptimal Engineer
Рет қаралды 70 М.
Dear Game Developers, Stop Messing This Up!
22:19
Jonas Tyroller
Рет қаралды 778 М.
I Made a Graphics Engine (again)
8:27
Zyger
Рет қаралды 182 М.
What Is A Graphics Programmer?
30:21
Acerola
Рет қаралды 468 М.
Introduction to Signed Distance Fields
9:00
Suboptimal Engineer
Рет қаралды 29 М.
Jonathan Blow on Modern Graphics Programming
10:50
Jonathan Blow Clips
Рет қаралды 72 М.
Rendering 2D objects - Software from scratch
1:45:23
Muukid
Рет қаралды 32 М.
I did a C++ University Assignment
50:23
The Cherno
Рет қаралды 302 М.