--- /dev/null
+#ifndef MSP_GL_GEOMETRYBUILDER_H_
+#define MSP_GL_GEOMETRYBUILDER_H_
+
+namespace Msp {
+namespace GL {
+
+class Mesh;
+class PrimitiveBuilder;
+
+class GeometryBuilder
+{
+public:
+ enum TextureFit
+ {
+ STRETCH,
+ CROP,
+ WRAP
+ };
+
+protected:
+ bool generate_tbn;
+ TextureFit tex_fit;
+
+ GeometryBuilder();
+
+public:
+ GeometryBuilder &tbn(bool = true);
+ GeometryBuilder &texture_fit(TextureFit);
+protected:
+ void adjust_texture_scale(float &, float &, float, float) const;
+
+public:
+ virtual void build(PrimitiveBuilder &) const = 0;
+ void build(Mesh &) const;
+};
+
+} // namespace GL
+} // namespace Msp
+
+#endif