| ▲ | dahart 4 hours ago | |||||||||||||||||||||||||
I think what you’re describing is the difference between raster and vector graphics, and doesn’t reflect on shaders directly. It always depends on your goals, of course. The goal of drawing with a pen is to draw outlines, but the goal behind rasterizing or ray tracing, and shading, is not to draw outlines, but often to render 3d scenes with physically based materials. Achieving that goal with a pen is extremely difficult and tedious and time consuming, which is why the way we render scenes doesn’t do that, it is closer to simulating bundles of light particles and approximating their statistical behavior. Of course, painting is slighty closer to shading than pen drawing is. | ||||||||||||||||||||||||||
| ▲ | Kiro 3 hours ago | parent [-] | |||||||||||||||||||||||||
I think their explanation is great. The shader is run on all the pixels within the quad and your shader code needs to figure out if the pixel is within the shape you want to draw or not. Compared to just drawing it pixel by pixel if you do it by pen or on the CPU. For a red line between A and B: CPU/pen: for each pixel between A and B: draw red GPU/shader: for all pixels: draw red if it's on the intersection between A and B | ||||||||||||||||||||||||||
| ||||||||||||||||||||||||||