Commit b8ec6714 authored by Chad Versace's avatar Chad Versace

tests,util: Wrap glutReshapeFunc with piglit_set_reshape_func

I'm trying to transition Piglit from using GLUT to using Waffle. This
requires killing all uses of GLUT functions, one-by-one.

One remaining test called glutReshapeFunc directly: texline.  This patch
replace that call with a new wrapper, piglit_set_reshape_func.
Reviewed-and-tested-by: Jordan Justen's avatarJordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Kenneth Graunke's avatarKenneth Graunke <kenneth@whitecape.org>
Tested-by: Paul Berry's avatarPaul Berry <stereotype441@gmail.com>
Acked-by: Eric Anholt's avatarEric Anholt <eric@anholt.net>
Signed-off-by: default avatarChad Versace <chad.versace@linux.intel.com>
parent 3168c103
......@@ -163,3 +163,10 @@ piglit_swap_buffers(void)
else
piglit_framework_glut_swap_buffers();
}
void
piglit_set_reshape_func(void (*func)(int w, int h))
{
if (!piglit_use_fbo && !piglit_automatic)
glutReshapeFunc(func);
}
......@@ -132,5 +132,6 @@ void piglit_swap_buffers(void);
extern void piglit_present_results();
void piglit_post_redisplay(void);
void piglit_set_keyboard_func(void (*func)(unsigned char key, int x, int y));
void piglit_set_reshape_func(void (*func)(int w, int h));
#endif /* PIGLIT_FRAMEWORK_H */
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