X-Git-Url: http://git.mutantstargoat.com?a=blobdiff_plain;f=src%2Fhair.h;h=5ef54d0462462d1a18897aa7a9847feb3ee86c81;hb=b07896ffc92093a3e8adb4953d22927a5874e43d;hp=19fa82ec8bbda3664be008bd878b9690bd25baf5;hpb=da5cbacf755273da510c37c819a59c7fe9894c4e;p=hair diff --git a/src/hair.h b/src/hair.h index 19fa82e..5ef54d0 100644 --- a/src/hair.h +++ b/src/hair.h @@ -5,10 +5,18 @@ #include "mesh.h" +struct HairStrand { + Vec3 pos; + Vec3 velocity; + Vec3 spawn_pt; + Vec3 spawn_dir; +}; + class Hair { private: - std::vector spawn_points; - std::vector spawn_directions; + float hair_length; + std::vector hair; + Mat4 xform; public: Hair(); @@ -16,6 +24,9 @@ public: bool init(const Mesh *m, int num_spawns, float thresh = 0.4); void draw() const; + + void set_transform(Mat4 &xform); + void update(float dt); }; #endif //PARTICLES_H_