So, here's how my shader structure currently looks:
Shader1_fp.hlsl:
Code: Select all
float4 mainFP() : COLOR
{
return float4(1.0, 0.7, 0.0, 1.0);
}
Code: Select all
float4 mainVP(float4 pos : POSITION, uniform float4x4 worldViewProj_m) : POSITION
{
return mul(worldViewProj_m, pos);
}
Code: Select all
vertex_program Shader1_HLSL_vp hlsl
{
source Shader1_vp.hlsl
entry_point mainVP
target vs_3_0
default_params
{
param_named_auto worldViewProj_m worldviewproj_matrix
}
}
fragment_program Shader1_HLSL_fp hlsl
{
source Shader1_fp.hlsl
entry_point mainFP
target ps_3_0
}
material Shader1_HLSL
{
technique
{
pass
{
vertex_program_ref Shader1_HLSL_vp
{
}
fragment_program_ref Shader1_HLSL_fp
{
}
}
}
}
and:23:02:07: WARNING: material Shader1_HLSL has no supportable Techniques and will be blank. Explanation:
Pass 0: Vertex program Shader1_HLSL_vp cannot be used - not supported.
Code: Select all
23:02:07: OGRE EXCEPTION(3:RenderingAPIException): Attempted to render to a D3D11 device without both vertex and fragment shaders there is no fixed pipeline in d3d11 - use the RTSS or write custom shaders. in D3D11RenderSystem::_render at D:\Libraries\ogre\RenderSystems\Direct3D11\src\OgreD3D11RenderSystem.cpp (line 2082)

Is there anything special that needs to be specified in the materials/shaders to make them work with Direct3D 11 ?
-----------------------------------------------------------------------------------------------------
My problem has been solved:
Go to answer.
(or just scroll down to the last post
