MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / Init

Method Init

engine/PoseidonGL33/TextureGL33_Init.cpp:145–161  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

143}
144
145int TextureGL33::Init(const char* name)
146{
147 SetName(name);
148
149 _maxSize = 0x10000;
150
151 RString resolved = Poseidon::Graphics::ResolveLooseTexturePath(name);
152 ITextureSourceFactory* factory = SelectTextureSourceFactory(resolved);
153 if (!factory || !factory->Check(resolved))
154 {
155 Poseidon::Foundation::WarningMessage("Cannot load texture %s.", static_cast<const char*>(GetName()));
156 _nMipmaps = 0;
157 return -1;
158 }
159
160 return 0;
161}
162
163void TextureGL33::PreloadHeaders()
164{

Callers 4

CopyMethod · 0.45
LoadMethod · 0.45
InitGLMethod · 0.45
InitDetailTexturesMethod · 0.45

Calls 4

ResolveLooseTexturePathFunction · 0.85
WarningMessageFunction · 0.85
CheckMethod · 0.45

Tested by

no test coverage detected