cloth2
view src/object.cc @ 0:ef0c22554406
cloth sim test, initial commit
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Mon, 11 Jan 2016 16:51:16 +0200 |
parents | |
children |
line source
1 #include "object.h"
2 #include "opengl.h"
4 Object::~Object()
5 {
6 }
8 Triangle::Triangle()
9 {
10 }
12 Triangle::Triangle(const Vector3 &a, const Vector3 &b, const Vector3 &c)
13 {
14 v[0] = a;
15 v[1] = b;
16 v[2] = c;
17 normal = normalize(cross(b - a, c - a));
18 }
20 bool Triangle::intersect(const Ray &ray, HitPoint *pt) const
21 {
22 return false;
23 }
25 void Triangle::draw() const
26 {
27 }