Skip to content

Incorrect precision when reading from texture #42

Description

@GregSlazinski

I use this code to specify high precision for "Depth" sampler:

      HLSLccSamplerPrecisionInfo sampler_precision;
      sampler_precision.insert(std::pair<std::string, REFLECT_RESOURCE_PRECISION>("Depth" , REFLECT_RESOURCE_PRECISION_HIGHP));

and in HLSL I read from that sampler, store results in float4 (high prec)
float4 value=read from Depth..

However the generated GLSL code gives me:

layout(location = 3) uniform highp sampler2D Depth; // THIS OK
mediump vec4 u_xlat10_0; // THIS NOT OK
void main()
{
    u_xlat10_0 = textureLod(Depth, vs_TEXCOORD0.xy, 0.0);

the u_xlat10_0 is defined as mediump

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions