Quantcast
Channel: Community | MonoGame - Latest topics
Viewing all articles
Browse latest Browse all 6821

Custom effect compile error: Input limit exceeded

$
0
0

@monogany wrote:

The effect compiler that MonoGame uses seems to be less optimized than the XNA one. Most of my effects were just below the 64 instruction limit, but with MonoGame they are over the limit.

This pixel shader input struct worked fine in XNA, but MonoGame gives the error "Input limit (8) exceeded, shader uses 9 inputs". Why is that, and how do I fix it...

struct VertexShaderOutput
{
    float4	PositionPS	: POSITION;		// POSITION may not be used in Pixel shader
	float2	TexCoord	: TEXCOORD0;
	float4	PositionWS	: TEXCOORD1;
	float3	NormalWS	: TEXCOORD2;
	float4	Diffuse		: COLOR0;		// diffuse.rgb and alpha
	
	float3 Reflection : TEXCOORD3; // for reflection/environment mapping
    float3 Fresnel : COLOR1;	// for reflection/environment mapping
    float2 DistanceFromViewer : TEXCOORD4;
    float4 ScreenPosition : TEXCOORD5; // copy the screen pos. info here...
    float2 ScanLinesTexCoords	: TEXCOORD6;
};

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 6821

Trending Articles