Commit fc7ea69e authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Pass a wined3d_context_gl structure to context_texture_update().

parent 9cb572cb
......@@ -1093,13 +1093,15 @@ void context_gl_resource_released(struct wined3d_device *device,
context_enum_fbo_entries(device, name, rb_namespace, context_queue_fbo_entry_destruction);
}
void context_texture_update(struct wined3d_context *context, const struct wined3d_texture_gl *texture_gl)
void wined3d_context_gl_texture_update(struct wined3d_context_gl *context_gl,
const struct wined3d_texture_gl *texture_gl)
{
const struct wined3d_gl_info *gl_info = context->gl_info;
struct fbo_entry *entry = context->current_fbo;
const struct wined3d_gl_info *gl_info = context_gl->c.gl_info;
struct fbo_entry *entry = context_gl->c.current_fbo;
unsigned int i;
if (!entry || context->rebind_fbo) return;
if (!entry || context_gl->c.rebind_fbo)
return;
for (i = 0; i < gl_info->limits.buffers + 1; ++i)
{
......@@ -1107,7 +1109,7 @@ void context_texture_update(struct wined3d_context *context, const struct wined3
|| texture_gl->texture_srgb.name == entry->key.objects[i].object)
{
TRACE("Updated texture %p is bound as attachment %u to the current FBO.\n", texture_gl, i);
context->rebind_fbo = TRUE;
context_gl->c.rebind_fbo = TRUE;
return;
}
}
......
......@@ -2127,7 +2127,7 @@ void wined3d_texture_upload_data(struct wined3d_texture *texture, unsigned int s
for (i = 0; i < device->context_count; ++i)
{
context_texture_update(device->contexts[i], wined3d_texture_gl(texture));
wined3d_context_gl_texture_update(wined3d_context_gl(device->contexts[i]), wined3d_texture_gl(texture));
}
}
}
......
......@@ -2088,6 +2088,8 @@ HRESULT wined3d_context_gl_init(struct wined3d_context_gl *context_gl,
void wined3d_context_gl_load_tex_coords(const struct wined3d_context_gl *context_gl,
const struct wined3d_stream_info *si, GLuint *current_bo, const struct wined3d_state *state) DECLSPEC_HIDDEN;
void wined3d_context_gl_set_draw_buffer(struct wined3d_context_gl *context_gl, GLenum buffer) DECLSPEC_HIDDEN;
void wined3d_context_gl_texture_update(struct wined3d_context_gl *context_gl,
const struct wined3d_texture_gl *texture_gl) DECLSPEC_HIDDEN;
void wined3d_context_gl_update_stream_sources(struct wined3d_context_gl *context_gl,
const struct wined3d_state *state) DECLSPEC_HIDDEN;
......@@ -2264,8 +2266,6 @@ void context_state_drawbuf(struct wined3d_context *context,
const struct wined3d_state *state, DWORD state_id) DECLSPEC_HIDDEN;
void context_state_fb(struct wined3d_context *context,
const struct wined3d_state *state, DWORD state_id) DECLSPEC_HIDDEN;
void context_texture_update(struct wined3d_context *context,
const struct wined3d_texture_gl *texture_gl) DECLSPEC_HIDDEN;
void context_unload_tex_coords(const struct wined3d_context *context) DECLSPEC_HIDDEN;
void context_unmap_bo_address(struct wined3d_context *context,
const struct wined3d_bo_address *data, GLenum binding) DECLSPEC_HIDDEN;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment