Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
angle
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
angle
Commits
f69ac0a5
Commit
f69ac0a5
authored
Jul 12, 2017
by
Commit Bot
Committed by
Gerrit Code Review
Jul 12, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge "Add support for new internalformats in copyTextureCHROMIUM"
parents
2c7c4268
340b7b8b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
401 additions
and
1 deletion
+401
-1
Blit11.cpp
src/libANGLE/renderer/d3d/d3d11/Blit11.cpp
+33
-1
Blit11.h
src/libANGLE/renderer/d3d/d3d11/Blit11.h
+6
-0
MultiplyAlpha.hlsl
src/libANGLE/renderer/d3d/d3d11/shaders/MultiplyAlpha.hlsl
+37
-0
multiplyalpha_ftof_pm_luma_ps.h
...3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_ps.h
+77
-0
multiplyalpha_ftof_pm_lumaalpha_ps.h
...d11/shaders/compiled/multiplyalpha_ftof_pm_lumaalpha_ps.h
+77
-0
multiplyalpha_ftof_um_luma_ps.h
...3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_ps.h
+82
-0
multiplyalpha_ftof_um_lumaalpha_ps.h
...d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_ps.h
+82
-0
generate_shaders.bat
src/libANGLE/renderer/d3d/d3d11/shaders/generate_shaders.bat
+4
-0
validationES2.cpp
src/libANGLE/validationES2.cpp
+3
-0
CopyTextureTest.cpp
src/tests/gl_tests/CopyTextureTest.cpp
+0
-0
No files found.
src/libANGLE/renderer/d3d/d3d11/Blit11.cpp
View file @
f69ac0a5
...
@@ -43,8 +43,12 @@ namespace
...
@@ -43,8 +43,12 @@ namespace
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2di11ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2di11ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2dui11ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2dui11ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_lumaalpha_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgb_ps.h"
#include "libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgb_ps.h"
...
@@ -839,7 +843,17 @@ Blit11::BlitShaderType Blit11::GetBlitShaderType(GLenum destinationFormat,
...
@@ -839,7 +843,17 @@ Blit11::BlitShaderType Blit11::GetBlitShaderType(GLenum destinationFormat,
return
unpackPremultiplyAlpha
?
BLITSHADER_2D_RGBF_TOUI_PREMULTIPLY
return
unpackPremultiplyAlpha
?
BLITSHADER_2D_RGBF_TOUI_PREMULTIPLY
:
BLITSHADER_2D_RGBF_TOUI_UNMULTIPLY
;
:
BLITSHADER_2D_RGBF_TOUI_UNMULTIPLY
;
}
}
case
GL_LUMINANCE
:
ASSERT
(
!
floatToIntBlit
);
return
unpackPremultiplyAlpha
?
BLITSHADER_2D_LUMAF_PREMULTIPLY
:
BLITSHADER_2D_LUMAF_UNMULTIPLY
;
case
GL_LUMINANCE_ALPHA
:
ASSERT
(
!
floatToIntBlit
);
return
unpackPremultiplyAlpha
?
BLITSHADER_2D_LUMAALPHAF_PREMULTIPLY
:
BLITSHADER_2D_LUMAALPHAF_UNMULTIPLY
;
case
GL_ALPHA
:
ASSERT
(
!
floatToIntBlit
);
return
BLITSHADER_2D_ALPHA
;
default
:
default
:
UNREACHABLE
();
UNREACHABLE
();
return
BLITSHADER_INVALID
;
return
BLITSHADER_INVALID
;
...
@@ -1860,6 +1874,24 @@ gl::Error Blit11::getBlitShader(GLenum destFormat,
...
@@ -1860,6 +1874,24 @@ gl::Error Blit11::getBlitShader(GLenum destFormat,
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoU_UM_RGB
),
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoU_UM_RGB
),
"Blit11 2D RGB to uint unmultiply pixel shader"
));
"Blit11 2D RGB to uint unmultiply pixel shader"
));
break
;
break
;
case
BLITSHADER_2D_LUMAF_PREMULTIPLY
:
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoF_PM_LUMA
),
"Blit11 2D LUMA premultiply pixel shader"
));
break
;
case
BLITSHADER_2D_LUMAF_UNMULTIPLY
:
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoF_UM_LUMA
),
"Blit11 2D LUMA unmultiply pixel shader"
));
break
;
case
BLITSHADER_2D_LUMAALPHAF_PREMULTIPLY
:
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoF_PM_LUMAALPHA
),
"Blit11 2D LUMAALPHA premultiply pixel shader"
));
break
;
case
BLITSHADER_2D_LUMAALPHAF_UNMULTIPLY
:
ANGLE_TRY
(
addBlitShaderToMap
(
blitShaderType
,
SHADER_2D
,
ShaderData
(
g_PS_FtoF_UM_LUMAALPHA
),
"Blit11 2D LUMAALPHA unmultiply pixel shader"
));
break
;
default
:
default
:
UNREACHABLE
();
UNREACHABLE
();
...
...
src/libANGLE/renderer/d3d/d3d11/Blit11.h
View file @
f69ac0a5
...
@@ -152,6 +152,12 @@ class Blit11 : angle::NonCopyable
...
@@ -152,6 +152,12 @@ class Blit11 : angle::NonCopyable
BLITSHADER_2D_RGBF_TOUI
,
BLITSHADER_2D_RGBF_TOUI
,
BLITSHADER_2D_RGBF_TOUI_PREMULTIPLY
,
BLITSHADER_2D_RGBF_TOUI_PREMULTIPLY
,
BLITSHADER_2D_RGBF_TOUI_UNMULTIPLY
,
BLITSHADER_2D_RGBF_TOUI_UNMULTIPLY
,
BLITSHADER_2D_LUMAF_PREMULTIPLY
,
BLITSHADER_2D_LUMAF_UNMULTIPLY
,
BLITSHADER_2D_LUMAALPHAF_PREMULTIPLY
,
BLITSHADER_2D_LUMAALPHAF_UNMULTIPLY
};
};
enum
SwizzleShaderType
enum
SwizzleShaderType
...
...
src/libANGLE/renderer/d3d/d3d11/shaders/MultiplyAlpha.hlsl
View file @
f69ac0a5
...
@@ -7,6 +7,43 @@ SamplerState Sampler : register(s0);
...
@@ -7,6 +7,43 @@ SamplerState Sampler : register(s0);
// PM: premultiply, UM: unmulitply, PT: passthrough
// PM: premultiply, UM: unmulitply, PT: passthrough
// F: float, U: uint
// F: float, U: uint
// Float to float LUMA
float4 PS_FtoF_PM_LUMA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
{
float4 color = TextureF.Sample(Sampler, inTexCoord).rgba;
color.rgb = color.r * color.a;
color.a = 1.0f;
return color;
}
float4 PS_FtoF_UM_LUMA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
{
float4 color = TextureF.Sample(Sampler, inTexCoord).rgba;
if (color.a > 0.0f)
{
color.rgb = color.r / color.a;
}
color.a = 1.0f;
return color;
}
// Float to float LUMAALPHA
float4 PS_FtoF_PM_LUMAALPHA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
{
float4 color = TextureF.Sample(Sampler, inTexCoord).rgba;
color.rgb = color.r * color.a;
return color;
}
float4 PS_FtoF_UM_LUMAALPHA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
{
float4 color = TextureF.Sample(Sampler, inTexCoord).rgba;
if (color.a > 0.0f)
{
color.rgb = color.r / color.a;
}
return color;
}
// Float to float RGBA
// Float to float RGBA
float4 PS_FtoF_PM_RGBA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
float4 PS_FtoF_PM_RGBA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
{
{
...
...
src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_ps.h
0 → 100644
View file @
f69ac0a5
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//
// Resource Bindings:
//
// Name Type Format Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// Sampler sampler NA NA 0 1
// TextureF texture float4 2d 0 1
//
//
//
// Input signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION 0 xyzw 0 POS float
// TEXCOORD 0 xy 1 NONE float xy
//
//
// Output signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_TARGET 0 xyzw 0 TARGET float xyzw
//
ps_4_0
dcl_sampler s0, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_input_ps linear v1.xy
dcl_output o0.xyzw
dcl_temps 1
sample r0.xyzw, v1.xyxx, t0.xyzw, s0
mul o0.xyz, r0.wwww, r0.xxxx
mov o0.w, l(1.000000)
ret
// Approximately 4 instruction slots used
#endif
const
BYTE
g_PS_FtoF_PM_LUMA
[]
=
{
68
,
88
,
66
,
67
,
61
,
193
,
4
,
85
,
218
,
250
,
183
,
199
,
231
,
187
,
141
,
93
,
80
,
186
,
200
,
74
,
1
,
0
,
0
,
0
,
136
,
2
,
0
,
0
,
5
,
0
,
0
,
0
,
52
,
0
,
0
,
0
,
220
,
0
,
0
,
0
,
52
,
1
,
0
,
0
,
104
,
1
,
0
,
0
,
12
,
2
,
0
,
0
,
82
,
68
,
69
,
70
,
160
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
28
,
0
,
0
,
0
,
0
,
4
,
255
,
255
,
0
,
1
,
0
,
0
,
109
,
0
,
0
,
0
,
92
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
100
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
5
,
0
,
0
,
0
,
4
,
0
,
0
,
0
,
255
,
255
,
255
,
255
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
13
,
0
,
0
,
0
,
83
,
97
,
109
,
112
,
108
,
101
,
114
,
0
,
84
,
101
,
120
,
116
,
117
,
114
,
101
,
70
,
0
,
77
,
105
,
99
,
114
,
111
,
115
,
111
,
102
,
116
,
32
,
40
,
82
,
41
,
32
,
72
,
76
,
83
,
76
,
32
,
83
,
104
,
97
,
100
,
101
,
114
,
32
,
67
,
111
,
109
,
112
,
105
,
108
,
101
,
114
,
32
,
54
,
46
,
51
,
46
,
57
,
54
,
48
,
48
,
46
,
49
,
54
,
51
,
56
,
52
,
0
,
171
,
73
,
83
,
71
,
78
,
80
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
56
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
15
,
0
,
0
,
0
,
68
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
3
,
0
,
0
,
83
,
86
,
95
,
80
,
79
,
83
,
73
,
84
,
73
,
79
,
78
,
0
,
84
,
69
,
88
,
67
,
79
,
79
,
82
,
68
,
0
,
171
,
171
,
171
,
79
,
83
,
71
,
78
,
44
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
32
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
15
,
0
,
0
,
0
,
83
,
86
,
95
,
84
,
65
,
82
,
71
,
69
,
84
,
0
,
171
,
171
,
83
,
72
,
68
,
82
,
156
,
0
,
0
,
0
,
64
,
0
,
0
,
0
,
39
,
0
,
0
,
0
,
90
,
0
,
0
,
3
,
0
,
96
,
16
,
0
,
0
,
0
,
0
,
0
,
88
,
24
,
0
,
4
,
0
,
112
,
16
,
0
,
0
,
0
,
0
,
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/multiplyalpha_ftof_pm_lumaalpha_ps.h
0 → 100644
View file @
f69ac0a5
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//
// Resource Bindings:
//
// Name Type Format Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// Sampler sampler NA NA 0 1
// TextureF texture float4 2d 0 1
//
//
//
// Input signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION 0 xyzw 0 POS float
// TEXCOORD 0 xy 1 NONE float xy
//
//
// Output signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_TARGET 0 xyzw 0 TARGET float xyzw
//
ps_4_0
dcl_sampler s0, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_input_ps linear v1.xy
dcl_output o0.xyzw
dcl_temps 1
sample r0.xyzw, v1.xyxx, t0.xyzw, s0
mul o0.xyz, r0.wwww, r0.xxxx
mov o0.w, r0.w
ret
// Approximately 4 instruction slots used
#endif
const
BYTE
g_PS_FtoF_PM_LUMAALPHA
[]
=
{
68
,
88
,
66
,
67
,
16
,
240
,
62
,
171
,
253
,
134
,
187
,
96
,
66
,
174
,
101
,
13
,
101
,
43
,
164
,
23
,
1
,
0
,
0
,
0
,
136
,
2
,
0
,
0
,
5
,
0
,
0
,
0
,
52
,
0
,
0
,
0
,
220
,
0
,
0
,
0
,
52
,
1
,
0
,
0
,
104
,
1
,
0
,
0
,
12
,
2
,
0
,
0
,
82
,
68
,
69
,
70
,
160
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
28
,
0
,
0
,
0
,
0
,
4
,
255
,
255
,
0
,
1
,
0
,
0
,
109
,
0
,
0
,
0
,
92
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
100
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
5
,
0
,
0
,
0
,
4
,
0
,
0
,
0
,
255
,
255
,
255
,
255
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
13
,
0
,
0
,
0
,
83
,
97
,
109
,
112
,
108
,
101
,
114
,
0
,
84
,
101
,
120
,
116
,
117
,
114
,
101
,
70
,
0
,
77
,
105
,
99
,
114
,
111
,
115
,
111
,
102
,
116
,
32
,
40
,
82
,
41
,
32
,
72
,
76
,
83
,
76
,
32
,
83
,
104
,
97
,
100
,
101
,
114
,
32
,
67
,
111
,
109
,
112
,
105
,
108
,
101
,
114
,
32
,
54
,
46
,
51
,
46
,
57
,
54
,
48
,
48
,
46
,
49
,
54
,
51
,
56
,
52
,
0
,
171
,
73
,
83
,
71
,
78
,
80
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
56
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
15
,
0
,
0
,
0
,
68
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
3
,
0
,
0
,
83
,
86
,
95
,
80
,
79
,
83
,
73
,
84
,
73
,
79
,
78
,
0
,
84
,
69
,
88
,
67
,
79
,
79
,
82
,
68
,
0
,
171
,
171
,
171
,
79
,
83
,
71
,
78
,
44
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
32
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
15
,
0
,
0
,
0
,
83
,
86
,
95
,
84
,
65
,
82
,
71
,
69
,
84
,
0
,
171
,
171
,
83
,
72
,
68
,
82
,
156
,
0
,
0
,
0
,
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0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
};
src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_ps.h
0 → 100644
View file @
f69ac0a5
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//
// Resource Bindings:
//
// Name Type Format Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// Sampler sampler NA NA 0 1
// TextureF texture float4 2d 0 1
//
//
//
// Input signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION 0 xyzw 0 POS float
// TEXCOORD 0 xy 1 NONE float xy
//
//
// Output signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_TARGET 0 xyzw 0 TARGET float xyzw
//
ps_4_0
dcl_sampler s0, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_input_ps linear v1.xy
dcl_output o0.xyzw
dcl_temps 2
sample r0.xyzw, v1.xyxx, t0.xyzw, s0
lt r1.x, l(0.000000), r0.w
div r0.w, r0.x, r0.w
movc o0.xyz, r1.xxxx, r0.wwww, r0.xyzx
mov o0.w, l(1.000000)
ret
// Approximately 6 instruction slots used
#endif
const
BYTE
g_PS_FtoF_UM_LUMA
[]
=
{
68
,
88
,
66
,
67
,
64
,
125
,
110
,
227
,
139
,
187
,
78
,
166
,
27
,
154
,
215
,
226
,
168
,
30
,
14
,
98
,
1
,
0
,
0
,
0
,
200
,
2
,
0
,
0
,
5
,
0
,
0
,
0
,
52
,
0
,
0
,
0
,
220
,
0
,
0
,
0
,
52
,
1
,
0
,
0
,
104
,
1
,
0
,
0
,
76
,
2
,
0
,
0
,
82
,
68
,
69
,
70
,
160
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
28
,
0
,
0
,
0
,
0
,
4
,
255
,
255
,
0
,
1
,
0
,
0
,
109
,
0
,
0
,
0
,
92
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
100
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
5
,
0
,
0
,
0
,
4
,
0
,
0
,
0
,
255
,
255
,
255
,
255
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
13
,
0
,
0
,
0
,
83
,
97
,
109
,
112
,
108
,
101
,
114
,
0
,
84
,
101
,
120
,
116
,
117
,
114
,
101
,
70
,
0
,
77
,
105
,
99
,
114
,
111
,
115
,
111
,
102
,
116
,
32
,
40
,
82
,
41
,
32
,
72
,
76
,
83
,
76
,
32
,
83
,
104
,
97
,
100
,
101
,
114
,
32
,
67
,
111
,
109
,
112
,
105
,
108
,
101
,
114
,
32
,
54
,
46
,
51
,
46
,
57
,
54
,
48
,
48
,
46
,
49
,
54
,
51
,
56
,
52
,
0
,
171
,
73
,
83
,
71
,
78
,
80
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
56
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
15
,
0
,
0
,
0
,
68
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
3
,
3
,
0
,
0
,
83
,
86
,
95
,
80
,
79
,
83
,
73
,
84
,
73
,
79
,
78
,
0
,
84
,
69
,
88
,
67
,
79
,
79
,
82
,
68
,
0
,
171
,
171
,
171
,
79
,
83
,
71
,
78
,
44
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
8
,
0
,
0
,
0
,
32
,
0
,
0
,
0
,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
62
,
0
,
0
,
1
,
83
,
84
,
65
,
84
,
116
,
0
,
0
,
0
,
6
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
};
src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_ps.h
0 → 100644
View file @
f69ac0a5
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//
// Resource Bindings:
//
// Name Type Format Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// Sampler sampler NA NA 0 1
// TextureF texture float4 2d 0 1
//
//
//
// Input signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION 0 xyzw 0 POS float
// TEXCOORD 0 xy 1 NONE float xy
//
//
// Output signature:
//
// Name Index Mask Register SysValue Format Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_TARGET 0 xyzw 0 TARGET float xyzw
//
ps_4_0
dcl_sampler s0, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_input_ps linear v1.xy
dcl_output o0.xyzw
dcl_temps 2
sample r0.xyzw, v1.xyxx, t0.xyzw, s0
lt r1.x, l(0.000000), r0.w
div r1.y, r0.x, r0.w
movc o0.xyz, r1.xxxx, r1.yyyy, r0.xyzx
mov o0.w, r0.w
ret
// Approximately 6 instruction slots used
#endif
const
BYTE
g_PS_FtoF_UM_LUMAALPHA
[]
=
{
68
,
88
,
66
,
67
,
108
,
4
,
157
,
10
,
254
,
47
,
42
,
8
,
219
,
0
,
94
,
160
,
25
,
199
,
73
,
60
,
1
,
0
,
0
,
0
,
200
,
2
,
0
,
0
,
5
,
0
,
0
,
0
,
52
,
0
,
0
,
0
,
220
,
0
,
0
,
0
,
52
,
1
,
0
,
0
,
104
,
1
,
0
,
0
,
76
,
2
,
0
,
0
,
82
,
68
,
69
,
70
,
160
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
28
,
0
,
0
,
0
,
0
,
4
,
255
,
255
,
0
,
1
,
0
,
0
,
109
,
0
,
0
,
0
,
92
,
0
,
0
,
0
,
3
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
100
,
0
,
0
,
0
,
2
,
0
,
0
,
0
,
5
,
0
,
0
,
0
,
4
,
0
,
0
,
0
,
255
,
255
,
255
,
255
,
0
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
13
,
0
,
0
,
0
,
83
,
97
,
109
,
112
,
108
,
101
,
114
,
0
,
84
,
101
,
120
,
116
,
117
,
114
,
101
,
70
,
0
,
77
,
105
,
99
,
114
,
111
,
115
,
111
,
102
,
116
,
32
,
40
,
82
,
41
,
32
,
72
,
76
,
83
,
76
,
32
,
83
,
104
,
97
,
100
,
101
,
114
,
32
,
67
,
111
,
109
,
112
,
105
,
108
,
101
,
114
,
32
,
54
,
46
,
51
,
46
,
57
,
54
,
48
,
48
,
46
,
49
,
54
,
51
,
56
,
52
,
0
,
171
,
73
,
83
,
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_FtoU_UM_RGBA ps_4_0 compiled\multiplyalph
...
@@ -40,6 +40,10 @@ call:BuildShader MultiplyAlpha.hlsl PS_FtoU_UM_RGBA ps_4_0 compiled\multiplyalph
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_PT_RGB ps_4_0 compiled\multiplyalpha_ftou_pt_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_PT_RGB ps_4_0 compiled\multiplyalpha_ftou_pt_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_PM_RGB ps_4_0 compiled\multiplyalpha_ftou_pm_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_PM_RGB ps_4_0 compiled\multiplyalpha_ftou_pm_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_UM_RGB ps_4_0 compiled\multiplyalpha_ftou_um_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoU_UM_RGB ps_4_0 compiled\multiplyalpha_ftou_um_rgb_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoF_PM_LUMA ps_4_0 compiled\multiplyalpha_ftof_pm_luma_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoF_UM_LUMA ps_4_0 compiled\multiplyalpha_ftof_um_luma_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoF_PM_LUMAALPHA ps_4_0 compiled\multiplyalpha_ftof_pm_lumaalpha_ps.h %debug%
call:BuildShader MultiplyAlpha.hlsl PS_FtoF_UM_LUMAALPHA ps_4_0 compiled\multiplyalpha_ftof_um_lumaalpha_ps.h %debug%
call:BuildShader Clear11.hlsl VS_Clear_FL9 vs_4_0_level_9_3 compiled\clear11_fl9vs.h %debug%
call:BuildShader Clear11.hlsl VS_Clear_FL9 vs_4_0_level_9_3 compiled\clear11_fl9vs.h %debug%
call:BuildShader Clear11.hlsl PS_ClearFloat_FL9 ps_4_0_level_9_3 compiled\clearfloat11_fl9ps.h %debug%
call:BuildShader Clear11.hlsl PS_ClearFloat_FL9 ps_4_0_level_9_3 compiled\clearfloat11_fl9ps.h %debug%
...
...
src/libANGLE/validationES2.cpp
View file @
f69ac0a5
...
@@ -268,6 +268,9 @@ bool IsValidCopyTextureDestinationInternalFormatEnum(GLint internalFormat)
...
@@ -268,6 +268,9 @@ bool IsValidCopyTextureDestinationInternalFormatEnum(GLint internalFormat)
case
GL_RGBA16F
:
case
GL_RGBA16F
:
case
GL_RGBA32F
:
case
GL_RGBA32F
:
case
GL_R11F_G11F_B10F
:
case
GL_R11F_G11F_B10F
:
case
GL_LUMINANCE
:
case
GL_LUMINANCE_ALPHA
:
case
GL_ALPHA
:
return
true
;
return
true
;
default
:
default
:
...
...
src/tests/gl_tests/CopyTextureTest.cpp
View file @
f69ac0a5
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment