source:
orxonox.OLD/branches/volumetric_fog/src/world_entities/weather_effects/volfog_effect.cc
@
9935
Last change on this file since 9935 was 9935, checked in by hdavid, 18 years ago | |
---|---|
File size: 1.5 KB |
Rev | Line | |
---|---|---|
[7504] | 1 | /* |
[8495] | 2 | orxonox - the future of 3D-vertical-scrollers |
[7504] | 3 | |
[9935] | 4 | Copyright (C) 2006 orx |
[7504] | 5 | |
[8495] | 6 | This program is free software; you can redistribute it and/or modify |
7 | it under the terms of the GNU General Public License as published by | |
8 | the Free Software Foundation; either version 2, or (at your option) | |
9 | any later version. | |
[7504] | 10 | |
11 | ### File Specific: | |
[9935] | 12 | main-programmer: hdavid |
[7504] | 13 | */ |
14 | ||
15 | #include "volfog_effect.h" | |
16 | ||
17 | #include "util/loading/load_param.h" | |
18 | #include "util/loading/factory.h" | |
19 | ||
[7760] | 20 | #include "p_node.h" |
21 | #include "state.h" | |
22 | ||
[8495] | 23 | #include "glincl.h" |
[9727] | 24 | #include "debug.h" |
[7504] | 25 | |
[9727] | 26 | |
[7759] | 27 | #define GLX_GLXEXT_PROTOTYPES |
28 | ||
[9716] | 29 | #include "class_id_DEPRECATED.h" |
[9715] | 30 | ObjectListDefinitionID(VolFogEffect, CL_VOLFOG_EFFECT); |
[9709] | 31 | CREATE_FACTORY(VolFogEffect); |
[7504] | 32 | |
[9935] | 33 | |
34 | ||
[8495] | 35 | VolFogEffect::VolFogEffect(const TiXmlElement* root) { |
[9686] | 36 | this->registerObject(this, VolFogEffect::_objectList); |
[7504] | 37 | |
[8495] | 38 | if (root != NULL) |
39 | this->loadParams(root); | |
[7532] | 40 | |
[8495] | 41 | // Initialize Effect |
42 | this->init(); | |
[7546] | 43 | |
[8495] | 44 | // Activate Effect |
[9935] | 45 | if(fogActivate) |
46 | this->activate(); | |
[7504] | 47 | } |
48 | ||
49 | ||
[8495] | 50 | VolFogEffect::~VolFogEffect() { |
51 | this->deactivate(); | |
[7504] | 52 | } |
53 | ||
[8495] | 54 | void VolFogEffect::loadParams(const TiXmlElement* root) { |
55 | WeatherEffect::loadParams(root); | |
[7504] | 56 | } |
57 | ||
[8495] | 58 | void VolFogEffect::init() { |
[9935] | 59 | PRINTF(0)("Initalize VolFogEffect\n"); |
60 | ||
61 | fogActivate = false; | |
[7504] | 62 | |
[9935] | 63 | |
[7546] | 64 | } |
65 | ||
66 | ||
[8495] | 67 | void VolFogEffect::activate() { |
[9935] | 68 | PRINTF(0)("Activating VolFogEffect\n"); |
[7504] | 69 | } |
70 | ||
[8495] | 71 | void VolFogEffect::deactivate() { |
[9935] | 72 | PRINTF(0)("Deactivating VolFogEffect\n"); |
[7504] | 73 | } |
74 | ||
[7520] | 75 | |
[7516] | 76 | /** |
[9935] | 77 | * draws the effect |
[7652] | 78 | */ |
[8495] | 79 | void VolFogEffect::draw() const { |
[7760] | 80 | |
[7557] | 81 | } |
[7546] | 82 | |
83 | ||
[7516] | 84 | /** |
[7652] | 85 | * ticks the effect if there is any time dependancy |
86 | */ | |
[8495] | 87 | void VolFogEffect::tick(float dt) {} |
Note: See TracBrowser
for help on using the repository browser.