Porting to web
This commit is contained in:
1 parent
6961152d34
commit
723b973c7f
16 files changed
+182
-22
No files matched your search
@@ -44,11 +44,19 @@ namespace ZL {
|
||||
|
||||
if (!vertexShaderCompiled)
|
||||
{
|
||||
#ifdef EMSCRIPTEN
|
||||
std::cout << "Failed to compile vertex shader code!" << std::endl;
|
||||
std::cout << infoLog << std::endl;
|
||||
#endif
|
||||
throw std::runtime_error("Failed to compile vertex shader code!");
|
||||
}
|
||||
|
||||
if (!fragmentShaderCompiled)
|
||||
{
|
||||
#ifdef EMSCRIPTEN
|
||||
std::cout << "Failed to compile fragment shader code!" << std::endl;
|
||||
std::cout << infoLog2 << std::endl;
|
||||
#endif
|
||||
throw std::runtime_error("Failed to compile fragment shader code!");
|
||||
}
|
||||
|
||||
@@ -67,6 +75,10 @@ namespace ZL {
|
||||
|
||||
if (!programLinked)
|
||||
{
|
||||
#ifdef EMSCRIPTEN
|
||||
std::cout << "Failed to link shader program!" << std::endl;
|
||||
std::cout << infoLog << std::endl;
|
||||
#endif
|
||||
shaderProgram = 0;
|
||||
throw std::runtime_error("Failed to link shader program!");
|
||||
}
|
||||
@@ -202,7 +214,7 @@ namespace ZL {
|
||||
|
||||
|
||||
ShaderSetter::ShaderSetter(ShaderManager& inShaderManager, const std::string& shaderName)
|
||||
: shaderManager(shaderManager)
|
||||
: shaderManager(inShaderManager)
|
||||
{
|
||||
shaderManager.PushShader(shaderName);
|
||||
}
|
||||
|
||||
@@ -27,7 +27,11 @@ namespace ZL
|
||||
};
|
||||
|
||||
BitSize bitSize;
|
||||
#ifdef SIMPLIFIED
|
||||
MipmapType mipmap = NONE; // Ïî óìîë÷àíèþ âêëþ÷åíî
|
||||
#else
|
||||
MipmapType mipmap = GENERATE; // Ïî óìîë÷àíèþ âêëþ÷åíî
|
||||
#endif
|
||||
};
|
||||
class Texture
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user