#include <C4Sky.h>
Public Member Functions | |
C4Sky () | |
~C4Sky () | |
void | Default () |
bool | Init (bool fSavegame, std::string names="") |
void | Clear () |
void | SetColor (int32_t iIndex, int32_t iRed, int32_t iGreen, int32_t iBlue) |
void | SetFadePalette (int32_t *ipColors) |
void | Draw (C4TargetFacet &cgo) |
DWORD | GetSkyFadeClr (int32_t iY) |
void | Execute () |
bool | SetModulation (DWORD dwWithClr, DWORD dwBackClr) |
DWORD | GetModulation (bool fBackClr) |
void | CompileFunc (StdCompiler *pComp) |
Public Attributes | |
class C4Surface * | Surface |
C4Shader | Shader |
C4Shader | ShaderLight |
C4Real | xdir |
C4Real | ydir |
C4Real | x |
C4Real | y |
int32_t | ParX |
int32_t | ParY |
uint32_t | FadeClr1 |
uint32_t | FadeClr2 |
int32_t | ParallaxMode |
Protected Attributes | |
int32_t | Width |
int32_t | Height |
uint32_t | Modulation |
int32_t | BackClr |
bool | BackClrEnabled |
|
inline |
C4Sky::~C4Sky | ( | ) |
void C4Sky::Clear | ( | ) |
Definition at line 159 of file C4Sky.cpp.
References C4Shader::Clear(), Modulation, Shader, ShaderLight, and Surface.
Referenced by ~C4Sky().
void C4Sky::CompileFunc | ( | StdCompiler * | pComp | ) |
Definition at line 237 of file C4Sky.cpp.
References BackClr, BackClrEnabled, C4SkyPM_Fixed, Fix0, mkCastIntAdapt(), mkNamingAdapt(), Modulation, ParallaxMode, ParX, ParY, StdCompiler::Value(), x, xdir, y, and ydir.
void C4Sky::Default | ( | ) |
Definition at line 142 of file C4Sky.cpp.
References BackClr, BackClrEnabled, C4SkyPM_Fixed, Height, Modulation, ParallaxMode, ParX, ParY, Surface, Width, x, xdir, y, and ydir.
Referenced by C4Sky().
void C4Sky::Draw | ( | C4TargetFacet & | cgo | ) |
Definition at line 180 of file C4Sky.cpp.
References C4Draw::ActivateBlitModulation(), BackClr, BackClrEnabled, C4Draw::BlitSurfaceTile(), C4Draw::DeactivateBlitModulation(), C4Draw::DrawBoxDw(), C4Draw::DrawBoxFade(), fixtof(), C4Draw::GetFoW(), GetSkyFadeClr(), C4Facet::Hgt, Modulation, ParX, ParY, pDraw, Shader, ShaderLight, C4Facet::Surface, Surface, C4TargetFacet::TargetX, C4TargetFacet::TargetY, C4Facet::Wdt, C4Facet::X, x, C4Facet::Y, y, and C4TargetFacet::Zoom.
Referenced by C4Viewport::Draw().
void C4Sky::Execute | ( | ) |
Definition at line 167 of file C4Sky.cpp.
References C4REAL100(), C4SkyPM_Wind, Height, itofix(), ParallaxMode, Surface, Weather, Width, C4Weather::Wind, x, xdir, y, and ydir.
|
inline |
DWORD C4Sky::GetSkyFadeClr | ( | int32_t | iY | ) |
bool C4Sky::Init | ( | bool | fSavegame, |
std::string | names = "" |
||
) |
Definition at line 46 of file C4Sky.cpp.
References C4CFN_Sky, C4Game::C4S, C4SF_MipMap, C4SF_Tileable, C4SkyPM_Wind, FadeClr1, FadeClr2, C4GraphicsResource::Files, Game, GraphicsResource, C4Scenario::Landscape, C4Surface::LoadAny(), ParallaxMode, ParX, ParY, pDraw, C4Draw::PrepareSpriteShader(), C4Game::RandomSeed, C4Game::ScenarioFile, SeededRandom(), SetFadePalette(), Shader, C4SLandscape::SkyDef, C4SLandscape::SkyDefFade, C4SLandscape::SkyScrollMode, Surface, x, xdir, y, and ydir.
void C4Sky::SetColor | ( | int32_t | iIndex, |
int32_t | iRed, | ||
int32_t | iGreen, | ||
int32_t | iBlue | ||
) |
void C4Sky::SetFadePalette | ( | int32_t * | ipColors | ) |
|
protected |
Definition at line 49 of file C4Sky.h.
Referenced by CompileFunc(), Default(), Draw(), GetModulation(), and SetModulation().
|
protected |
Definition at line 50 of file C4Sky.h.
Referenced by CompileFunc(), Default(), Draw(), and SetModulation().
uint32_t C4Sky::FadeClr1 |
Definition at line 58 of file C4Sky.h.
Referenced by GetSkyFadeClr(), Init(), and SetFadePalette().
uint32_t C4Sky::FadeClr2 |
Definition at line 58 of file C4Sky.h.
Referenced by GetSkyFadeClr(), Init(), and SetFadePalette().
|
protected |
|
protected |
Definition at line 48 of file C4Sky.h.
Referenced by Clear(), CompileFunc(), Default(), Draw(), GetModulation(), and SetModulation().
int32_t C4Sky::ParallaxMode |
int32_t C4Sky::ParX |
Definition at line 57 of file C4Sky.h.
Referenced by CompileFunc(), Default(), C4GraphicsSystem::DoSaveScreenshot(), Draw(), and Init().
int32_t C4Sky::ParY |
Definition at line 57 of file C4Sky.h.
Referenced by CompileFunc(), Default(), C4GraphicsSystem::DoSaveScreenshot(), Draw(), and Init().
C4Shader C4Sky::Shader |
C4Shader C4Sky::ShaderLight |
class C4Surface* C4Sky::Surface |
|
protected |
C4Real C4Sky::x |
C4Real C4Sky::xdir |
C4Real C4Sky::y |
C4Real C4Sky::ydir |