@@ -103,11 +103,6 @@ typedef struct GPU_TextureData
103
103
#endif
104
104
} GPU_TextureData ;
105
105
106
- enum
107
- {
108
- BLEND_INVALID = 0x7fffffff ,
109
- };
110
-
111
106
static SDL_GpuBlendFactor GetBlendFunc (SDL_BlendFactor factor )
112
107
{
113
108
switch (factor ) {
@@ -132,7 +127,7 @@ static SDL_GpuBlendFactor GetBlendFunc(SDL_BlendFactor factor)
132
127
case SDL_BLENDFACTOR_ONE_MINUS_DST_ALPHA :
133
128
return SDL_GPU_BLENDFACTOR_ONE_MINUS_DST_ALPHA ;
134
129
default :
135
- return BLEND_INVALID ;
130
+ return SDL_GPU_BLENDFACTOR_INVALID ;
136
131
}
137
132
}
138
133
@@ -150,7 +145,7 @@ static SDL_GpuBlendOp GetBlendEquation(SDL_BlendOperation operation)
150
145
case SDL_BLENDOPERATION_MAXIMUM :
151
146
return SDL_GPU_BLENDOP_MAX ;
152
147
default :
153
- return BLEND_INVALID ;
148
+ return SDL_GPU_BLENDOP_INVALID ;
154
149
}
155
150
}
156
151
@@ -163,12 +158,12 @@ static SDL_bool GPU_SupportsBlendMode(SDL_Renderer *renderer, SDL_BlendMode blen
163
158
SDL_BlendFactor dstAlphaFactor = SDL_GetBlendModeDstAlphaFactor (blendMode );
164
159
SDL_BlendOperation alphaOperation = SDL_GetBlendModeAlphaOperation (blendMode );
165
160
166
- if (GetBlendFunc (srcColorFactor ) == BLEND_INVALID ||
167
- GetBlendFunc (srcAlphaFactor ) == BLEND_INVALID ||
168
- GetBlendEquation (colorOperation ) == BLEND_INVALID ||
169
- GetBlendFunc (dstColorFactor ) == BLEND_INVALID ||
170
- GetBlendFunc (dstAlphaFactor ) == BLEND_INVALID ||
171
- GetBlendEquation (alphaOperation ) == BLEND_INVALID ) {
161
+ if (GetBlendFunc (srcColorFactor ) == SDL_GPU_BLENDFACTOR_INVALID ||
162
+ GetBlendFunc (srcAlphaFactor ) == SDL_GPU_BLENDFACTOR_INVALID ||
163
+ GetBlendEquation (colorOperation ) == SDL_GPU_BLENDOP_INVALID ||
164
+ GetBlendFunc (dstColorFactor ) == SDL_GPU_BLENDFACTOR_INVALID ||
165
+ GetBlendFunc (dstAlphaFactor ) == SDL_GPU_BLENDFACTOR_INVALID ||
166
+ GetBlendEquation (alphaOperation ) == SDL_GPU_BLENDOP_INVALID ) {
172
167
return SDL_FALSE ;
173
168
}
174
169
0 commit comments