summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibGL/GLStruct.h
blob: 72bb8cc3c356f307e528eb1f230a8d2c9bd6beb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/*
 * Copyright (c) 2021, Jesse Buhagiar <jooster669@gmail.com>
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */

#pragma once

#include "GL/gl.h"
#include <LibGfx/Vector2.h>
#include <LibGfx/Vector3.h>
#include <LibGfx/Vector4.h>

namespace GL {

struct GLColor {
    GLclampf r, g, b, a;
};

struct GLVertex {
    FloatVector4 position;
    FloatVector4 color;
    FloatVector2 tex_coord;
    FloatVector3 normal;
};

struct GLTriangle {
    GLVertex vertices[3];
};

struct GLEdge {
    GLfloat x1;
    GLfloat y1;
    GLfloat x2;
    GLfloat y2;
};

}