world render refactor
This commit is contained in:
@@ -1,10 +1,3 @@
|
||||
/*
|
||||
* LineBatch.cpp
|
||||
*
|
||||
* Created on: Jun 25, 2020
|
||||
* Author: MihailRis
|
||||
*/
|
||||
|
||||
#include "LineBatch.h"
|
||||
#include "Mesh.h"
|
||||
|
||||
@@ -67,7 +60,6 @@ void LineBatch::box(float x, float y, float z, float w, float h, float d,
|
||||
line(x+w, y+h, z-d, x+w, y+h, z+d, r,g,b,a);
|
||||
}
|
||||
|
||||
#include <iostream>
|
||||
void LineBatch::render(){
|
||||
if (index == 0)
|
||||
return;
|
||||
@@ -75,3 +67,7 @@ void LineBatch::render(){
|
||||
mesh->draw(GL_LINES);
|
||||
index = 0;
|
||||
}
|
||||
|
||||
void LineBatch::lineWidth(float width) {
|
||||
glLineWidth(width);
|
||||
}
|
||||
@@ -1,10 +1,3 @@
|
||||
/*
|
||||
* LineBatch.h
|
||||
*
|
||||
* Created on: Jun 25, 2020
|
||||
* Author: MihailRis
|
||||
*/
|
||||
|
||||
#ifndef GRAPHICS_LINEBATCH_H_
|
||||
#define GRAPHICS_LINEBATCH_H_
|
||||
|
||||
@@ -27,6 +20,7 @@ public:
|
||||
float r, float g, float b, float a);
|
||||
|
||||
void render();
|
||||
void lineWidth(float width);
|
||||
};
|
||||
|
||||
#endif /* GRAPHICS_LINEBATCH_H_ */
|
||||
|
||||
Reference in New Issue
Block a user