ScummVM API documentation
wme_shadowmanager.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef WINTERMUTE_SHADOWMANAGER_H
23 #define WINTERMUTE_SHADOWMANAGER_H
24 
25 #include "common/str.h"
26 
27 #include "engines/wintermute/base/base_scriptable.h"
28 
29 namespace Wintermute {
30 
31 class AdActor3DX;
32 class Light3D;
33 
35 public:
36  DECLARE_PERSISTENT(SXShadowManager, BaseScriptable)
37  ScValue *scGetProperty(const Common::String &name) override;
38  bool scSetProperty(const char *name, ScValue *value) override;
39  bool scCallMethod(ScScript *script, ScStack *stack, ScStack *thisStack, const char *name) override;
40  const char *scToString() override;
41  SXShadowManager(BaseGame *inGame, ScStack *stack);
42  ~SXShadowManager() override;
43 
44 private:
45  static void callback(void *eventData1, void *eventData2);
46  void update();
47  void run();
48  void stop();
49  bool addActor(AdActor3DX *actorObj);
50  bool removeAllActors();
51  bool enableLight(const char *lightName);
52  bool disableLight(const char *lightName);
53 
56  uint32 _lastTime{};
57  DXVector3 _defaultLightPos;
58  float _minShadow;
59  float _maxShadow;
60  bool _useSmartShadows;
61  uint32 _shadowColor;
62 };
63 
64 } // End of namespace Wintermute
65 
66 #endif
Definition: script.h:44
Definition: base_game.h:76
Definition: script_value.h:42
Definition: str.h:59
Definition: xmath.h:50
Definition: list.h:44
Definition: ad_actor_3dx.h:43
Definition: base_scriptable.h:41
Definition: wme_shadowmanager.h:34
Definition: script_stack.h:41
Definition: achievements_tables.h:27