This commit is contained in:
Nishi 2026-06-06 22:30:58 +09:00
commit 112a8f568b
19 changed files with 222 additions and 14 deletions

View file

@ -12,6 +12,7 @@ namespace fishbone {
#include <fishbone/window.h>
#include <fishbone/meshldr.h>
#include <fishbone/textureldr.h>
#include <fishbone/math.h>
namespace fishbone {
class Texture {
@ -64,6 +65,18 @@ namespace fishbone {
~Renderer();
void prepare();
void quad(std::vector<struct fishbone::Vector3> vertices, std::vector<struct fishbone::Vector2> texcoords, std::vector<struct fishbone::Vector3> normals) {
std::vector<struct fishbone::Vector3> v;
std::vector<struct fishbone::Vector2> t;
std::vector<struct fishbone::Vector3> n;
v = fishbone::quadToTriangle<struct fishbone::Vector3>(vertices);
t = fishbone::quadToTriangle<struct fishbone::Vector2>(texcoords);
n = fishbone::quadToTriangle<struct fishbone::Vector3>(normals);
this->triangle(v, t, n);
}
void triangle(std::vector<struct fishbone::Vector3> vertices, std::vector<struct fishbone::Vector2> texcoords, std::vector<struct fishbone::Vector3> normals);
};
static float maxDistance = 64;