blob: 1e24df567162ab01b1b70c55fdc973a06f28cc8c [file] [log] [blame]
R"SKSL(
// *********************************************************
// *** AUTOGENERATED BY create_sksl_fp.py, DO NOT EDIT ***
// *********************************************************
/*
* Copyright 2017 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/*************************************************************************************************/
/* This file is used from both C++ and SkSL, so we need to stick to syntax compatible with both. */
/*************************************************************************************************/
/**
* We have coverage effects that clip rendering to the edge of some geometric primitive.
* This enum specifies how that clipping is performed. Not all factories that take a
* GrProcessorEdgeType will succeed with all values and it is up to the caller to verify success.
*/
enum class GrClipEdgeType {
kFillBW,
kFillAA,
kInverseFillBW,
kInverseFillAA,
kLast = kInverseFillAA
};
enum class PMConversion {
kToPremul = 0,
kToUnpremul = 1,
kPMConversionCnt = 2
};
// defines built-in interfaces supported by SkiaSL fragment shaders
layout(builtin=15) in float4 sk_FragCoord;
layout(builtin=3) float sk_ClipDistance[1];
layout(builtin=20) out int sk_SampleMask[1];
// 9999 is a temporary value that causes us to ignore these declarations beyond
// adding them to the symbol table. This works fine in GLSL (where they do not
// require any further handling) but will fail in SPIR-V. We'll have a better
// solution for this soon.
layout(builtin=9999) float4 gl_LastFragData[1];
layout(builtin=9999) half4 gl_LastFragColor;
layout(builtin=9999) half4 gl_LastFragColorARM;
layout(builtin=9999) half4 gl_SecondaryFragColorEXT;
layout(builtin=10003) half4 sk_InColor;
layout(builtin=10004) out half4 sk_OutColor;
layout(builtin=10006) sampler2D[] sk_TextureSamplers;
layout(builtin=10011) half sk_Width;
layout(builtin=10012) half sk_Height;
half4 sample(fragmentProcessor fp);
half4 sample(fragmentProcessor fp, float3x3 transform);
half4 sample(fragmentProcessor fp, float2 coords);
half4 sample(fragmentProcessor fp, half4 input);
half4 sample(fragmentProcessor fp, half4 input, float3x3 transform);
half4 sample(fragmentProcessor fp, half4 input, float2 coords);
half4 sample(fragmentProcessor? fp);
half4 sample(fragmentProcessor? fp, float3x3 transform);
half4 sample(fragmentProcessor? fp, float2 coords);
half4 sample(fragmentProcessor? fp, half4 input);
half4 sample(fragmentProcessor? fp, half4 input, float3x3 transfrom);
half4 sample(fragmentProcessor? fp, half4 input, float2 coords);
)SKSL";