Model Viewer crashes on start up. 
			 
			
				My Model Viewer crashes as pretty much as soon as it starts up and starts working. It shows the Initializing... text at the top next to the program name and then the No Model Loaded! and then stops working and the screen never boots up the Model Viewer screen, it remains black until it crashes. I have included the log below. 
 
-------- THE HPL ENGINE LOG ------------ 
Engine build ID 20100731000830 
 
Creating Engine Modules 
-------------------------------------------------------- 
 Creating graphics module 
 Creating system module 
 Creating resource module 
 Creating input module 
 Creating sound module 
 Creating physics module 
 Creating ai module 
 Creating gui module 
 Creating generate module 
 Creating haptic module 
 Creating scene module 
-------------------------------------------------------- 
 
Initializing Resources Module 
-------------------------------------------------------- 
 Creating loader handlers  
 Creating resource managers 
 Adding loaders to handlers  
-------------------------------------------------------- 
 
Initializing Graphics Module 
-------------------------------------------------------- 
 Setting video mode: 1024 x 768 - 32 bpp 
 Init Glew...OK 
 Setting up OpenGL 
  Vendor: Intel 
  Renderer: Intel® HD Graphics 
  Version: 3.1.0 - Build 9.17.10.3062 
  Max texture image units: 16 
  Max texture coord units: 8 
  Max user clip planes: 6 
  Two sided stencil: 1 
  Vertex Buffer Object: 1 
  Anisotropic filtering: 1 
  Max Anisotropic degree: 16 
  Multisampling: 1 
  Texture compression: 1 
  Texture compression S3TC: 1 
  Auto generate MipMaps: 1 
  Render to texture: 1 
  Max draw buffers: 8 
  Max color render targets: 8 
  Packed depth-stencil: 1 
  Texture float: 1 
  GLSL Version: 1.40 - Intel Build 9.17.10.3062 
  ShaderModel 2: 1 
  ShaderModel 3: 1 
  ShaderModel 4: 0 
  OGL ATIFragmentShader: 0 
