stubbed out shaders
This commit is contained in:
+3
-2
@@ -5,6 +5,7 @@
|
||||
#include "datatypes.cpp"
|
||||
#include "helpers.cpp"
|
||||
#include "buffer.cpp"
|
||||
#include "shaders/shader.cpp"
|
||||
|
||||
namespace UwU {
|
||||
// rectangle
|
||||
@@ -23,11 +24,11 @@ namespace UwU {
|
||||
uint16_t y1;
|
||||
|
||||
// Draw a rectangle
|
||||
void draw (Buffer buffer, Color color) {
|
||||
void draw (Buffer buffer, Shader shader) {
|
||||
if (x0 > buffer.width || y0 > buffer.height || x1 > buffer.width || y1 > buffer.height) {return;};
|
||||
for (uint16_t y = y0; y < y1; y++) {
|
||||
for (uint16_t x = x0; x < x1; x++) {
|
||||
buffer.drawPixel(Coord2(x, y), color);
|
||||
buffer.drawPixelShader(Coord2(x, y), shader);
|
||||
}
|
||||
}
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user