mirror of
https://github.com/projectM-visualizer/projectm.git
synced 2026-02-27 01:05:26 +00:00
Say hello to compiled-in textures
git-svn-id: https://projectm.svn.sourceforge.net/svnroot/projectm/trunk@544 6778bc44-b910-0410-a7a0-be141de4315d
This commit is contained in:
@ -1,13 +1,47 @@
|
||||
#include "TextureManager.hpp"
|
||||
#include "CustomShape.hpp"
|
||||
#include "Common.hpp"
|
||||
|
||||
#include "IdleTextures.hpp"
|
||||
|
||||
|
||||
|
||||
TextureManager::TextureManager(const std::string _presetURL): presetURL(_presetURL)
|
||||
{
|
||||
;
|
||||
GLuint tex = SOIL_load_OGL_texture_from_memory(
|
||||
M_data,
|
||||
M_bytes,
|
||||
SOIL_LOAD_AUTO,
|
||||
SOIL_CREATE_NEW_ID,
|
||||
|
||||
SOIL_FLAG_POWER_OF_TWO
|
||||
| SOIL_FLAG_MULTIPLY_ALPHA
|
||||
| SOIL_FLAG_COMPRESS_TO_DXT
|
||||
);
|
||||
textures["M.tga"]=tex;
|
||||
|
||||
tex = SOIL_load_OGL_texture_from_memory(
|
||||
project_data,
|
||||
project_bytes,
|
||||
SOIL_LOAD_AUTO,
|
||||
SOIL_CREATE_NEW_ID,
|
||||
|
||||
SOIL_FLAG_POWER_OF_TWO
|
||||
| SOIL_FLAG_MULTIPLY_ALPHA
|
||||
| SOIL_FLAG_COMPRESS_TO_DXT
|
||||
);
|
||||
textures["project.tga"]=tex;
|
||||
|
||||
tex = SOIL_load_OGL_texture_from_memory(
|
||||
headphones_data,
|
||||
headphones_bytes,
|
||||
SOIL_LOAD_AUTO,
|
||||
SOIL_CREATE_NEW_ID,
|
||||
|
||||
SOIL_FLAG_POWER_OF_TWO
|
||||
| SOIL_FLAG_MULTIPLY_ALPHA
|
||||
| SOIL_FLAG_COMPRESS_TO_DXT
|
||||
);
|
||||
textures["headphones.tga"]=tex;
|
||||
}
|
||||
|
||||
TextureManager::~TextureManager()
|
||||
|
||||
Reference in New Issue
Block a user