ERROR: Failed to compile GLSL shader 'C:/Program Files (x86)/Amnesia - The Dark Descent/redist/core/shaders/deferred_ssao_blur_frag.glsl'! 
Shader code: 
------------------- 
[0001] #version 120 
[0002] #extension GL_ARB_texture_rectangle : enable 
[0003]  
[0004] //////////////////// 
[0005] // Arguments 
[0006] uniform float afFarPlane; 
[0007]  
[0008] //////////////////// 
[0009] // Samplers 
[0010] uniform sampler2DRect occMap; 
[0011]  
[0012]  
[0013] uniform sampler2DRect depthMap; 
[0014]  
[0015]  
[0016] //////////////////////////////////// 
[0017] // Initialize these down in MAIN due to Mac OS X OpenGL Driver 
[0018]  
[0019] 	const float vMul[9] = float[9](0.05, 0.1, 0.25, 0.3, 0.1, 0.3, 0.25, 0.1, 0.05); 
[0020] 	const float fOffset[9] = float[9](-3.35, -2.35, -1.35, -0.35, 0.0, 0.35, 1.35, 2.35, 3.35); 
[0021]  
[0022]  
[0023] //////////////////// 
[0024] // MAIN 
[0025] void main() 
[0026] { 
[0027] 	//Mac cannot initialize outside of main 
[0028]  
[0029] 	//Get the core (at center) depth and create the minimum depth based on that. 
[0030] 	float fCoreDepth = texture2DRect(depthMap, gl_FragCoord.xy).x; 
[0031] 	float fMinDepth =  fCoreDepth - 0.2 / afFarPlane; 
[0032] 	//float fMaxDepth =  fCoreDepth + 0.5 / afFarPlane; <- can skip since it does not give that much impact. 
[0033] 	 
[0034] 	//Offset mul depends on the direction of the blur.	 
[0035] 	float fBlurSize = 2.0; 
[0036]  
[0037] 		vec2 vOffsetMul = vec2(1.0, 0.0) * fBlurSize; 
[0038]  
[0039] 		 
[0040] 	 
[0041] 	vec3 vAmount =vec3(0.0); 
[0042] 	float fMulSum =0.0; 
[0043] 	for(int i=0; i<9; i+=1) 
[0044] 	{	 
[0045] 		vec2 vCoordOffset = fOffset[i] * vOffsetMul; 
[0046] 		vec2 vUVPos = gl_TexCoord[0].xy + vCoordOffset; 
[0047] 				 
[0048] 		vec3 vOcc = texture2DRect(occMap, vUVPos).xyz; 
[0049] 		float fDepth = texture2DRect(depthMap, vUVPos).x; 
[0050] 	 
[0051] 		float fMul = vMul[i]; 
[0052] 		 
[0053] 		//Skip any pixels where depth is lower (in front of) the core depth 
[0054] 		//Do not want foreground leaking into background (opposite is acceptable though) 
[0055] 		if(fDepth < fMinDepth) fMul*=0.25; 
[0056] 		//if(fDepth > fMaxDepth) fMul=0; <- can skip since it does not give that much impact. 
[0057] 		 
[0058] 		vOcc *= fMul; 
[0059] 		 
[0060] 		fMulSum += fMul; 
[0061] 		vAmount += vOcc; 
[0062] 	} 
[0063] 	 
[0064] 	vAmount /= fMulSum; 
[0065] 		 
[0066] 	gl_FragColor.xyz = vAmount; 
--------------------- 
Compile log: 
--------------------- 
ERROR: 0:19: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:19: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:20: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:20: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:45: 'fOffset' :  left of '[' is not of type array, matrix, or vector   
ERROR: 0:51: 'vMul' :  left of '[' is not of type array, matrix, or vector   
 
 
--------------------- 
ERROR: Couldn't create program 'deferred_ssao_blur_frag.glsl' 
ERROR: Failed to compile GLSL shader 'C:/Program Files (x86)/Amnesia - The Dark Descent/redist/core/shaders/deferred_ssao_blur_frag.glsl'! 
Shader code: 
------------------- 
[0001] #version 120 
[0002] #extension GL_ARB_texture_rectangle : enable 
[0003]  
[0004] //////////////////// 
[0005] // Arguments 
[0006] uniform float afFarPlane; 
[0007]  
[0008] //////////////////// 
[0009] // Samplers 
[0010] uniform sampler2DRect occMap; 
[0011]  
[0012]  
[0013] uniform sampler2DRect depthMap; 
[0014]  
[0015]  
[0016] //////////////////////////////////// 
[0017] // Initialize these down in MAIN due to Mac OS X OpenGL Driver 
[0018]  
[0019] 	const float vMul[9] = float[9](0.05, 0.1, 0.25, 0.3, 0.1, 0.3, 0.25, 0.1, 0.05); 
[0020] 	const float fOffset[9] = float[9](-3.35, -2.35, -1.35, -0.35, 0.0, 0.35, 1.35, 2.35, 3.35); 
[0021]  
[0022]  
[0023] //////////////////// 
[0024] // MAIN 
[0025] void main() 
[0026] { 
[0027] 	//Mac cannot initialize outside of main 
[0028]  
[0029] 	//Get the core (at center) depth and create the minimum depth based on that. 
[0030] 	float fCoreDepth = texture2DRect(depthMap, gl_FragCoord.xy).x; 
[0031] 	float fMinDepth =  fCoreDepth - 0.2 / afFarPlane; 
[0032] 	//float fMaxDepth =  fCoreDepth + 0.5 / afFarPlane; <- can skip since it does not give that much impact. 
[0033] 	 
[0034] 	//Offset mul depends on the direction of the blur.	 
[0035] 	float fBlurSize = 2.0; 
[0036]  
[0037] 		vec2 vOffsetMul = vec2(0.0, 1.0) * fBlurSize; 
[0038]  
[0039] 		 
[0040] 	 
[0041] 	vec3 vAmount =vec3(0.0); 
[0042] 	float fMulSum =0.0; 
[0043] 	for(int i=0; i<9; i+=1) 
[0044] 	{	 
[0045] 		vec2 vCoordOffset = fOffset[i] * vOffsetMul; 
[0046] 		vec2 vUVPos = gl_TexCoord[0].xy + vCoordOffset; 
[0047] 				 
[0048] 		vec3 vOcc = texture2DRect(occMap, vUVPos).xyz; 
[0049] 		float fDepth = texture2DRect(depthMap, vUVPos).x; 
[0050] 	 
[0051] 		float fMul = vMul[i]; 
[0052] 		 
[0053] 		//Skip any pixels where depth is lower (in front of) the core depth 
[0054] 		//Do not want foreground leaking into background (opposite is acceptable though) 
[0055] 		if(fDepth < fMinDepth) fMul*=0.25; 
[0056] 		//if(fDepth > fMaxDepth) fMul=0; <- can skip since it does not give that much impact. 
[0057] 		 
[0058] 		vOcc *= fMul; 
[0059] 		 
[0060] 		fMulSum += fMul; 
[0061] 		vAmount += vOcc; 
[0062] 	} 
[0063] 	 
[0064] 	vAmount /= fMulSum; 
[0065] 		 
[0066] 	gl_FragColor.xyz = vAmount; 
--------------------- 
Compile log: 
--------------------- 
ERROR: 0:19: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:19: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:20: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:20: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:45: 'fOffset' :  left of '[' is not of type array, matrix, or vector   
ERROR: 0:51: 'vMul' :  left of '[' is not of type array, matrix, or vector   
 
 
--------------------- 
ERROR: Couldn't create program 'deferred_ssao_blur_frag.glsl' 
 Adding engine materials 
 Adding engine post effects 
ERROR: Failed to compile GLSL shader 'C:/Program Files (x86)/Amnesia - The Dark Descent/redist/core/shaders/posteffect_bloom_blur_frag.glsl'! 
Shader code: 
------------------- 
[0001] //////////////////////////////////////////////////////// 
[0002] // PostEffect Bloom Blur - Fragment Shader 
[0003] // 
[0004] // Blur effect for the bloom post effect 
[0005] //////////////////////////////////////////////////////// 
[0006]  
[0007] #version 120 
[0008] #extension GL_ARB_texture_rectangle : enable 
[0009]  
[0010] uniform sampler2DRect diffuseMap; 
[0011]  
[0012]  
[0013] uniform float afBlurSize; 
[0014]  
[0015] // Initialize these down in MAIN due to Mac OS X OpenGL Driver 
[0016]  
[0017] 	const float vMul[5] = float[5]   ( 0.25,  0.3, 0.5, 0.3, 0.25); 
[0018] 	const float fOffset[5] = float[5]( -2.5, -0.75, 0.0, 0.75,  2.5); 
[0019]  
[0020] const float fMulSum = 0.25+0.3+0.5+0.3+0.25; 
[0021]  
[0022] void main() 
[0023] { 
[0024]  
[0025] 	vec3 vAmount =vec3(0); 
[0026] 	 
[0027]  
[0028] 		vec2 vOffsetMul = vec2(0.0, 1.0)*afBlurSize; 
[0029]  
[0030] 	 
[0031] 	for(int i=0; i<5; i+=1) 
[0032] 	{	 
[0033] 		vec2 vOffset = vec2(fOffset[i])*vOffsetMul; 
[0034] 		vec3 vColor = texture2DRect(diffuseMap, gl_TexCoord[0].xy + vOffset).xyz; 
[0035] 		vAmount += vColor * vMul[i]; 
[0036] 	} 
[0037] 	 
[0038] 	vAmount /= fMulSum; 
[0039] 	 
[0040] 	gl_FragColor.xyz = vAmount; 
[0041] 	gl_FragColor.w = 1.0; 
--------------------- 
Compile log: 
--------------------- 
ERROR: 0:17: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:17: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:18: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:18: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:33: 'fOffset' :  left of '[' is not of type array, matrix, or vector   
ERROR: 0:35: 'vMul' :  left of '[' is not of type array, matrix, or vector   
 
 
--------------------- 
ERROR: Couldn't create program 'posteffect_bloom_blur_frag.glsl' 
ERROR: Failed to compile GLSL shader 'C:/Program Files (x86)/Amnesia - The Dark Descent/redist/core/shaders/posteffect_bloom_blur_frag.glsl'! 
Shader code: 
------------------- 
[0001] //////////////////////////////////////////////////////// 
[0002] // PostEffect Bloom Blur - Fragment Shader 
[0003] // 
[0004] // Blur effect for the bloom post effect 
[0005] //////////////////////////////////////////////////////// 
[0006]  
[0007] #version 120 
[0008] #extension GL_ARB_texture_rectangle : enable 
[0009]  
[0010] uniform sampler2DRect diffuseMap; 
[0011]  
[0012]  
[0013] uniform float afBlurSize; 
[0014]  
[0015] // Initialize these down in MAIN due to Mac OS X OpenGL Driver 
[0016]  
[0017] 	const float vMul[5] = float[5]   ( 0.25,  0.3, 0.5, 0.3, 0.25); 
[0018] 	const float fOffset[5] = float[5]( -2.5, -0.75, 0.0, 0.75,  2.5); 
[0019]  
[0020] const float fMulSum = 0.25+0.3+0.5+0.3+0.25; 
[0021]  
[0022] void main() 
[0023] { 
[0024]  
[0025] 	vec3 vAmount =vec3(0); 
[0026] 	 
[0027]  
[0028] 		vec2 vOffsetMul = vec2(1.0, 0.0)*afBlurSize; 
[0029]  
[0030] 	 
[0031] 	for(int i=0; i<5; i+=1) 
[0032] 	{	 
[0033] 		vec2 vOffset = vec2(fOffset[i])*vOffsetMul; 
[0034] 		vec3 vColor = texture2DRect(diffuseMap, gl_TexCoord[0].xy + vOffset).xyz; 
[0035] 		vAmount += vColor * vMul[i]; 
[0036] 	} 
[0037] 	 
[0038] 	vAmount /= fMulSum; 
[0039] 	 
[0040] 	gl_FragColor.xyz = vAmount; 
[0041] 	gl_FragColor.w = 1.0; 
--------------------- 
Compile log: 
--------------------- 
ERROR: 0:17: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:17: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:18: 'const float' : cannot declare arrays of this qualifier  
ERROR: 0:18: 'const' :  non-matching types (using implicit conversion) for const initializer   
ERROR: 0:33: 'fOffset' :  left of '[' is not of type array, matrix, or vector   
ERROR: 0:35: 'vMul' :  left of '[' is not of type array, matrix, or vector   
 
 
--------------------- 
ERROR: Couldn't create program 'posteffect_bloom_blur_frag.glsl' 
-------------------------------------------------------- 
 
Initializing Sound Module 
-------------------------------------------------------- 
 Initializing OpenAL 
  Trying to open device 'Generic Software on Speakers (Realtek High Definition Audio)'... Success! 
  Number of mono sources: 32 
-------------------------------------------------------- 
 
Initializing Game Module 
-------------------------------------------------------- 
 Adding engine updates 
 Initializing script functions 
-------------------------------------------------------- 
 
User Initialization 
-------------------------------------------------------- 
-------------------------------------------------------- 
 
Game Running 
-------------------------------------------------------- 
			 
			
			
 
-Grind to the Gore- 
			
		 |