- Timestamp:
- May 24, 2006, 3:21:13 PM (19 years ago)
- Location:
- branches/atmospheric_engine/src
- Files:
-
- 8 edited
- 2 copied
- 2 moved
Legend:
- Unmodified
- Added
- Removed
-
branches/atmospheric_engine/src/defs/class_id.h
r7679 r7807 218 218 219 219 CL_IMAGE_ENTITY = 0x00000513, 220 CL_ BILLBOARD= 0x00000514,220 CL_IMAGE_PLANE = 0x00000514, 221 221 CL_MODEL_ENTITY = 0x00000515, 222 222 CL_TEXT_ELEMENT = 0x00000516, /// TODO MOVE … … 281 281 CL_GRAPHICS_EFFECT = 0x00a01000, 282 282 283 CL_BILLBOARD = 0x00000a01, 283 284 CL_SUN_EFFECT = 0x00a02000, 284 285 CL_WEATHER_EFFECT = 0x00a04000, -
branches/atmospheric_engine/src/lib/graphics/Makefile.am
r7679 r7807 10 10 render2D/render_2d.cc \ 11 11 render2D/element_2d.cc \ 12 render2D/ billboard.cc \12 render2D/image_plane.cc \ 13 13 \ 14 14 text_engine/text_engine.cc \ … … 35 35 render2D/render_2d.h \ 36 36 render2D/element_2d.h \ 37 render2D/ billboard.h \37 render2D/image_plane.h \ 38 38 \ 39 39 text_engine/text_engine.h \ -
branches/atmospheric_engine/src/lib/graphics/effects/lense_flare.cc
r7316 r7807 28 28 #include "state.h" 29 29 30 #include "render2D/ billboard.h"30 #include "render2D/image_plane.h" 31 31 32 32 #include "light.h" … … 80 80 LenseFlare::~LenseFlare() 81 81 { 82 std::vector< Billboard*>::iterator it;82 std::vector<ImagePlane*>::iterator it; 83 83 for( it = flares.begin(); it != flares.end(); it++) 84 84 delete (*it); … … 155 155 } 156 156 157 Billboard* bb = new Billboard(NULL);157 ImagePlane* bb = new ImagePlane(NULL); 158 158 bb->setTexture(textureName); 159 159 bb->setSize(50, 50); 160 160 this->flares.push_back(bb); 161 PRINTF(4)("Added a Lenseflare Billboardwith texture %s\n", textureName.c_str());161 PRINTF(4)("Added a Lenseflare ImagePlane with texture %s\n", textureName.c_str()); 162 162 163 163 // the first flare belongs to the light source … … 178 178 float dist = this->frustumPlane.distancePoint(this->lightSource->getAbsCoor()); 179 179 PRINTF(0)("dist: %f\n", dist); 180 std::vector< Billboard*>::const_iterator it;180 std::vector<ImagePlane*>::const_iterator it; 181 181 for(it = flares.begin(); it != flares.end(); it++) 182 182 (*it)->setVisibility(visibility); … … 220 220 221 221 // now calculate the new coordinates of the billboards 222 std::vector< Billboard*>::iterator it;222 std::vector<ImagePlane*>::iterator it; 223 223 int i; 224 224 for( it = flares.begin(), i = 0; it != flares.end(); it++, i++) -
branches/atmospheric_engine/src/lib/graphics/effects/lense_flare.h
r7316 r7807 20 20 class TiXmlElement; 21 21 class Light; 22 class Billboard;22 class ImagePlane; 23 23 24 24 //! A class that handles LenseFlares. The LenseFlareManager operates on this. … … 50 50 float isVisible; //!< Checks visibility 51 51 Light* lightSource; //!< reference to the sun (or primary light source) 52 std::vector< Billboard*> flares; //!< the flares array52 std::vector<ImagePlane*> flares; //!< the flares array 53 53 54 54 Vector2D flareVector; //!< the axis to draw the flares on -
branches/atmospheric_engine/src/lib/graphics/effects/lightening_effect.cc
r7699 r7807 15 15 #include "lightening_effect.h" 16 16 17 #include "state.h" 17 18 #include "util/loading/load_param.h" 18 19 #include "util/loading/factory.h" 19 #include "render2D/ billboard.h"20 #include "render2D/image_plane.h" 20 21 21 22 #include "glincl.h" … … 31 32 32 33 33 lightening = new Billboard(NULL);34 lightening->setTexture(" pictures/lense_flare/lens2.png");34 lightening = new ImagePlane(NULL); 35 lightening->setTexture("maps/lightning_bolt.png"); 35 36 lightening->setSize(50, 50); 36 lightening->setAbsCoor2D( 0,0);37 lightening->setAbsCoor2D(10,10); 37 38 lightening->setVisibility(true); 39 38 40 39 41 this->init(); -
branches/atmospheric_engine/src/lib/graphics/effects/lightening_effect.h
r7699 r7807 15 15 16 16 17 class Billboard;17 class ImagePlane; 18 18 19 19 class LighteningEffect : public WeatherEffect … … 33 33 34 34 private: 35 Billboard* lightening;35 ImagePlane* lightening; 36 36 37 37 }; -
branches/atmospheric_engine/src/lib/graphics/render2D/image_plane.cc
r7799 r7807 15 15 #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WEAPON 16 16 17 #include " billboard.h"17 #include "image_plane.h" 18 18 19 19 #include "util/loading/load_param.h" … … 30 30 31 31 32 CREATE_FACTORY( Billboard, CL_IMAGE_ENTITY);32 CREATE_FACTORY(ImagePlane, CL_IMAGE_ENTITY); 33 33 34 34 … … 36 36 * standart constructor 37 37 */ 38 Billboard::Billboard(const TiXmlElement* root)38 ImagePlane::ImagePlane (const TiXmlElement* root) 39 39 { 40 40 this->init(); … … 46 46 47 47 /** 48 * destroys a Billboard48 * destroys a ImagePlane 49 49 */ 50 Billboard::~Billboard()50 ImagePlane::~ImagePlane () 51 51 { 52 52 if (this->material) … … 56 56 57 57 /** 58 * initializes the Billboard58 * initializes the ImagePlane 59 59 */ 60 void Billboard::init()60 void ImagePlane::init() 61 61 { 62 this->setClassID(CL_ BILLBOARD, "Billboard");63 this->setName(" Billboard");62 this->setClassID(CL_IMAGE_PLANE, "ImagePlane"); 63 this->setName("ImagePlane"); 64 64 65 65 this->setLayer(E2D_LAYER_TOP); … … 76 76 * @param root TiXmlElement object 77 77 */ 78 void Billboard::loadParams(const TiXmlElement* root)78 void ImagePlane::loadParams(const TiXmlElement* root) 79 79 { 80 80 LoadParam(root, "texture", this->material, Material, setDiffuseMap) 81 .describe("the texture-file to load onto the Billboard");81 .describe("the texture-file to load onto the ImagePlane"); 82 82 83 LoadParam(root, "size", this, Billboard, setSize)84 .describe("the size of the Billboardin Pixels");83 LoadParam(root, "size", this, ImagePlane, setSize) 84 .describe("the size of the ImagePlane in Pixels"); 85 85 } 86 86 87 87 88 88 /** 89 * sets the size of the Billboard.89 * sets the size of the ImagePlane. 90 90 * @param size the size in pixels 91 91 */ 92 void Billboard::setSize(float sizeX, float sizeY)92 void ImagePlane::setSize(float sizeX, float sizeY) 93 93 { 94 94 this->setSize2D(sizeX, sizeY); … … 100 100 * @param textureFile The texture-file to load onto the crosshair 101 101 */ 102 void Billboard::setTexture(const std::string& textureFile)102 void ImagePlane::setTexture(const std::string& textureFile) 103 103 { 104 104 this->material->setDiffuseMap(textureFile); … … 107 107 108 108 /** 109 * attaches this billboardto a parent109 * attaches this image_plane to a parent 110 110 * @param pNode node to attach to 111 111 */ 112 void Billboard::attachTo(PNode* pNode)112 void ImagePlane::attachTo(PNode* pNode) 113 113 { 114 114 this->source->setParent(pNode); … … 117 117 118 118 /** 119 * ticks the Billboard119 * ticks the ImagePlane 120 120 * @param dt the time to ticks 121 121 */ 122 void Billboard::tick(float dt)122 void ImagePlane::tick(float dt) 123 123 { 124 124 float z = 0.0f; … … 145 145 146 146 /** 147 * draws the billboard147 * draws the image_plane 148 148 */ 149 void Billboard::draw() const149 void ImagePlane::draw() const 150 150 { 151 151 if( !this->isVisible()) -
branches/atmospheric_engine/src/lib/graphics/render2D/image_plane.h
r7799 r7807 1 1 /*! 2 * @file billboard.h3 * Definition of a billboard2 * @file image_plane.h 3 * Definition of a image_plane 4 4 */ 5 5 6 #ifndef _ BILLBOARD_H7 #define _ BILLBOARD_H6 #ifndef _IMAGE_PLANE_H 7 #define _IMAGE_PLANE_H 8 8 9 9 … … 14 14 15 15 16 class Model;17 16 class Material; 18 17 class TiXmlElement; 19 18 20 19 //! A class that enables the 21 class Billboard: public Element2D20 class ImagePlane : public Element2D 22 21 { 23 22 24 23 public: 25 Billboard(const TiXmlElement* root = NULL);26 virtual ~ Billboard();24 ImagePlane(const TiXmlElement* root = NULL); 25 virtual ~ImagePlane(); 27 26 28 27 void init(); … … 38 37 39 38 private: 40 Material* material; //!< a material for the Billboard39 Material* material; //!< a material for the ImagePlane 41 40 float rotationSpeed; //!< Speed of the Rotation. 42 41 … … 45 44 }; 46 45 47 #endif /* _ BILLBOARD_H */46 #endif /* _IMAGE_PLANE_H */ -
branches/atmospheric_engine/src/util/multiplayer_team_deathmatch.cc
r7221 r7807 20 20 #include "util/loading/factory.h" 21 21 22 #include "render2D/ billboard.h"22 #include "render2D/image_plane.h" 23 23 #include "state.h" 24 24 #include "class_list.h" … … 53 53 this->timeout = 0.0f; 54 54 55 this->deathScreen = new Billboard();55 this->deathScreen = new ImagePlane(); 56 56 this->deathScreen->setSize(State::getResX()/4.0, State::getResY()/4.0); 57 57 this->deathScreen->setAbsCoor2D(State::getResX()/2.0f, State::getResY()/2.0f); -
branches/atmospheric_engine/src/util/multiplayer_team_deathmatch.h
r7221 r7807 16 16 class ObjectManager; 17 17 class Player; 18 class Billboard;18 class ImagePlane; 19 19 20 20 … … 52 52 int teamBKills; //!< kills of team B 53 53 54 Billboard* deathScreen; //!< the death screen54 ImagePlane* deathScreen; //!< the death screen 55 55 }; 56 56 -
branches/atmospheric_engine/src/world_entities/effects/billboard.h
r7799 r7807 2 2 * @file lightning_bolt.h 3 3 * @brief a LightningBolt Projectile 4 * Der Effekt soll folgendermaßen funktionieren:5 * -> Ein Partikel mit einer Blitz-Textur soll sehr schnell erscheinen,6 * -> während er an Intensität zunimmt soll die Beleuchtung der gerenderten Szene entsprechend zunehmen.7 * -> Je mehr Blitze zum gleichen Zeitpunkt sichtbar sind, desto heller soll die Beleuchtung werden, das heißt die Helligkeitszunahme pro Blitz soll Additiv sein.8 * -> Ein Partikel soll ebenfalls sehr schnell wieder verblassen, dabei soll die Beleuchtung entsprechend der vorhergehenden Zunahme wieder abnehmen (Additiv)9 4 */ 10 5
Note: See TracChangeset
for help on using the changeset viewer.