diff options
author | Chia-I Wu <[email protected]> | 2010-01-31 11:26:56 +0800 |
---|---|---|
committer | Chia-I Wu <[email protected]> | 2010-01-31 11:31:58 +0800 |
commit | 996fd61442e4186e23418cc8a3b0cd593398be26 (patch) | |
tree | 44d3eaed3e7b106a05c2ade2c9bb31d7555c56f0 /src/egl/main/eglmode.c | |
parent | 89e6eb5fbe7fb036f5d1a5fef040cc9635a10672 (diff) |
egl: Remove code blocks that are commented out.
They are either unit tests or to demonstrate how functions are supposed
to be used. The unit test is outdated and it should be better to take a
look at any of the working drivers to see how a function is used.
Diffstat (limited to 'src/egl/main/eglmode.c')
-rw-r--r-- | src/egl/main/eglmode.c | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/src/egl/main/eglmode.c b/src/egl/main/eglmode.c index 1e26ea83f5f..66446c0495d 100644 --- a/src/egl/main/eglmode.c +++ b/src/egl/main/eglmode.c @@ -350,41 +350,3 @@ _eglQueryModeStringMESA(_EGLDriver *drv, _EGLDisplay *dpy, _EGLMode *m) { return m->Name; } - - -#if 0 -static int -_eglRand(int max) -{ - return rand() % max; -} - -void -_eglTestModeModule(void) -{ - EGLint count = 30; - _EGLMode *modes = (_EGLMode *) malloc(count * sizeof(_EGLMode)); - _EGLMode **modeList = (_EGLMode **) malloc(count * sizeof(_EGLMode*)); - EGLint i; - - for (i = 0; i < count; i++) { - modes[i].Handle = _eglRand(20); - modes[i].Width = 512 + 256 * _eglRand(2); - modes[i].Height = 512 + 256 * _eglRand(2); - modes[i].RefreshRate = 50 + 5 * _eglRand(3); - modes[i].Interlaced = _eglRand(2); - modes[i].Optimal = _eglRand(4) == 0; - modeList[i] = modes + i; - } - - /* sort array of pointers */ - qsort(modeList, count, sizeof(_EGLMode *), compareModes); - - for (i = 0; i < count; i++) { - _EGLMode *m = modeList[i]; - printf("%2d: %3d %4d x %4d @ %3d opt %d int %d\n", i, - m->Handle, m->Width, m->Height, m->RefreshRate, - m->Optimal, m->Interlaced); - } -} -#endif |