MCPcopy Create free account
hub / github.com/DFHack/dfhack / delete_texture

Function delete_texture

library/modules/Textures.cpp:109–115  ·  view source on GitHub ↗

delete surface from texture raws

Source from the content-addressed store, hash-verified

107
108// delete surface from texture raws
109static void delete_texture(long texpos) {
110 std::lock_guard<std::mutex> lg_add_texture(g_adding_mutex);
111 auto pos = static_cast<size_t>(texpos);
112 if (pos >= enabler->textures.raws.size())
113 return;
114 enabler->textures.raws[texpos] = NULL;
115}
116
117// create new surface with RGBA32 format and pixels as data
118SDL_Surface* create_texture(std::vector<uint32_t>& pixels, int texture_px_w, int texture_px_h) {

Callers 1

deleteHandleMethod · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected