00001
00002
00003
00004
00005 #ifndef __I_GEOMETRY_CREATOR_H_INCLUDED__
00006 #define __I_GEOMETRY_CREATOR_H_INCLUDED__
00007
00008 #include "IReferenceCounted.h"
00009 #include "IMesh.h"
00010 #include "IImage.h"
00011
00012 namespace irr
00013 {
00014 namespace video
00015 {
00016 class IVideoDriver;
00017 class SMaterial;
00018 }
00019
00020 namespace scene
00021 {
00022
00024
00025 class IGeometryCreator : public IReferenceCounted
00026 {
00027 public:
00028
00030
00034 virtual IMesh* createCubeMesh(const core::vector3df& size=core::vector3df(5.f,5.f,5.f)) const =0;
00035
00037
00046 virtual IMesh* createHillPlaneMesh(
00047 const core::dimension2d<f32>& tileSize,
00048 const core::dimension2d<u32>& tileCount,
00049 video::SMaterial* material, f32 hillHeight,
00050 const core::dimension2d<f32>& countHills,
00051 const core::dimension2d<f32>& textureRepeatCount) const =0;
00052
00054
00069 virtual IMesh* createTerrainMesh(video::IImage* texture,
00070 video::IImage* heightmap,
00071 const core::dimension2d<f32>& stretchSize,
00072 f32 maxHeight, video::IVideoDriver* driver,
00073 const core::dimension2d<u32>& defaultVertexBlockSize,
00074 bool debugBorders=false) const =0;
00075
00077
00090 virtual IMesh* createArrowMesh(const u32 tesselationCylinder = 4,
00091 const u32 tesselationCone = 8, const f32 height = 1.f,
00092 const f32 cylinderHeight = 0.6f, const f32 widthCylinder = 0.05f,
00093 const f32 widthCone = 0.3f, const video::SColor colorCylinder = 0xFFFFFFFF,
00094 const video::SColor colorCone = 0xFFFFFFFF) const =0;
00095
00096
00098
00104 virtual IMesh* createSphereMesh(f32 radius = 5.f,
00105 u32 polyCountX = 16, u32 polyCountY = 16) const =0;
00106
00108
00117 virtual IMesh* createCylinderMesh(f32 radius, f32 length,
00118 u32 tesselation,
00119 const video::SColor& color=video::SColor(0xffffffff),
00120 bool closeTop=true, f32 oblique=0.f) const =0;
00121
00123
00132 virtual IMesh* createConeMesh(f32 radius, f32 length, u32 tesselation,
00133 const video::SColor& colorTop=video::SColor(0xffffffff),
00134 const video::SColor& colorBottom=video::SColor(0xffffffff),
00135 f32 oblique=0.f) const =0;
00136
00138
00147 virtual IMesh* createVolumeLightMesh(
00148 const u32 subdivideU=32, const u32 subdivideV=32,
00149 const video::SColor footColor = 0xffffffff,
00150 const video::SColor tailColor = 0xffffffff,
00151 const f32 lpDistance = 8.f,
00152 const core::vector3df& lightDim = core::vector3df(1.f,1.2f,1.f)) const =0;
00153 };
00154
00155
00156 }
00157 }
00158
00159 #endif // __I_GEOMETRY_CREATOR_H_INCLUDED__
00160