ok...some issues :
I have a Intel GMA950 Integrated Graphics Card so I don't have those fancy things the newest graphics cards has.
I got PixelShader support to 2.0 and VertexShader support to 3.0
However the clouds in caelum uses PS3.0
I tried to lower it to PS2.0 but that gave me some errors :
Code: Select all
22:50:32: Parsing script LayeredClouds.material
22:50:32: OGRE EXCEPTION(7:InternalErrorException): Unable to compile Cg program CaelumLayeredCloudsFP: CG ERROR : The compile returned an error.
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(0) : error C6003: Arithmetic instruction limit of 64 exceeded; 88 arithmetic instructions needed to compile program
in CgProgram::loadFromSource at c:\ogrewin1.6\ogre\plugins\cgprogrammanager\src\ogrecgprogrammanagerdll.cpp (line 66)
22:50:32: High-level program CaelumLayeredCloudsFP encountered an error during loading and is thus not supported.
OGRE EXCEPTION(7:InternalErrorException): Unable to compile Cg program CaelumLayeredCloudsFP: CG ERROR : The compile returned an error.
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(203) : warning C7011: implicit cast from "float4" to "float3"
(0) : error C6003: Arithmetic instruction limit of 64 exceeded; 88 arithmetic instructions needed to compile program
in CgProgram::loadFromSource at c:\ogrewin1.6\ogre\plugins\cgprogrammanager\src\ogrecgprogrammanagerdll.cpp (line 66)
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(44): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(45): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(46): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(49): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(53): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(55): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(58): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(60): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(63): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(65): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(69): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(72): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(75): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(77): setting of constant failed
22:50:32: OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at c:\ogrewin1.6\ogre\ogremain\src\ogregpuprogram.cpp (line 1085)
22:50:32: Compiler error: invalid parameters in LayeredClouds.material(78): setting of constant failed
the rest is working....the only thing that isn't working are the clouds.
I use Caelum SVN Trunk.
I tried the same code on my parents pc (wich have PS3.0 and VS3.0)
and there it worked perfectly.
Does anyone know if i can bypass these issues to make it support PS2.0 ?
My LayeredClouds.material :
Code: Select all
//
//This file is part of Caelum.
//See http://www.ogre3d.org/wiki/index.php/Caelum
//
//Copyright (c) 2006-2007 Caelum team. See Contributors.txt for details.
//
//Caelum is free software: you can redistribute it and/or modify
//it under the terms of the GNU Lesser General Public License as published
//by the Free Software Foundation, either version 3 of the License, or
//(at your option) any later version.
//
//Caelum is distributed in the hope that it will be useful,
//but WITHOUT ANY WARRANTY; without even the implied warranty of
//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
//GNU Lesser General Public License for more details.
//
//You should have received a copy of the GNU Lesser General Public License
//along with Caelum. If not, see <http://www.gnu.org/licenses/>.
//
vertex_program CaelumLayeredCloudsVP cg
{
source CaelumLayeredClouds.cg
entry_point LayeredClouds_vp
profiles vs_3_0 vp40 arbvp1
compile_arguments -posinv
default_params
{
param_named_auto worldViewProj worldviewproj_matrix
param_named sunDirection float3 -1 -1 0
}
}
fragment_program CaelumLayeredCloudsFP cg
{
source CaelumLayeredClouds.cg
entry_point LayeredClouds_fp
profiles ps_2_0 fp40 arbfp1
default_params
{
// Caelum sky properties
param_named sunLightColour float4 1 1 1 1
param_named sunSphereColour float4 1 1 1 1
param_named sunDirection float4 1 1 1 1
// Fog colour; used as the base cloud colour.
param_named fogColour float4 0 0 0 0
// The inverse of the cloud forms scale
param_named cloudMassInvScale float 1.2
// The inverse of the cloud details scale
param_named cloudDetailInvScale float 4.8
// Cloud mass offset
param_named cloudMassOffset float2 0 0
// Cloud details offset
param_named cloudDetailOffset float2 0.5 0.5
// Blending factor between Cloud1 and Cloud2
param_named cloudMassBlend float 0.9
// Cloud detail weight.
param_named cloudDetailBlend float 0.5
// Cloud coverage, between 0 and 1
param_named cloudCoverageThreshold float 0.9
// Cloud sharpness. Lower values result in softer clouds.
param_named cloudSharpness float 4
// Cloud thickness. Bigger values results in darker clouds.
param_named cloudThickness float 3
param_named_auto camera_position camera_position
param_named layerHeight float 0
}
}
material CaelumLayeredClouds
{
technique
{
pass
{
lighting off
depth_check on
depth_write off
scene_blend alpha_blend
fog_override true
cull_hardware none
vertex_program_ref CaelumLayeredCloudsVP
{
}
fragment_program_ref CaelumLayeredCloudsFP
{
}
texture_unit Cloud1
{
texture noise1.dds
filtering trilinear
tex_coord_set 0
}
texture_unit Cloud2
{
texture noise2.dds
filtering trilinear
tex_coord_set 1
}
texture_unit Detail
{
texture noise4.dds
tex_coord_set 2
}
}
}
}