| // GENERATED FILE - DO NOT EDIT. |
| // Generated by gen_vk_internal_shaders.py. |
| // |
| // Copyright 2018 The ANGLE Project Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| // |
| // shaders/gen/ImageCopy.frag.00000002.inc: |
| // Pre-generated shader for the ANGLE Vulkan back-end. |
| |
| #pragma once |
| constexpr uint8_t kImageCopy_frag_00000002[] = { |
| 0x1f,0x8b,0x08,0x00,0x00,0x00,0x00,0x00,0x02,0xff,0x85,0x58,0x6b,0x4c,0x96,0x65, |
| 0x18,0x7e,0x9f,0xef,0xe3,0xe0,0xa9,0xd2,0x65,0x98,0x8a,0x47,0x6c,0xcb,0xe9,0xc0, |
| 0x02,0x4a,0x25,0x4e,0x9e,0xc8,0x12,0x21,0xcc,0x03,0xb2,0xc5,0x30,0x20,0x95,0x94, |
| 0x4c,0xd2,0x44,0x50,0x3c,0x4d,0xd7,0x66,0x5b,0x63,0xa3,0x84,0x46,0xe5,0x01,0x0d, |
| 0x8b,0x84,0x39,0x45,0xb2,0x7e,0x58,0xc9,0xd6,0x9f,0xfe,0xd4,0xac,0xf4,0x47,0x5a, |
| 0xc1,0x9a,0xb3,0x56,0xea,0x44,0x9a,0xd1,0x73,0xbf,0xcf,0x75,0xfb,0x5d,0x7b,0x97, |
| 0x8b,0xed,0xd9,0xfb,0x3e,0xd7,0x7d,0xba,0xee,0xeb,0x79,0x9e,0xf7,0x7d,0xf9,0xc2, |
| 0xa1,0x84,0x58,0xcf,0x33,0xde,0x10,0x6f,0x90,0xf7,0xb9,0xf1,0xfc,0xbf,0x11,0x5e, |
| 0xc8,0x93,0xdb,0xa1,0x5e,0x8c,0x7f,0xcd,0x59,0xb4,0x64,0x51,0xe2,0xc6,0xaa,0xd2, |
| 0xc4,0x94,0xd4,0x19,0x62,0xbf,0xdf,0x0b,0xfb,0x7e,0x62,0x7b,0xc0,0x8b,0xf5,0xa2, |
| 0xec,0x55,0xc6,0xba,0x92,0x35,0xeb,0x05,0x9f,0x25,0x73,0x6b,0x1c,0x6e,0xfd,0x04, |
| 0x8f,0x95,0x1c,0xf6,0x6e,0x96,0x9f,0x53,0x62,0x3c,0xef,0x69,0x2f,0xda,0xcb,0x74, |
| 0xe5,0xbc,0x04,0x5c,0x15,0x33,0xc0,0x06,0x11,0x16,0x02,0x36,0x9c,0xb0,0x30,0xb0, |
| 0x91,0x84,0x45,0x01,0x7b,0x98,0xb0,0x68,0x60,0xf1,0x84,0xc5,0x00,0x9b,0x48,0x58, |
| 0x2c,0xb0,0x29,0x84,0x0d,0x02,0xf6,0x28,0x61,0x83,0x81,0x4d,0x27,0x6c,0x08,0xb0, |
| 0x19,0x84,0x0d,0x05,0x96,0x42,0xd8,0x30,0x60,0x33,0x09,0xbb,0x0f,0xd8,0x53,0xbe, |
| 0x4e,0xe1,0xbb,0xfd,0x8a,0x66,0xeb,0xec,0x75,0x32,0xf4,0xd1,0xf9,0x24,0x9a,0x8b, |
| 0xce,0xe3,0x31,0x7f,0xd0,0x46,0x85,0x7c,0x7b,0xd8,0xd7,0x46,0xee,0xe3,0xec,0x5d, |
| 0x0c,0xfa,0x9c,0x66,0xfd,0x63,0xa0,0x61,0x7c,0x62,0x6e,0xda,0x48,0xeb,0x31,0x82, |
| 0xf0,0x38,0x3b,0x0a,0x3a,0x17,0x67,0xeb,0x7c,0xac,0x1d,0x4b,0x97,0x7e,0x97,0xa1, |
| 0xf3,0x71,0x76,0xa4,0x0f,0xd9,0x9b,0xa9,0xf3,0x09,0x76,0xb4,0xe5,0x94,0xa4,0xeb, |
| 0x5c,0x74,0xeb,0x69,0x7b,0xe4,0xee,0x3c,0xc9,0x8e,0xc6,0x03,0xa3,0xb3,0x1e,0xb2, |
| 0xf3,0x64,0x70,0x90,0xb5,0x1d,0x65,0xe7,0xa2,0x49,0x32,0x38,0xca,0xfc,0x49,0xac, |
| 0x49,0x94,0xef,0x17,0xe5,0xeb,0x23,0xbe,0x82,0xa7,0x61,0x3e,0x8b,0x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|
| 0xaf,0xa7,0xc3,0x9e,0x6d,0x33,0xc8,0x5e,0x99,0x87,0xfd,0x34,0x07,0xf9,0xc4,0x67, |
| 0x3e,0xf0,0x9d,0xd6,0x47,0xe6,0x0b,0x10,0x37,0x1f,0x71,0xb2,0x87,0x9e,0x45,0xdc, |
| 0x42,0xc4,0xc9,0x3e,0x5a,0x04,0xfc,0xb8,0xf5,0x91,0xf3,0xbc,0x18,0x98,0xec,0xaf, |
| 0x5b,0x96,0x79,0x3e,0xf8,0xf4,0x5b,0xff,0xc5,0x3e,0x5f,0xcf,0xc7,0xa4,0x1f,0xb9, |
| 0x7f,0xce,0xc6,0x89,0x96,0x4b,0x50,0x53,0xfe,0xb6,0x41,0xdf,0xe7,0x81,0x17,0x58, |
| 0x75,0x84,0xd3,0x0e,0xe3,0x30,0xf5,0xbb,0x6d,0x73,0x68,0x2e,0xb9,0xde,0xb4,0x5a, |
| 0x88,0xdf,0x11,0xe3,0x7c,0xa2,0x11,0x93,0x47,0x3d,0x2c,0x47,0x0f,0xcb,0xa8,0x87, |
| 0x15,0xc0,0xb5,0x87,0x42,0x60,0xda,0x43,0x11,0xf5,0x20,0xb6,0x95,0x76,0x14,0xa1, |
| 0xee,0x4a,0xea,0xe1,0x05,0xd4,0x36,0xd4,0x43,0x31,0x70,0xed,0x61,0xb7,0x71,0x98, |
| 0xfa,0x49,0x0f,0x9a,0xab,0x88,0x7a,0x68,0x31,0xce,0x27,0x1f,0x31,0x2b,0xa9,0x87, |
| 0x55,0xe8,0xa1,0x84,0x7a,0x78,0x11,0xb8,0xf6,0x50,0x0a,0x4c,0x7b,0x28,0xa7,0x1e, |
| 0xc4,0x56,0x66,0x47,0x39,0xea,0x96,0x61,0x1f,0x49,0xdd,0xd5,0xa8,0xdd,0x62,0x22, |
| 0xe7,0x5b,0x38,0xaa,0x6f,0x39,0x71,0x3c,0x0a,0xbf,0x22,0xc4,0x95,0x81,0x4f,0x85, |
| 0xbf,0xf7,0xdc,0xf9,0xd7,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a6,0x06,0x34,0x9a,0x8a,0x9a,0x53,0x49,0xa3, |
| 0x69,0xc6,0xc5,0xa9,0x46,0x29,0xa4,0x91,0xd8,0xa6,0xdb,0x91,0x84,0xb8,0x24,0xd2, |
| 0xe8,0x31,0xd2,0x68,0x7f,0x40,0xa3,0xc7,0x8d,0xb3,0xb3,0x46,0xc9,0xc6,0xe1,0xaa, |
| 0x51,0x2a,0x72,0x4e,0x27,0x8d,0x12,0xc1,0x25,0x2e,0xe0,0x93,0x42,0x1a,0xa5,0x92, |
| 0x46,0xad,0xc6,0xe5,0x15,0x5e,0x89,0xe0,0xaa,0x1a,0xbd,0x61,0x9c,0x7d,0x2f,0x78, |
| 0xaa,0x46,0xf5,0xd0,0x28,0x84,0x7e,0x73,0x02,0x1a,0xa5,0xa1,0x66,0x1a,0x69,0x94, |
| 0x6e,0x5c,0x9c,0x6a,0xb4,0x80,0x34,0x12,0x5b,0x86,0x9c,0x53,0xc4,0x65,0x93,0x46, |
| 0x73,0x49,0xa3,0xfa,0x80,0x46,0xf3,0x8c,0xb3,0xb3,0x46,0xf3,0x8d,0xc3,0x55,0xa3, |
| 0x1c,0xe4,0xcc,0x20,0x8d,0xb2,0xc0,0x25,0x2e,0xe0,0xb3,0x80,0x34,0xca,0x21,0x8d, |
| 0x3e,0x32,0x2e,0xaf,0xf0,0xca,0x02,0x57,0xd5,0x68,0xbf,0x71,0x76,0xd1,0x2a,0x84, |
| 0x7c,0x7a,0xf6,0xf6,0xe0,0xf9,0x26,0x7e,0x6d,0xd8,0x6b,0xe5,0x88,0xc9,0x31,0x91, |
| 0x33,0xff,0x36,0xce,0x7c,0x03,0x9d,0xf9,0x77,0x80,0xeb,0x99,0x3f,0x00,0x4c,0xcf, |
| 0x7c,0x13,0x9d,0x79,0xb1,0x35,0xca,0x7b,0x00,0x75,0x8f,0xd0,0xf3,0xe4,0x28,0x72, |
| 0xb7,0x50,0xee,0x63,0xc0,0x35,0xf7,0x87,0xc0,0x34,0xf7,0x71,0xca,0x2d,0xb6,0x56, |
| 0xdf,0xd7,0xe5,0x6e,0xa5,0x7d,0xf0,0x31,0xfa,0x92,0x6f,0x8a,0x2e,0xe4,0xfa,0x44, |
| 0x71,0x68,0xa1,0x71,0xc7,0xa1,0x85,0xf8,0x9c,0x40,0xcd,0x23,0xf0,0x6f,0x45,0xdd, |
| 0x0e,0xaa,0x2b,0x3e,0xed,0x76,0x74,0x20,0xbe,0x9d,0xea,0x9e,0xa4,0xba,0x79,0xf6, |
| 0xab,0x4a,0xbe,0xcf,0x4e,0x01,0x6b,0x33,0x91,0x6f,0x96,0x10,0x9e,0xd7,0x62,0x3f, |
| 0x8d,0x38,0x1d,0xfb,0x6c,0x2e,0xc1,0x3b,0x11,0x7b,0xda,0xcf,0x35,0xd8,0x5f,0xab, |
| 0x2e,0xe4,0xea,0xc4,0x77,0x53,0x34,0x7d,0xff,0x49,0x4f,0xca,0xa9,0x83,0xd6,0xb7, |
| 0x1d,0xb5,0x8f,0x23,0xbe,0x1d,0xbe,0x4d,0xf0,0x6d,0x24,0xfe,0xcd,0xff,0xc1,0xff, |
| 0x83,0x7b,0xf0,0x7f,0x13,0x3c,0x0f,0xc2,0xa7,0x99,0x78,0x1e,0x46,0xcc,0xc1,0x7b, |
| 0xf0,0xd4,0xda,0x4d,0xc4,0xf3,0x84,0x71,0x5c,0x3b,0x10,0xdf,0x48,0x7b,0xe5,0x0b, |
| 0xec,0x95,0x73,0xb4,0x57,0xbe,0x04,0xae,0x7b,0xe5,0x2b,0x60,0xba,0x57,0xba,0x69, |
| 0xcd,0xc4,0x76,0xde,0x8e,0x6e,0xd4,0x3d,0x4f,0x3d,0x7f,0x8d,0xda,0xfa,0xee,0x29, |
| 0x0c,0x3c,0x33,0x72,0x71,0x06,0x73,0xe9,0x99,0x91,0x67,0x5c,0xdc,0x14,0xc4,0xac, |
| 0xa0,0x67,0x86,0xd8,0xf2,0xed,0x58,0x82,0x38,0xb9,0xee,0x40,0xad,0xa5,0x88,0x9b, |
| 0x40,0xcf,0x8a,0x65,0xc6,0xe1,0x87,0xe8,0xd9,0xb2,0x9c,0x9e,0x2d,0x62,0x4f,0x82, |
| 0x6e,0x85,0xc8,0x99,0x4f,0xcf,0x8c,0x02,0xe4,0x94,0xef,0x6a,0xf6,0x59,0x41,0xcf, |
| 0x8c,0x42,0x7a,0x66,0x74,0x18,0x97,0x5f,0x78,0x15,0x80,0xab,0x3e,0x33,0xea,0x8d, |
| 0xb3,0xab,0x1e,0xaa,0xd1,0x37,0xd0,0x48,0xdf,0x3d,0x15,0x01,0x8d,0x8a,0x51,0xb3, |
| 0x98,0x34,0x2a,0x31,0x2e,0x4e,0x35,0x5a,0x4b,0x1a,0x89,0x6d,0x95,0x1d,0x65,0x88, |
| 0x2b,0x23,0x8d,0x5e,0x42,0x1c,0x6b,0xb4,0xda,0x38,0x9c,0x35,0x5a,0x43,0x1a,0xad, |
| 0x26,0x8d,0x2a,0x90,0x73,0x15,0x69,0x54,0x8a,0x9c,0xaa,0x91,0xfa,0xac,0x25,0x8d, |
| 0x2a,0x48,0xa3,0x93,0xc6,0xe5,0x17,0x5e,0xa5,0xe0,0xaa,0x1a,0x35,0x18,0x67,0xaf, |
| 0x0f,0xbc,0x7b,0xbe,0x85,0x46,0xfa,0xee,0xa9,0x0d,0x68,0xb4,0x01,0x35,0x37,0x90, |
| 0x46,0x1b,0x8d,0x8b,0x53,0x8d,0x6a,0x48,0x23,0xb1,0x55,0xd9,0xb1,0x19,0x71,0x9b, |
| 0x49,0xa3,0x2d,0x88,0x63,0x8d,0xaa,0x8d,0xc3,0x59,0xa3,0xad,0xa4,0x51,0x35,0x69, |
| 0x54,0x8b,0x9c,0x55,0xa4,0xd1,0x26,0xe4,0x54,0x8d,0xd4,0xa7,0x86,0x34,0xaa,0x25, |
| 0x8d,0x4e,0x19,0x97,0x5f,0x78,0x6d,0x02,0x57,0xd5,0xe8,0x80,0x71,0xf6,0x06,0x7a, |
| 0xf7,0xe8,0xd9,0xeb,0xa6,0x33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0xe8,0x1d,0xa6,0x3a,0xef,0x9a,0x08,0xee,0x05, |
| 0x62,0x7b,0xa9,0xef,0xb3,0xc6,0xd5,0x92,0xda,0x12,0xd3,0x03,0xdf,0x4b,0xf0,0xbd, |
| 0x48,0xef,0xd1,0x9f,0x90,0x4f,0x86,0xfe,0xce,0x1b,0xa2,0xf7,0xa8,0xc6,0x5c,0xa2, |
| 0xfc,0x9f,0x1a,0x57,0xa3,0x17,0xf1,0x17,0xfd,0xdf,0xc4,0xc2,0xfe,0xef,0x32,0x62, |
| 0xbb,0x63,0x0b,0xcf,0xb4,0xe3,0x5f,0xcf,0x2c,0x49,0xa7,0x98,0x16,0x00,0x00 |
| }; |
| |
| // Generated from: |
| // |
| // #version 450 core |
| // |
| // #extension GL_EXT_samplerless_texture_functions : require |
| // |
| // layout(set = 0, binding = 0)uniform texture3D src; |
| // layout(location = 0)out vec4 dst; |
| // |
| // layout(push_constant)uniform PushConstants { |
| // |
| // ivec2 srcOffset; |
| // ivec2 dstOffset; |
| // int srcMip; |
| // int srcLayer; |
| // |
| // bool flipX; |
| // bool flipY; |
| // |
| // bool premultiplyAlpha; |
| // bool unmultiplyAlpha; |
| // |
| // bool dstHasLuminance; |
| // bool dstIsAlpha; |
| // |
| // bool srcIsSRGB; |
| // bool dstIsSRGB; |
| // |
| // int dstDefaultChannelsMask; |
| // bool rotateXY; |
| // } params; |
| // |
| // float linearToSRGB(float linear) |
| // { |
| // |
| // if(linear <= 0.0031308) |
| // { |
| // return linear * 12.92; |
| // } |
| // else |
| // { |
| // return pow(linear,(1.0f / 2.4f))* 1.055f - 0.055f; |
| // } |
| // } |
| // |
| // float sRGBToLinear(float sRGB) |
| // { |
| // |
| // if(sRGB <= 0.04045) |
| // { |
| // return sRGB / 12.92; |
| // } |
| // else |
| // { |
| // return pow((sRGB + 0.055f)/ 1.055f, 2.4f); |
| // } |
| // } |
| // |
| // void main() |
| // { |
| // ivec2 dstSubImageCoords = ivec2(gl_FragCoord . xy)- params . dstOffset; |
| // |
| // ivec2 srcSubImageCoords = dstSubImageCoords; |
| // |
| // if(params . flipX) |
| // { |
| // srcSubImageCoords . x = - srcSubImageCoords . x; |
| // } |
| // if(params . flipY) |
| // { |
| // srcSubImageCoords . y = - srcSubImageCoords . y; |
| // } |
| // if(params . rotateXY) |
| // { |
| // srcSubImageCoords . xy = srcSubImageCoords . yx; |
| // } |
| // |
| // vec4 srcValue = texelFetch(src, ivec3(params . srcOffset + srcSubImageCoords, params . srcLayer), params . srcMip); |
| // |
| // if(params . srcIsSRGB) |
| // { |
| // |
| // srcValue . r = linearToSRGB(srcValue . r); |
| // srcValue . g = linearToSRGB(srcValue . g); |
| // srcValue . b = linearToSRGB(srcValue . b); |
| // } |
| // |
| // if(params . premultiplyAlpha) |
| // { |
| // srcValue . rgb *= srcValue . a; |
| // } |
| // else if(params . unmultiplyAlpha && srcValue . a > 0) |
| // { |
| // srcValue . rgb /= srcValue . a; |
| // } |
| // |
| // vec4 dstValue = vec4(srcValue); |
| // |
| // if(params . dstIsSRGB) |
| // { |
| // |
| // dstValue . r = sRGBToLinear(dstValue . r); |
| // dstValue . g = sRGBToLinear(dstValue . g); |
| // dstValue . b = sRGBToLinear(dstValue . b); |
| // } |
| // |
| // if(params . dstHasLuminance) |
| // { |
| // dstValue . rg = dstValue . ra; |
| // } |
| // else if(params . dstIsAlpha) |
| // { |
| // dstValue . r = dstValue . a; |
| // } |
| // else |
| // { |
| // int defaultChannelsMask = params . dstDefaultChannelsMask; |
| // if((defaultChannelsMask & 2)!= 0) |
| // { |
| // dstValue . g = 0; |
| // } |
| // if((defaultChannelsMask & 4)!= 0) |
| // { |
| // dstValue . b = 0; |
| // } |
| // if((defaultChannelsMask & 8)!= 0) |
| // { |
| // dstValue . a = 1; |
| // } |
| // } |
| // |
| // dst = dstValue; |
| // } |