1// GENERATED FILE - DO NOT EDIT.
2// Generated by gen_vk_internal_shaders.py.
3//
4// Copyright 2018 The ANGLE Project Authors. All rights reserved.
5// Use of this source code is governed by a BSD-style license that can be
6// found in the LICENSE file.
7//
8// shaders/gen/ImageCopy.frag.00000004.inc:
9//   Pre-generated shader for the ANGLE Vulkan back-end.
10
11#pragma once
12constexpr uint8_t kImageCopy_frag_00000004[] = {
13    0x1f,0x8b,0x08,0x00,0x00,0x00,0x00,0x00,0x02,0xff,0x85,0x98,0x8b,0x97,0x8e,0x55,
14    0x14,0xc6,0x5f,0xf3,0xcd,0x85,0x71,0x1b,0x99,0xdc,0xa2,0x35,0xe3,0x96,0x1a,0x0d,
15    0xd5,0xb8,0xfb,0x5c,0xcb,0xa5,0xdc,0x32,0x14,0x69,0x62,0x44,0x12,0x43,0x22,0x54,
16    0xee,0xc4,0x48,0xba,0xa0,0x32,0x53,0x51,0xa1,0x42,0x06,0x45,0x21,0xb7,0x6e,0xa4,
17    0x42,0x45,0xa8,0x3f,0xa0,0xff,0xa0,0xd5,0x65,0xad,0x2e,0x67,0xbf,0xf3,0xdb,0xb3,
18    0x9e,0xf5,0x2d,0xd5,0xac,0x75,0xd6,0xfb,0xed,0x67,0xef,0xf3,0x9c,0x67,0xef,0x7d,
19    0xce,0x79,0xbf,0x6f,0x12,0x69,0x6d,0xb2,0xa2,0xa8,0x56,0x94,0x1d,0xd5,0x8e,0x7e,
20    0x8a,0xaa,0xff,0x1a,0x45,0x69,0x01,0x89,0xa2,0xba,0x51,0x66,0xfc,0x1c,0x3c,0xac,
21    0x78,0x58,0xe1,0xdc,0x79,0x53,0x0a,0x8b,0xba,0x74,0x36,0x7f,0x83,0x28,0x11,0xc7,
22    0x99,0xaf,0x61,0x94,0x15,0xa5,0x87,0xa7,0x8d,0xb2,0xd2,0xe9,0xb3,0x0c,0x6f,0x1f,
23    0xc6,0x95,0x30,0x72,0x42,0x9c,0xe1,0x59,0xc6,0x11,0x3e,0xb5,0x8f,0x39,0x6d,0x4e,
24    0x14,0x0d,0x89,0x32,0xa2,0x8e,0xac,0xd7,0x86,0xa7,0x63,0xb5,0xc0,0x6a,0x0b,0x96,
25    0x06,0x96,0x23,0x58,0x02,0x2c,0x57,0xb0,0x74,0xb0,0x66,0x82,0x65,0x80,0xb5,0x14,
26    0x2c,0x13,0x2c,0x4f,0xb0,0x2c,0xb0,0xb6,0x82,0xd5,0x06,0xeb,0x20,0x58,0x1d,0xb0,
27    0x8e,0x82,0x65,0x83,0x75,0x16,0xac,0x2e,0x58,0x91,0x60,0xf5,0xc0,0xba,0x0b,0x56,
28    0x1f,0xac,0x77,0x5c,0xa7,0x44,0x4d,0xbe,0x56,0xb3,0x09,0xe1,0xd9,0x9a,0xfa,0xb8,
29    0x9d,0x2f,0xb6,0xd5,0xf9,0x7a,0xec,0xc6,0x61,0x56,0x5a,0xec,0x4f,0xc4,0xb5,0xb1,
30    0xcf,0x4d,0xc2,0xa7,0x4c,0xf2,0xcc,0x0b,0xf1,0x59,0xe4,0x99,0x19,0xc7,0xa5,0xc7,
31    0xf9,0x65,0x82,0x15,0x04,0x3b,0x13,0x3d,0x3f,0x57,0xb5,0x4b,0xe6,0x06,0x86,0x06,
32    0x82,0x37,0x0e,0x63,0xf4,0xa1,0x11,0xfd,0xdd,0xb6,0x1a,0x57,0x0d,0x2e,0x4d,0xba,
33    0xdd,0x22,0x8c,0x64,0xf6,0x9a,0xbe,0x6e,0x5b,0xbd,0x2b,0x2b,0x9a,0xf7,0xbb,0x36,
34    0xd8,0x79,0x68,0xb0,0xde,0x36,0x0d,0x76,0x3e,0x76,0x1a,0xba,0x5a,0xa3,0x21,0x1f,
35    0x7f,0x5b,0x74,0xa5,0xe3,0x6f,0xc7,0x5c,0xc3,0x7b,0x61,0xb7,0x17,0xbe,0x1b,0x88,
36    0x37,0x3e,0x5b,0xaf,0x00,0xfe,0x28,0xae,0x4f,0x4e,0x5c,0xd3,0x7c,0x86,0x6b,0x29,
37    0xf8,0x9f,0x91,0x57,0xf3,0x4c,0x8f,0x6e,0xa6,0xef,0x1d,0x59,0xdf,0xec,0x42,0xb0,
38    0x02,0xf2,0xeb,0x84,0x1e,0x8b,0xef,0x8c,0x2f,0x5f,0xfc,0x5d,0x25,0x9f,0x6e,0x35,
39    0x73,0xab,0xfd,0xf6,0xec,0x89,0x5e,0xf3,0xf7,0xa1,0x1e,0x79,0x32,0x7f,0x20,0x7b,
40    0xd9,0xe3,0x87,0xb2,0x9e,0xfb,0x47,0xd0,0x3b,0xab,0xc7,0x3d,0xcc,0xf5,0xf5,0xee,
41    0x85,0xcf,0xf0,0xe6,0x61,0xe5,0xf1,0xd2,0x0f,0xfd,0xab,0x25,0x1a,0xee,0xe3,0xf3,
42    0x78,0x72,0x36,0x7b,0x02,0x98,0xaf,0x59,0x92,0x62,0x4f,0x96,0x9e,0x3e,0x48,0x8e,
43    0x9a,0xc3,0x34,0xfa,0xe4,0x39,0x94,0x71,0x8e,0x4d,0xf3,0xa3,0xc4,0x26,0x24,0x7e,
44    0x61,0x4d,0x1d,0xd2,0xa3,0x67,0xf9,0xdc,0x56,0xf6,0xe4,0x0b,0xf1,0xea,0x4b,0x07,
45    0x7a,0xfc,0x26,0xce,0x9d,0xf3,0xef,0x40,0x8f,0xfb,0x77,0x71,0xa6,0xdd,0x3e,0x98,
46    0xd2,0xc3,0x93,0x9c,0x51,0xe7,0xff,0x52,0xf2,0x33,0xfb,0x87,0xd8,0x5a,0xd6,0xd7,
47    0xf4,0x5c,0x46,0xab,0xef,0xc9,0xcb,0xdc,0x7b,0x89,0xb8,0xd7,0x19,0xf1,0xba,0xe9,
48    0xcc,0x37,0xec,0xb7,0x80,0x64,0x10,0xdb,0x9a,0x33,0x9f,0x25,0x76,0x91,0xd8,0xd6,
49    0xaf,0x71,0x62,0x5b,0xee,0xeb,0xc5,0xb6,0x67,0x65,0x8a,0xbd,0x35,0xc5,0xde,0x2e,
50    0xb6,0xed,0xa7,0x13,0xd8,0x49,0xce,0x57,0x07,0xce,0xd0,0xc8,0x80,0xda,0xf9,0xb9,
51    0x11,0xac,0x83,0xec,0x85,0x59,0x9c,0xd5,0x9b,0xf0,0xf7,0x0f,0x19,0xd8,0xde,0xbe,
52    0x85,0xfd,0xdf,0x09,0x3e,0x8b,0xb9,0x15,0x7c,0x45,0x88,0x31,0xfb,0x36,0xe6,0x19,
53    0xde,0x27,0x54,0xa0,0x0d,0x98,0xc7,0x77,0xa1,0x06,0xe6,0x2b,0xc2,0x36,0xfe,0x6e,
54    0xdc,0x8f,0x85,0x9c,0x99,0x24,0xbd,0xec,0x01,0xbe,0x3b,0xc4,0x34,0x88,0xf3,0xaa,
55    0xc6,0xec,0xdc,0xfc,0x1a,0x38,0x92,0xe8,0xfe,0x23,0xc4,0xf7,0xe2,0x3e,0x4d,0x52,
56    0xf7,0xde,0x70,0x5b,0x1d,0xfa,0x52,0xeb,0x9e,0x70,0x5b,0xdf,0xfb,0x81,0x2f,0xc1,
57    0xee,0x0f,0xe6,0x73,0x06,0xc8,0x1c,0xd3,0x3b,0x80,0x98,0xdf,0x03,0xb7,0xaf,0x91,
58    0x14,0xfd,0xb7,0xa3,0x7f,0xa0,0xe8,0xbf,0x03,0xdc,0xf5,0x0f,0x02,0x73,0xfd,0x43,
59    0x44,0xff,0xa0,0xf8,0x7e,0x8f,0x62,0xcc,0xb8,0x07,0x8b,0x96,0x3b,0xd1,0x32,0x54,
60    0xf4,0xdf,0x05,0xee,0xfa,0x87,0x81,0xf9,0x9c,0xe1,0x32,0xc7,0xf4,0x0f,0x27,0xc6,
61    0xf4,0xfb,0x1a,0x43,0x44,0xff,0x48,0xf4,0x8f,0x10,0xfd,0xa3,0xc0,0x5d,0xff,0xdd,
62    0x60,0xae,0xbf,0x58,0xf4,0x9b,0x6f,0x74,0x18,0xc5,0x70,0x8f,0x96,0xbe,0x8f,0x41,
63    0x8b,0xed,0x3b,0xb3,0xc7,0x82,0x8d,0x91,0xfb,0xc7,0xf7,0xc4,0x58,0x34,0x3a,0x4f,
64    0x31,0x3c,0x76,0x27,0xdd,0xcf,0x7d,0xe4,0x7b,0xf2,0x01,0x34,0x97,0xc8,0x5a,0x13,
65    0xc1,0xdd,0x9e,0xc4,0xda,0xcb,0xd8,0xa3,0xa5,0xc4,0x4c,0x82,0xc7,0xee,0xac,0x29,
66    0xf0,0x4c,0x96,0xfa,0x4e,0x05,0x9f,0x18,0x34,0xdb,0x1d,0xfa,0x10,0xeb,0x97,0x72,
67    0xbf,0x4c,0x45,0xf3,0x38,0x7c,0x5e,0xc7,0x87,0xe1,0x9a,0x26,0x75,0x9c,0x0e,0xee,
68    0x75,0x7c,0x04,0xcc,0xeb,0x38,0x53,0xea,0x68,0xbe,0x19,0x61,0x2c,0x20,0xff,0x19,
69    0xd2,0xd3,0x59,0xdc,0x11,0x65,0xa2,0x73,0x36,0x78,0x92,0x77,0xc0,0x1c,0x62,0x46,
70    0x86,0x5b,0xcf,0xee,0xd7,0xc7,0xc0,0xe6,0xc8,0x19,0x4f,0x8b,0xfb,0x98,0x19,0xfb,
71    0xe7,0xc2,0xe1,0x63,0x55,0x58,0xcb,0xf0,0x79,0xcc,0x9d,0x2b,0xdc,0x8f,0xd7,0x70,
72    0xd7,0x89,0xed,0xf9,0x60,0xf3,0xb8,0xf7,0x32,0xb8,0xeb,0x13,0x52,0x9b,0xf9,0xf4,
73    0x73,0x26,0xf9,0x2c,0x90,0x5a,0x3d,0x41,0xad,0x16,0x4a,0xad,0x9e,0x04,0xf7,0x5a,
74    0x3d,0x05,0xe6,0xb5,0x5a,0x2c,0xb5,0x32,0xdf,0xa2,0x30,0x16,0xc3,0xbd,0x48,0x6a,
75    0xb5,0xe4,0x2a,0xb5,0x5a,0x0a,0xbe,0x07,0xee,0x65,0x60,0x25,0x68,0x74,0x1e,0x7b,
76    0xfe,0x12,0xfa,0x6e,0x31,0xcb,0xd1,0xb0,0x80,0xf8,0x45,0xe8,0x58,0x29,0x3a,0x96,
77    0xc7,0x77,0x60,0x14,0x63,0x36,0x7f,0x85,0xe8,0x58,0x75,0x15,0x1d,0x4f,0x83,0x7b,
78    0x5d,0x57,0xa7,0xf4,0x6c,0x0d,0xd8,0xea,0x7f,0xe9,0x59,0x39,0x1c,0x3e,0xd6,0xd0,
79    0xb3,0xb5,0xcc,0x2d,0x17,0xee,0x67,0x52,0x7a,0xb6,0x0e,0x6c,0xed,0x7f,0xf4,0x6c,
80    0x1d,0xf5,0xf0,0x7c,0x56,0xa6,0xf4,0x70,0xa6,0xf0,0x3f,0x07,0xff,0x6c,0xde,0x31,
81    0xcf,0x83,0x19,0xd7,0x7a,0x6c,0x7f,0xff,0xbc,0xc8,0x3b,0x6d,0x54,0xa8,0xad,0xd9,
82    0x1b,0x78,0x9f,0xeb,0x28,0x0f,0x8a,0xcc,0xb7,0x91,0xf8,0x0d,0xc2,0xb5,0x51,0xf6,
83    0xce,0x4b,0xec,0x9d,0x4d,0xb2,0x77,0x5e,0x06,0xf7,0xbd,0xf3,0x0a,0x98,0xef,0x9d,
84    0x0a,0xe9,0x99,0xf9,0x36,0x87,0x51,0x41,0x4e,0x9b,0xe1,0xb6,0xf7,0xe5,0xab,0xe8,
85    0xf4,0xf7,0x85,0xd5,0xe7,0x35,0x70,0xd3,0x52,0x89,0xdd,0x23,0xc4,0x9b,0xef,0x75,
86    0x7e,0x0f,0x54,0x0a,0xc7,0x16,0xe1,0xb0,0x39,0x5b,0x88,0x73,0xff,0x1b,0xf8,0x87,
87    0xca,0x1a,0x6f,0x82,0x5b,0xfc,0x56,0x6c,0x5f,0xe3,0x2d,0xd6,0xd8,0x2a,0x1c,0xdb,
88    0x84,0xc3,0xe6,0x6c,0x23,0xce,0xfd,0x6f,0xe3,0xdf,0x21,0x6b,0xbc,0x03,0x6e,0xf1,
89    0xdb,0xb1,0x7d,0x8d,0x77,0x59,0x63,0xbb,0x70,0xec,0x14,0x0e,0x9b,0xb3,0x93,0x38,
90    0xdb,0x0f,0x5e,0xbb,0x0a,0xe9,0xcb,0x6e,0xfa,0xb2,0x4b,0xfa,0xf2,0x1e,0xb8,0xf7,
91    0x65,0x0f,0x98,0xf7,0x65,0xaf,0xf4,0xc5,0x7c,0x55,0x61,0x1c,0x80,0xbb,0x4a,0xf6,
92    0xcf,0x3e,0xb4,0xf8,0xf7,0x97,0xfd,0x60,0xfb,0xe4,0x3b,0x97,0xc7,0xbe,0x5f,0x13,
93    0x5b,0x27,0xb6,0x3f,0x00,0xdb,0x2f,0xfb,0x3e,0x4d,0xf6,0xfd,0x7a,0x62,0x2c,0xaf,
94    0xbd,0xac,0x7d,0x40,0xf2,0xfa,0x90,0xbc,0x0e,0x4a,0x5e,0x1f,0x81,0x7b,0x5e,0x87,
95    0xc0,0x3c,0xaf,0x23,0x92,0x97,0xf9,0x0e,0x87,0x71,0x1c,0xee,0xc3,0x52,0xe3,0x8f,
96    0xd1,0x5a,0x26,0x7d,0x3a,0x0a,0xee,0x31,0xc7,0x52,0xf6,0xd3,0x31,0x62,0x4c,0xef,
97    0x11,0x38,0x8f,0xcb,0x3b,0xed,0x13,0xf4,0x9e,0x94,0x7b,0xe7,0x53,0x70,0x9b,0x7f,
98    0x02,0xdb,0x7d,0x9f,0xf1,0x7d,0xf1,0x74,0x98,0x6f,0xf6,0xe7,0x60,0x93,0x25,0xbf,
99    0x2f,0xc0,0x4b,0xc8,0xef,0xb4,0xe4,0x67,0xbe,0x53,0xf1,0xfc,0x6a,0x2d,0xa7,0x44,
100    0xfb,0x99,0x94,0x7d,0x7a,0x86,0xef,0xd9,0xa6,0xdd,0xe3,0x4f,0x8b,0x96,0xaf,0x52,
101    0xb4,0x7c,0x0d,0xd6,0x55,0xb4,0x7c,0x03,0xee,0x5a,0xce,0x89,0x16,0xf3,0x9d,0x0d,
102    0xe3,0x1c,0xdc,0x67,0x45,0xcb,0xf9,0x94,0xfd,0x7c,0x5e,0xb4,0x78,0xfc,0x39,0xd1,
103    0xf2,0x6d,0x8a,0x96,0xef,0xc0,0x76,0x89,0x96,0xef,0xc1,0x5d,0xcb,0x45,0xd1,0x62,
104    0xbe,0x0b,0x61,0x5c,0x84,0xfb,0x82,0x68,0xb9,0x24,0x7d,0x37,0x2d,0x97,0xf8,0xbd,
105    0x61,0x5a,0x3c,0xfe,0x62,0x4a,0x8f,0x8f,0xa4,0xec,0xd1,0xbd,0xb2,0xe7,0x7f,0x84,
106    0xcf,0xb8,0xae,0x60,0xff,0x19,0xde,0x1e,0xdd,0xc3,0xe8,0xca,0x19,0xcf,0x46,0x9b,
107    0xfd,0x26,0xea,0x16,0xe2,0xb2,0xf8,0x3d,0x64,0x5c,0x75,0x65,0xff,0xd5,0x03,0x3f,
108    0x4a,0x8e,0x0d,0xc1,0xea,0x93,0x63,0x23,0xc9,0xb1,0x21,0xff,0xa7,0x69,0x02,0x4f,
109    0x8e,0xf0,0x5c,0x03,0x4f,0x39,0xeb,0xe7,0x82,0xd9,0xff,0x16,0xfe,0x0a,0xb1,0xb9,
110    0xcc,0x69,0x22,0x73,0x9a,0x32,0x67,0x39,0x73,0x9a,0x83,0x35,0x13,0x9e,0xeb,0xc0,
111    0x5b,0xc4,0xba,0xb2,0x62,0xac,0x15,0xef,0xca,0x16,0xf8,0x5b,0xb2,0x46,0x2b,0xd6,
112    0x30,0xcd,0x7f,0x53,0x8f,0x7f,0x00,0x7d,0xda,0xc9,0xab,0x08,0x13,0x00,0x00
113};
114
115// Generated from:
116//
117// #version 450 core
118//
119// #extension GL_EXT_samplerless_texture_functions : require
120//
121// layout(set = 0, binding = 0)uniform itexture2D src;
122// layout(location = 0)out vec4 dest;
123//
124// layout(push_constant)uniform PushConstants {
125//
126//     ivec2 srcOffset;
127//     ivec2 destOffset;
128//     int srcMip;
129//     int srcLayer;
130//
131//     bool flipX;
132//     bool flipY;
133//
134//     bool premultiplyAlpha;
135//     bool unmultiplyAlpha;
136//
137//     bool destHasLuminance;
138//     bool destIsAlpha;
139//
140//     bool srcIsSRGB;
141//     bool destIsSRGB;
142//
143//     int destDefaultChannelsMask;
144//     bool rotateXY;
145// } params;
146//
147// float sRGBToLinear(float sRGB)
148// {
149//
150//     if(sRGB <= 0.04045)
151//     {
152//         return sRGB / 12.92;
153//     }
154//     else
155//     {
156//         return pow((sRGB + 0.055f)/ 1.055f, 2.4f);
157//     }
158// }
159//
160// void main()
161// {
162//     ivec2 destSubImageCoords = ivec2(gl_FragCoord . xy)- params . destOffset;
163//
164//     ivec2 srcSubImageCoords = destSubImageCoords;
165//
166//     if(params . flipX)
167//     {
168//         srcSubImageCoords . x = - srcSubImageCoords . x;
169//     }
170//     if(params . flipY)
171//     {
172//         srcSubImageCoords . y = - srcSubImageCoords . y;
173//     }
174//     if(params . rotateXY)
175//     {
176//         srcSubImageCoords . xy = srcSubImageCoords . yx;
177//     }
178//
179//           ivec4 srcValue = texelFetch(src, params . srcOffset + srcSubImageCoords, params . srcMip);
180//
181//     if(params . premultiplyAlpha)
182//     {
183//         srcValue . rgb *= srcValue . a;
184//     }
185//     else if(params . unmultiplyAlpha && srcValue . a > 0)
186//     {
187//         srcValue . rgb /= srcValue . a;
188//     }
189//
190//            vec4 destValue = vec4(srcValue);
191//
192//     destValue /= 255.0;
193//
194//     if(params . destIsSRGB)
195//     {
196//
197//         destValue . r = sRGBToLinear(destValue . r);
198//         destValue . g = sRGBToLinear(destValue . g);
199//         destValue . b = sRGBToLinear(destValue . b);
200//     }
201//
202//     if(params . destHasLuminance)
203//     {
204//         destValue . rg = destValue . ra;
205//     }
206//     else if(params . destIsAlpha)
207//     {
208//         destValue . r = destValue . a;
209//     }
210//     else
211//     {
212//         int defaultChannelsMask = params . destDefaultChannelsMask;
213//         if((defaultChannelsMask & 2)!= 0)
214//         {
215//             destValue . g = 0;
216//         }
217//         if((defaultChannelsMask & 4)!= 0)
218//         {
219//             destValue . b = 0;
220//         }
221//         if((defaultChannelsMask & 8)!= 0)
222//         {
223//             destValue . a = 1;
224//         }
225//     }
226//
227//     dest = destValue;
228// }
229