Minetest  5.4.0
tile.h File Reference
#include "irrlichttypes.h"
#include "irr_v3d.h"
#include <ITexture.h>
#include <string>
#include <vector>
#include <SMaterial.h>
#include "util/numeric.h"
#include "config.h"
+ Include dependency graph for tile.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  ISimpleTextureSource
 
class  ITextureSource
 
class  IWritableTextureSource
 
struct  FrameSpec
 
struct  TileLayer
 Defines a layer of a tile. More...
 
struct  TileSpec
 

Macros

#define MATERIAL_FLAG_BACKFACE_CULLING   0x01
 
#define MATERIAL_FLAG_CRACK   0x02
 
#define MATERIAL_FLAG_CRACK_OVERLAY   0x04
 
#define MATERIAL_FLAG_ANIMATION   0x08
 
#define MATERIAL_FLAG_TILEABLE_HORIZONTAL   0x20
 
#define MATERIAL_FLAG_TILEABLE_VERTICAL   0x40
 
#define MAX_TILE_LAYERS   2
 

Typedefs

typedef std::vector< video::SColor > Palette
 

Enumerations

enum  MaterialType {
  TILE_MATERIAL_BASIC , TILE_MATERIAL_ALPHA , TILE_MATERIAL_LIQUID_TRANSPARENT , TILE_MATERIAL_LIQUID_OPAQUE ,
  TILE_MATERIAL_WAVING_LEAVES , TILE_MATERIAL_WAVING_PLANTS , TILE_MATERIAL_OPAQUE , TILE_MATERIAL_WAVING_LIQUID_BASIC ,
  TILE_MATERIAL_WAVING_LIQUID_TRANSPARENT , TILE_MATERIAL_WAVING_LIQUID_OPAQUE , TILE_MATERIAL_PLAIN , TILE_MATERIAL_PLAIN_ALPHA
}
 

Functions

std::string getImagePath (std::string path)
 
std::string getTexturePath (const std::string &filename, bool *is_base_pack=nullptr)
 
void clearTextureNameCache ()
 
IWritableTextureSourcecreateTextureSource ()
 
std::vector< std::string > getTextureDirs ()
 

Macro Definition Documentation

◆ MATERIAL_FLAG_ANIMATION

#define MATERIAL_FLAG_ANIMATION   0x08

◆ MATERIAL_FLAG_BACKFACE_CULLING

#define MATERIAL_FLAG_BACKFACE_CULLING   0x01

◆ MATERIAL_FLAG_CRACK

#define MATERIAL_FLAG_CRACK   0x02

◆ MATERIAL_FLAG_CRACK_OVERLAY

#define MATERIAL_FLAG_CRACK_OVERLAY   0x04

◆ MATERIAL_FLAG_TILEABLE_HORIZONTAL

#define MATERIAL_FLAG_TILEABLE_HORIZONTAL   0x20

◆ MATERIAL_FLAG_TILEABLE_VERTICAL

#define MATERIAL_FLAG_TILEABLE_VERTICAL   0x40

◆ MAX_TILE_LAYERS

#define MAX_TILE_LAYERS   2

Typedef Documentation

◆ Palette

typedef std::vector<video::SColor> Palette

Enumeration Type Documentation

◆ MaterialType

Enumerator
TILE_MATERIAL_BASIC 
TILE_MATERIAL_ALPHA 
TILE_MATERIAL_LIQUID_TRANSPARENT 
TILE_MATERIAL_LIQUID_OPAQUE 
TILE_MATERIAL_WAVING_LEAVES 
TILE_MATERIAL_WAVING_PLANTS 
TILE_MATERIAL_OPAQUE 
TILE_MATERIAL_WAVING_LIQUID_BASIC 
TILE_MATERIAL_WAVING_LIQUID_TRANSPARENT 
TILE_MATERIAL_WAVING_LIQUID_OPAQUE 
TILE_MATERIAL_PLAIN 
TILE_MATERIAL_PLAIN_ALPHA 

Function Documentation

◆ clearTextureNameCache()

void clearTextureNameCache ( )

References g_texturename_to_path_cache.

Referenced by Game::extendedResourceCleanup().

+ Here is the caller graph for this function:

◆ createTextureSource()

IWritableTextureSource* createTextureSource ( )

Referenced by Game::init().

+ Here is the caller graph for this function:

◆ getImagePath()

std::string getImagePath ( std::string  path)

References fs::PathExists(), removeStringEnd(), and replace_ext().

Referenced by findSubgame(), and getTexturePath().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTextureDirs()

std::vector<std::string> getTextureDirs ( )

References g_settings, Settings::get(), and fs::GetRecursiveDirs().

Referenced by Client::afterContentReceived(), and getTexturePath().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTexturePath()

std::string getTexturePath ( const std::string &  filename,
bool *  is_base_pack = nullptr 
)

References DIR_DELIM, g_texturename_to_path_cache, getImagePath(), getTextureDirs(), and porting::path_share.

Referenced by SourceImageCache::getOrLoad(), SourceImageCache::insert(), and TextureSource::isKnownSourceImage().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: