Eduardo Bart 13 years ago
parent 8926f33679
commit 1339e18202

@ -33,6 +33,7 @@ bool ParticleManager::load(const std::string& filename)
try {
OTMLDocumentPtr doc = OTMLDocument::parse(filename);
const OTMLNodePtr& node = doc->at("ParticleSystem");
for(const OTMLNodePtr& node : doc->children()) {
if(node->tag() == "ParticleSystem") {
ParticleSystemPtr particleSystem = ParticleSystemPtr(new ParticleSystem);

@ -56,6 +56,7 @@ bool Shader::compileSourceCode(const std::string& sourceCode)
"#ifndef GL_FRAGMENT_PRECISION_HIGH\n"
"#define highp mediump\n"
"#endif\n";
"precision highp float;\n"
#endif
std::string code = qualifierDefines;

@ -67,7 +67,8 @@ uint Texture::internalLoadGLTexture(uchar *pixels, int channels, int width, int
std::vector<uint8> tmp;
// old opengl drivers only accept power of two dimensions
//if(!g_painter.isExtensionSupported("GL_ARB_texture_non_power_of_two")) {
/*
if(!g_painter.isExtensionSupported("GL_ARB_texture_non_power_of_two")) {
int glWidth = 1;
while(glWidth < width)
glWidth = glWidth << 1;
@ -86,8 +87,8 @@ uint Texture::internalLoadGLTexture(uchar *pixels, int channels, int width, int
}
m_glSize.resize(glWidth, glHeight);
//} else
// m_glSize = m_size;
} else */
m_glSize = m_size;
// detect pixels GL format
GLenum format = 0;

Loading…
Cancel
Save