mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-15 20:09:14 +02:00
fix the c++ header generation for mac though the brand new raw string format of c++11
This commit is contained in:
parent
641768773b
commit
42157161e0
2 changed files with 11 additions and 5 deletions
|
@ -21,9 +21,9 @@ uniform float alphaThreshold;
|
|||
varying vec4 normal;
|
||||
|
||||
void main(void) {
|
||||
// set the diffuse, normal, specular data
|
||||
vec4 diffuse = texture2D(diffuseMap, gl_TexCoord[0].st);
|
||||
gl_FragData[0] = vec4(gl_Color.rgb * diffuse.rgb, mix(gl_Color.a, 1.0 - gl_Color.a, step(diffuse.a, alphaThreshold)));
|
||||
gl_FragData[1] = normalize(normal) * 0.5 + vec4(0.5, 0.5, 0.5, 1.0);
|
||||
// set the diffuse, normal, specular data
|
||||
vec4 diffuse = texture2D(diffuseMap, gl_TexCoord[0].st);
|
||||
gl_FragData[0] = vec4(gl_Color.rgb * diffuse.rgb, mix(gl_Color.a, 1.0 - gl_Color.a, step(diffuse.a, alphaThreshold)));
|
||||
gl_FragData[1] = normalize(normal) * 0.5 + vec4(0.5, 0.5, 0.5, 1.0);
|
||||
gl_FragData[2] = vec4(gl_FrontMaterial.specular.rgb, gl_FrontMaterial.shininess / 128.0);
|
||||
}
|
||||
|
|
|
@ -192,16 +192,22 @@ int main (int argc, char** argv) {
|
|||
targetStringStream << "#ifndef scribe_" << targetName << "_h" << std::endl;
|
||||
targetStringStream << "#define scribe_" << targetName << "_h" << std::endl << std::endl;
|
||||
|
||||
targetStringStream << "const char " << targetName << "[] = R\"XXX(" << destStringStream.str() << ")XXX\";";
|
||||
/*
|
||||
targetStringStream << "const char " << targetName << "[] = {\n";
|
||||
|
||||
std::stringstream destStringStreamAgain(destStringStream.str());
|
||||
while (!destStringStreamAgain.eof()) {
|
||||
std::string line;
|
||||
std::getline(destStringStreamAgain, line);
|
||||
|
||||
|
||||
if (line.find_first_of('/t') )
|
||||
targetStringStream << "\"" << line << "\\n\"" << std::endl;
|
||||
}
|
||||
targetStringStream << "};" << std::endl << std::endl;
|
||||
|
||||
*/
|
||||
targetStringStream << std::endl << std::endl;
|
||||
targetStringStream << "#endif" << std::endl;
|
||||
} else {
|
||||
targetStringStream << destStringStream.str();
|
||||
|
|
Loading…
Reference in a new issue