IQ3LevelMesh.h 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. // Copyright (C) 2002-2012 Nikolaus Gebhardt
  2. // This file is part of the "Irrlicht Engine".
  3. // For conditions of distribution and use, see copyright notice in irrlicht.h
  4. #ifndef IRR_I_Q3_LEVEL_MESH_H_INCLUDED
  5. #define IRR_I_Q3_LEVEL_MESH_H_INCLUDED
  6. #include "IAnimatedMesh.h"
  7. #include "IQ3Shader.h"
  8. namespace irr
  9. {
  10. namespace scene
  11. {
  12. //! Interface for a Mesh which can be loaded directly from a Quake3 .bsp-file.
  13. /** The Mesh tries to load all textures of the map.*/
  14. class IQ3LevelMesh : public IAnimatedMesh
  15. {
  16. public:
  17. //! loads the shader definition from file
  18. /** \param filename Name of the shaderfile, defaults to /scripts if fileNameIsValid is false.
  19. \param fileNameIsValid Specifies whether the filename is valid in the current situation. */
  20. virtual const quake3::IShader* getShader( const c8* filename, bool fileNameIsValid=true ) = 0;
  21. //! returns a already loaded Shader
  22. virtual const quake3::IShader* getShader(u32 index) const = 0;
  23. //! get's an interface to the entities
  24. virtual quake3::tQ3EntityList& getEntityList() = 0;
  25. //! returns the requested brush entity
  26. /** \param num The number from the model key of the entity.
  27. Use this interface if you parse the entities yourself.*/
  28. virtual IMesh* getBrushEntityMesh(s32 num) const = 0;
  29. //! returns the requested brush entity
  30. virtual IMesh* getBrushEntityMesh(quake3::IEntity &ent) const = 0;
  31. };
  32. } // end namespace scene
  33. } // end namespace irr
  34. #endif