wined3d: Get rid of the WINED3DSAMPLER_TEXTURE_TYPE typedef.
This commit is contained in:
parent
81ae0cea7c
commit
323a95418e
|
@ -2898,7 +2898,7 @@ static void device_map_fixed_function_samplers(struct wined3d_device *device, co
|
|||
|
||||
static void device_map_psamplers(struct wined3d_device *device, const struct wined3d_gl_info *gl_info)
|
||||
{
|
||||
const WINED3DSAMPLER_TEXTURE_TYPE *sampler_type =
|
||||
const enum wined3d_sampler_texture_type *sampler_type =
|
||||
device->stateBlock->state.pixel_shader->reg_maps.sampler_type;
|
||||
unsigned int i;
|
||||
|
||||
|
@ -2915,8 +2915,8 @@ static void device_map_psamplers(struct wined3d_device *device, const struct win
|
|||
}
|
||||
|
||||
static BOOL device_unit_free_for_vs(const struct wined3d_device *device,
|
||||
const WINED3DSAMPLER_TEXTURE_TYPE *pshader_sampler_tokens,
|
||||
const WINED3DSAMPLER_TEXTURE_TYPE *vshader_sampler_tokens, DWORD unit)
|
||||
const enum wined3d_sampler_texture_type *pshader_sampler_tokens,
|
||||
const enum wined3d_sampler_texture_type *vshader_sampler_tokens, DWORD unit)
|
||||
{
|
||||
DWORD current_mapping = device->rev_tex_unit_map[unit];
|
||||
|
||||
|
@ -2941,9 +2941,9 @@ static BOOL device_unit_free_for_vs(const struct wined3d_device *device,
|
|||
|
||||
static void device_map_vsamplers(struct wined3d_device *device, BOOL ps, const struct wined3d_gl_info *gl_info)
|
||||
{
|
||||
const WINED3DSAMPLER_TEXTURE_TYPE *vshader_sampler_type =
|
||||
const enum wined3d_sampler_texture_type *vshader_sampler_type =
|
||||
device->stateBlock->state.vertex_shader->reg_maps.sampler_type;
|
||||
const WINED3DSAMPLER_TEXTURE_TYPE *pshader_sampler_type = NULL;
|
||||
const enum wined3d_sampler_texture_type *pshader_sampler_type = NULL;
|
||||
int start = min(MAX_COMBINED_SAMPLERS, gl_info->limits.combined_samplers) - 1;
|
||||
int i;
|
||||
|
||||
|
|
|
@ -1652,7 +1652,7 @@ static inline const char *shader_get_comp_op(DWORD op)
|
|||
static void shader_glsl_get_sample_function(const struct wined3d_shader_context *ctx,
|
||||
DWORD sampler_idx, DWORD flags, struct glsl_sample_function *sample_function)
|
||||
{
|
||||
WINED3DSAMPLER_TEXTURE_TYPE sampler_type = ctx->reg_maps->sampler_type[sampler_idx];
|
||||
enum wined3d_sampler_texture_type sampler_type = ctx->reg_maps->sampler_type[sampler_idx];
|
||||
const struct wined3d_gl_info *gl_info = ctx->gl_info;
|
||||
BOOL shadow = shader_is_pshader_version(ctx->reg_maps->shader_version.type)
|
||||
&& (((const struct shader_glsl_ctx_priv *)ctx->backend_data)->cur_ps_args->shadow & (1 << sampler_idx));
|
||||
|
@ -3036,7 +3036,7 @@ static void shader_glsl_tex(const struct wined3d_shader_instruction *ins)
|
|||
const struct shader_glsl_ctx_priv *priv = ins->ctx->backend_data;
|
||||
DWORD flags = (priv->cur_ps_args->tex_transform >> sampler_idx * WINED3D_PSARGS_TEXTRANSFORM_SHIFT)
|
||||
& WINED3D_PSARGS_TEXTRANSFORM_MASK;
|
||||
WINED3DSAMPLER_TEXTURE_TYPE sampler_type = ins->ctx->reg_maps->sampler_type[sampler_idx];
|
||||
enum wined3d_sampler_texture_type sampler_type = ins->ctx->reg_maps->sampler_type[sampler_idx];
|
||||
|
||||
/* Projected cube textures don't make a lot of sense, the resulting coordinates stay the same. */
|
||||
if (flags & WINED3D_PSARGS_PROJECTED && sampler_type != WINED3DSTT_CUBE) {
|
||||
|
|
|
@ -2157,7 +2157,7 @@ static HRESULT pixelshader_init(struct wined3d_shader *shader, struct wined3d_de
|
|||
|
||||
void pixelshader_update_samplers(struct wined3d_shader_reg_maps *reg_maps, struct wined3d_texture * const *textures)
|
||||
{
|
||||
WINED3DSAMPLER_TEXTURE_TYPE *sampler_type = reg_maps->sampler_type;
|
||||
enum wined3d_sampler_texture_type *sampler_type = reg_maps->sampler_type;
|
||||
unsigned int i;
|
||||
|
||||
if (reg_maps->shader_version.major != 1) return;
|
||||
|
|
|
@ -277,14 +277,14 @@ struct wined3d_settings
|
|||
|
||||
extern struct wined3d_settings wined3d_settings DECLSPEC_HIDDEN;
|
||||
|
||||
typedef enum _WINED3DSAMPLER_TEXTURE_TYPE
|
||||
enum wined3d_sampler_texture_type
|
||||
{
|
||||
WINED3DSTT_UNKNOWN = 0,
|
||||
WINED3DSTT_1D = 1,
|
||||
WINED3DSTT_2D = 2,
|
||||
WINED3DSTT_CUBE = 3,
|
||||
WINED3DSTT_VOLUME = 4,
|
||||
} WINED3DSAMPLER_TEXTURE_TYPE;
|
||||
};
|
||||
|
||||
typedef enum _WINED3DSHADER_PARAM_REGISTER_TYPE
|
||||
{
|
||||
|
@ -544,7 +544,7 @@ struct wined3d_shader_reg_maps
|
|||
WORD local_int_consts; /* MAX_CONST_I, 16 */
|
||||
WORD local_bool_consts; /* MAX_CONST_B, 16 */
|
||||
|
||||
WINED3DSAMPLER_TEXTURE_TYPE sampler_type[max(MAX_FRAGMENT_SAMPLERS, MAX_VERTEX_SAMPLERS)];
|
||||
enum wined3d_sampler_texture_type sampler_type[max(MAX_FRAGMENT_SAMPLERS, MAX_VERTEX_SAMPLERS)];
|
||||
BYTE bumpmat; /* MAX_TEXTURES, 8 */
|
||||
BYTE luminanceparams; /* MAX_TEXTURES, 8 */
|
||||
|
||||
|
@ -637,7 +637,7 @@ struct wined3d_shader_semantic
|
|||
{
|
||||
WINED3DDECLUSAGE usage;
|
||||
UINT usage_idx;
|
||||
WINED3DSAMPLER_TEXTURE_TYPE sampler_type;
|
||||
enum wined3d_sampler_texture_type sampler_type;
|
||||
struct wined3d_shader_dst_param reg;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue