[PATCH 5/5] wined3d: Clarify the comment about deleting a GL stream output buffer.
Zebediah Figura
zfigura at codeweavers.com
Sun Oct 17 15:08:34 CDT 2021
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
---
dlls/wined3d/buffer.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c
index b994d625f12..4bb2b210265 100644
--- a/dlls/wined3d/buffer.c
+++ b/dlls/wined3d/buffer.c
@@ -147,9 +147,9 @@ static void wined3d_buffer_gl_destroy_buffer_object(struct wined3d_buffer_gl *bu
if (context_gl->c.transform_feedback_active && resource->bind_flags & WINED3D_BIND_STREAM_OUTPUT)
{
- /* We have to make sure that transform feedback is not active
- * when deleting a potentially bound transform feedback buffer.
- * This may happen when the device is being destroyed. */
+ /* It's illegal to (un)bind GL_TRANSFORM_FEEDBACK_BUFFER while transform
+ * feedback is active. Deleting a buffer implicitly unbinds it, so we
+ * always end transform feedback here in case this buffer was bound. */
WARN("Deleting buffer object for buffer %p, disabling transform feedback.\n", buffer_gl);
wined3d_context_gl_end_transform_feedback(context_gl);
}
--
2.33.0
More information about the wine-devel
mailing list