OSDN Git Service

Macgui: Remove now defunct PictureGLView .h and .mm as they are no longer necessary...
authordynaflash <dynaflash@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Sun, 13 Jan 2008 15:04:52 +0000 (15:04 +0000)
committerdynaflash <dynaflash@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Sun, 13 Jan 2008 15:04:52 +0000 (15:04 +0000)
- Effectively completes the removal of "Useless OpenGL Effects" from Picture Preview.

git-svn-id: svn://localhost/HandBrake/trunk@1190 b64f7644-9d1e-0410-96f1-a4d463321fa5

macosx/HandBrake.xcodeproj/project.pbxproj
macosx/PictureGLView.h [deleted file]
macosx/PictureGLView.mm [deleted file]

index d961f7f..2717686 100644 (file)
                25DE1FB70C169A0C00F01FC8 /* HBPreferencesController.m in Sources */ = {isa = PBXBuildFile; fileRef = 25DE1FB50C169A0C00F01FC8 /* HBPreferencesController.m */; };
                4D1125D809D72FD200E0657B /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D1125D709D72FD200E0657B /* libz.dylib */; };
                4DD93F8F082036E8008E1322 /* Controller.h in Headers */ = {isa = PBXBuildFile; fileRef = 4DF3C8CB052889CD00A80101 /* Controller.h */; };
-               4DD93F90082036E8008E1322 /* PictureGLView.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D85758F052B78E300C39CA9 /* PictureGLView.h */; };
                4DD93F92082036E8008E1322 /* PictureController.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D1FD381073D19CE00E46515 /* PictureController.h */; };
                4DD93F97082036E8008E1322 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; };
                4DD93F9A082036E8008E1322 /* main.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.mm */; settings = {ATTRIBUTES = (); }; };
                4DD93F9B082036E8008E1322 /* Controller.mm in Sources */ = {isa = PBXBuildFile; fileRef = 4DF3C8CC052889CD00A80101 /* Controller.mm */; };
-               4DD93F9C082036E8008E1322 /* PictureGLView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 4D85758E052B78E300C39CA9 /* PictureGLView.mm */; };
                4DD93F9E082036E8008E1322 /* PictureController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 4D1FD382073D19CE00E46515 /* PictureController.mm */; };
                4DD93FA2082036E8008E1322 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; };
                4DD93FA3082036E8008E1322 /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4DEB2024052B055F00C39CA9 /* IOKit.framework */; };
                4D1125D709D72FD200E0657B /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = /usr/lib/libz.dylib; sourceTree = "<absolute>"; };
                4D1FD381073D19CE00E46515 /* PictureController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = PictureController.h; sourceTree = "<group>"; };
                4D1FD382073D19CE00E46515 /* PictureController.mm */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.objcpp; path = PictureController.mm; sourceTree = "<group>"; };
-               4D85758E052B78E300C39CA9 /* PictureGLView.mm */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.objcpp; path = PictureGLView.mm; sourceTree = "<group>"; };
-               4D85758F052B78E300C39CA9 /* PictureGLView.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = PictureGLView.h; sourceTree = "<group>"; };
                4DDE9724052B7B2B00C39CA9 /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = /System/Library/Frameworks/OpenGL.framework; sourceTree = "<absolute>"; };
                4DEB2024052B055F00C39CA9 /* IOKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = IOKit.framework; path = /System/Library/Frameworks/IOKit.framework; sourceTree = "<absolute>"; };
                4DF3C8CB052889CD00A80101 /* Controller.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Controller.h; sourceTree = "<group>"; };
                                4D1FD382073D19CE00E46515 /* PictureController.mm */,
                                4DF3C8CB052889CD00A80101 /* Controller.h */,
                                4DF3C8CC052889CD00A80101 /* Controller.mm */,
-                               4D85758E052B78E300C39CA9 /* PictureGLView.mm */,
-                               4D85758F052B78E300C39CA9 /* PictureGLView.h */,
                                593034E90BBA39A100172349 /* ChapterTitles.h */,
                                593034EA0BBA39A100172349 /* ChapterTitles.m */,
                                A2A1EC300C76C35E00827E0D /* HBDVDDetector.h */,
                        files = (
                                A2DFC6750C6197C600E66E89 /* MVMenuButton.h in Headers */,
                                4DD93F8F082036E8008E1322 /* Controller.h in Headers */,
-                               4DD93F90082036E8008E1322 /* PictureGLView.h in Headers */,
                                4DD93F92082036E8008E1322 /* PictureController.h in Headers */,
                                A2A1EC310C76C35E00827E0D /* HBDVDDetector.h in Headers */,
                                253886010BFE0A5B0064E995 /* HBOutputRedirect.h in Headers */,
                                59CBD2650BBB4D1B004A3BE3 /* ChapterTitles.m in Sources */,
                                4DD93F9A082036E8008E1322 /* main.mm in Sources */,
                                4DD93F9B082036E8008E1322 /* Controller.mm in Sources */,
-                               4DD93F9C082036E8008E1322 /* PictureGLView.mm in Sources */,
                                4DD93F9E082036E8008E1322 /* PictureController.mm in Sources */,
                                A2A1EC3A0C76C58400827E0D /* HBDVDDetector.m in Sources */,
                                253886020BFE0A5B0064E995 /* HBOutputRedirect.m in Sources */,
diff --git a/macosx/PictureGLView.h b/macosx/PictureGLView.h
deleted file mode 100644 (file)
index bcbb095..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-/* $Id: PictureGLView.h,v 1.7 2005/08/01 15:10:44 titer Exp $
-
-   This file is part of the HandBrake source code.
-   Homepage: <http://handbrake.m0k.org/>.
-   It may be used under the terms of the GNU General Public License. */
-
-#include <Cocoa/Cocoa.h>
-
-#include "hb.h"
-
-#define HB_ANIMATE_NONE     1
-#define HB_ANIMATE_BACKWARD 2
-#define HB_ANIMATE_FORWARD  4
-#define HB_ANIMATE_SLOW     8
-
-@interface HBPictureGLView : NSOpenGLView
-
-{
-    bool            fHasQE;
-    unsigned long   fTarget;
-
-    int             fWidth;
-    int             fHeight;
-    int             fTexWidth;
-    int             fTexHeight;
-    float           fCoordX;
-    float           fCoordY;
-
-    uint8_t       * fBuffers[2];
-    #if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_4
-    unsigned long   fTextures[2];
-    #else
-    /* Leopard */
-    unsigned int   fTextures[2];
-    #endif;
-    
-    int             fLastEffect;
-    int             fAnimDuration;
-    int             fFrameRate;
-}
-
-- (id) initWithFrame: (NSRect) frame;
-- (void) reshape;
-- (void) drawRect: (NSRect) rect;
-- (void) drawAnimation: (int) anim;
-
-- (void) Display: (int) anim buffer1: (uint8_t *) buffer1
-    buffer2: (uint8_t *) buffer2 width: (int) width
-    height: (int) height;
-
-@end
diff --git a/macosx/PictureGLView.mm b/macosx/PictureGLView.mm
deleted file mode 100644 (file)
index 8aeacba..0000000
+++ /dev/null
@@ -1,432 +0,0 @@
-/* $Id: PictureGLView.mm,v 1.18 2005/08/01 15:10:44 titer Exp $
-
-   This file is part of the HandBrake source code.
-   Homepage: <http://handbrake.m0k.org/>.
-   It may be used under the terms of the GNU General Public License. */
-
-#include <OpenGL/OpenGL.h>
-#include <OpenGL/gl.h>
-#include <OpenGL/glext.h>
-#include <math.h>
-
-#include "PictureGLView.h"
-
-static int GetAlignedSize( int size )
-{
-    int result = 1;
-    while( result < size )
-    {
-        result *= 2;
-    }
-    return result;
-}
-
-@implementation HBPictureGLView
-
-- (id) initWithFrame: (NSRect) frame
-{
-    fHasQE  = CGDisplayUsesOpenGLAcceleration( kCGDirectMainDisplay );
-    fTarget = fHasQE ? GL_TEXTURE_RECTANGLE_EXT : GL_TEXTURE_2D;
-
-    fBuffers[0] = NULL;
-    fBuffers[1] = NULL;
-    fWidth      = 0;
-    fHeight     = 0;
-
-    fLastEffect = -1;
-    
-    GLuint attribs[] =
-    {
-        NSOpenGLPFANoRecovery,
-        NSOpenGLPFAWindow,
-        NSOpenGLPFAAccelerated,
-        NSOpenGLPFADoubleBuffer,
-        NSOpenGLPFAColorSize, 24,
-        NSOpenGLPFAAlphaSize, 8,
-        NSOpenGLPFADepthSize, 24,
-        NSOpenGLPFAStencilSize, 8,
-        NSOpenGLPFAAccumSize, 0,
-        0
-    };
-
-    NSOpenGLPixelFormat * fmt = [[NSOpenGLPixelFormat alloc]
-        initWithAttributes: (NSOpenGLPixelFormatAttribute*) attribs];
-
-    self = [super initWithFrame:frame pixelFormat: [fmt autorelease]];
-
-    if( !self )
-    {
-        return NULL;
-    }
-
-    [[self openGLContext] makeCurrentContext];
-    [self reshape];
-
-    glGenTextures( 2, fTextures );
-
-    return self;
-}
-
-- (void) reshape
-{
-    NSRect bounds;
-    [[self openGLContext] update];
-    [[self openGLContext] makeCurrentContext];
-    bounds = [self bounds];
-    glViewport( 0, 0, (int) bounds.size.width,
-                (int) bounds.size.height );
-}
-
-- (void) drawRect: (NSRect) rect
-{
-    [[self openGLContext] makeCurrentContext];
-
-    glDisable( GL_DEPTH_TEST );
-    glDisable( GL_CULL_FACE );
-    glDisable( GL_BLEND );
-
-    glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
-
-    if( fBuffers[0] )
-    {
-        glMatrixMode( GL_PROJECTION );
-        glLoadIdentity();
-        glMatrixMode( GL_MODELVIEW );
-        glLoadIdentity();
-
-        glEnable( fTarget );
-        glBindTexture( fTarget, fTextures[0] );
-        glTexImage2D( fTarget, 0, GL_RGBA, fTexWidth, fTexHeight, 0,
-                      GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, fBuffers[0] );
-        glTexParameteri( fTarget, GL_TEXTURE_MIN_FILTER, GL_LINEAR );
-        glTexParameteri( fTarget, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
-
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0    , 0.0     ); glVertex2f( -1.0,  1.0 );
-        glTexCoord2f( 0.0    , fCoordY ); glVertex2f( -1.0, -1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex2f(  1.0, -1.0 );
-        glTexCoord2f( fCoordX, 0.0     ); glVertex2f(  1.0,  1.0 );
-        glEnd();
-    }
-    [[self openGLContext] flushBuffer];
-}
-
-#define FRUSTUM_NEAR   2.5
-#define FRUSTUM_FAR    20.0
-
-- (void) drawCube: (int) anim
-{
-    uint64_t date;
-    float w, rotation, translation;
-    
-    w = ( anim & HB_ANIMATE_BACKWARD ) ? 1.0 : -1.0;
-
-    glEnable( GL_DEPTH_TEST );
-    glEnable( GL_CULL_FACE );
-    glDisable( GL_BLEND );
-
-    for( rotation = 0.0; w * rotation < 90.0;
-         rotation += w * 90 * 1000 / fAnimDuration / fFrameRate )
-    {
-        date = hb_get_date();
-        translation = - FRUSTUM_NEAR - cos( rotation * M_PI / 180 ) *
-            ( 1 + w * tan( rotation * M_PI / 180 ) );
-
-        glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
-
-        glMatrixMode( GL_PROJECTION );
-        glLoadIdentity();
-        glFrustum( -1.0, 1.0, -1.0, 1.0, FRUSTUM_NEAR, FRUSTUM_FAR );
-        glMatrixMode( GL_MODELVIEW );
-        glLoadIdentity();
-        glTranslatef( 0.0, 0.0, translation );
-        glRotatef( rotation, 0.0, 1.0, 0.0 );
-     
-        glBindTexture( fTarget, fTextures[0] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0    , 0.0 );     glVertex3f( -1.0,  1.0, 1.0 );
-        glTexCoord2f( 0.0    , fCoordY ); glVertex3f( -1.0, -1.0, 1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex3f(  1.0, -1.0, 1.0 );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex3f(  1.0,  1.0, 1.0 );
-        glEnd();
-     
-        glBindTexture( fTarget, fTextures[1] );
-        glBegin( GL_QUADS );
-        if( anim & HB_ANIMATE_FORWARD )
-        {
-            glTexCoord2f( 0.0,    0.0 );     glVertex3f( 1.0,  1.0,  1.0 );
-            glTexCoord2f( 0.0,    fCoordY ); glVertex3f( 1.0, -1.0,  1.0 );
-            glTexCoord2f( fCoordX, fCoordY ); glVertex3f( 1.0, -1.0, -1.0 );
-            glTexCoord2f( fCoordX, 0.0 );     glVertex3f( 1.0,  1.0, -1.0 );
-        }
-        else
-        {
-            glTexCoord2f( 0.0,    0.0 );     glVertex3f( -1.0,  1.0, -1.0 );
-            glTexCoord2f( 0.0,    fCoordY ); glVertex3f( -1.0, -1.0, -1.0 );
-            glTexCoord2f( fCoordX, fCoordY ); glVertex3f( -1.0, -1.0,  1.0 );
-            glTexCoord2f( fCoordX, 0.0 );     glVertex3f( -1.0,  1.0,  1.0 );
-        }
-        glEnd();
-     
-        [[self openGLContext] flushBuffer];
-
-        hb_snooze( 1000 / fFrameRate - ( hb_get_date() - date ) );
-    }
-
-}
-
-- (void) drawSwap: (int) anim
-{
-    uint64_t date;
-    float w, rotation, x, z;
-    
-    w = ( anim & HB_ANIMATE_BACKWARD ) ? 1.0 : -1.0;
-
-    glEnable( GL_DEPTH_TEST );
-    glEnable( GL_CULL_FACE );
-    glDisable( GL_BLEND );
-
-    glMatrixMode( GL_PROJECTION );
-    glLoadIdentity();
-    glFrustum( -1.0, 1.0, -1.0, 1.0, FRUSTUM_NEAR, FRUSTUM_FAR );
-    glMatrixMode( GL_MODELVIEW );
-    glLoadIdentity();
-    glTranslatef( 0.0, 0.0, - FRUSTUM_NEAR - 1.0 );
-
-    for( rotation = 0.0; w * rotation < 180.0;
-         rotation += w * 180 * 1000 / fAnimDuration / fFrameRate )
-    {
-        date = hb_get_date();
-
-        glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
-
-        x = 1.1 * sin( rotation * M_PI / 180 );
-        z = cos( rotation * M_PI / 180 );
-
-        glBindTexture( fTarget, fTextures[0] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex3f( -1.0 + x,  1.0, z );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex3f( -1.0 + x, -1.0, z );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex3f(  1.0 + x, -1.0, z );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex3f(  1.0 + x,  1.0, z );
-        glEnd();
-     
-        glBindTexture( fTarget, fTextures[1] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex3f( -1.0 - x,  1.0, - z );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex3f( -1.0 - x, -1.0, - z );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex3f(  1.0 - x, -1.0, - z );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex3f(  1.0 - x,  1.0, - z );
-        glEnd();
-     
-        [[self openGLContext] flushBuffer];
-
-        hb_snooze( 1000 / fFrameRate - ( hb_get_date() - date ) );
-    }
-}
-
-- (void) drawFade
-{
-    uint64_t date;
-    float alpha;
-
-    glDisable( GL_DEPTH_TEST );
-    glDisable( GL_CULL_FACE );
-    glEnable( GL_BLEND );
-
-    glMatrixMode( GL_PROJECTION );
-    glLoadIdentity();
-    glMatrixMode( GL_MODELVIEW );
-    glLoadIdentity();
-
-    for( alpha = 0.0; alpha < 1.0;
-         alpha += 1000.0 / fAnimDuration / fFrameRate )
-    {
-        date = hb_get_date();
-
-        glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
-
-        glColor4f( 1.0, 1.0, 1.0, 1.0 - alpha );
-        glBlendFunc( GL_SRC_ALPHA, GL_ONE );
-
-        glBindTexture( fTarget, fTextures[0] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex2f( -1.0,  1.0 );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex2f( -1.0, -1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex2f(  1.0, -1.0 );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex2f(  1.0,  1.0 );
-        glEnd();
-
-        glColor4f( 1.0, 1.0, 1.0, alpha );
-        glBlendFunc( GL_SRC_ALPHA, GL_ONE );
-
-        glBindTexture( fTarget, fTextures[1] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex2f( -1.0,  1.0 );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex2f( -1.0, -1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex2f(  1.0, -1.0 );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex2f(  1.0,  1.0 );
-        glEnd();
-
-        [[self openGLContext] flushBuffer];
-
-        hb_snooze( 1000 / fFrameRate - ( hb_get_date() - date ) );
-    }
-}
-
-- (void) drawSlide: (int) anim
-{
-    uint64_t date;
-    float foo, w;
-    int left, right;
-    if( anim & HB_ANIMATE_FORWARD )
-    {
-        left  = 0;
-        right = 1;
-        w     = 1.0;
-    }
-    else
-    {
-        left  = 1;
-        right = 0;
-        w     = -1.0;
-    }
-
-    glDisable( GL_DEPTH_TEST );
-    glDisable( GL_CULL_FACE );
-    glDisable( GL_BLEND );
-
-    glMatrixMode( GL_PROJECTION );
-    glLoadIdentity();
-    glMatrixMode( GL_MODELVIEW );
-    glLoadIdentity();
-
-    for( foo = w; foo >= -1.0 && foo <= 1.0;
-         foo -= w * 2000.0 / fAnimDuration / fFrameRate )
-    {
-        date = hb_get_date();
-
-        glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
-
-        glBindTexture( fTarget, fTextures[left] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex2f( foo - 2.0,  1.0 );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex2f( foo - 2.0, -1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex2f( foo,       -1.0 );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex2f( foo,        1.0 );
-        glEnd();
-
-        glBindTexture( fTarget, fTextures[right] );
-        glBegin( GL_QUADS );
-        glTexCoord2f( 0.0,    0.0 );     glVertex2f( foo,        1.0 );
-        glTexCoord2f( 0.0,    fCoordY ); glVertex2f( foo,       -1.0 );
-        glTexCoord2f( fCoordX, fCoordY ); glVertex2f( foo + 2.0, -1.0 );
-        glTexCoord2f( fCoordX, 0.0 );     glVertex2f( foo + 2.0,  1.0 );
-        glEnd();
-
-        [[self openGLContext] flushBuffer];
-
-        hb_snooze( 1000 / fFrameRate - ( hb_get_date() - date ) );
-    }
-}
-
-#undef FRUSTUM_NEAR
-#undef FRUSTUM_FAR
-
-- (void) drawAnimation: (int) anim
-{
-    glEnable( fTarget );
-
-    glBindTexture( fTarget, fTextures[0] );
-    glTexImage2D( fTarget, 0, GL_RGBA, fTexWidth, fTexHeight, 0,
-                  GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, fBuffers[1] );
-    glTexParameteri( fTarget, GL_TEXTURE_MIN_FILTER, GL_LINEAR );
-    glTexParameteri( fTarget, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
-
-    glBindTexture( fTarget, fTextures[1] );
-    glTexImage2D( fTarget, 0, GL_RGBA, fTexWidth, fTexHeight, 0,
-                  GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, fBuffers[0] );
-    glTexParameteri( fTarget, GL_TEXTURE_MIN_FILTER, GL_LINEAR );
-    glTexParameteri( fTarget, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
-
-    /* Draw a random animation, just making sure we don't use the same
-       effect two times in a row */
-    int effect;
-    do
-    {
-        effect = hb_get_date() % 4;
-    }
-    while( effect == fLastEffect );
-
-    fAnimDuration = ( anim & HB_ANIMATE_SLOW ) ? 3000 : 600;
-    fFrameRate    = 60.0;
-    
-    switch( effect )
-    {
-        case 0:
-            [self drawCube: anim];
-            break;
-        case 1:
-            [self drawSwap: anim];
-            break;
-        case 2:
-            [self drawFade];
-            break;
-        case 3:
-            [self drawSlide: anim];
-            break;
-    }
-
-    fLastEffect = effect;
-}
-
-- (void) Display: (int) anim buffer1: (uint8_t *) buffer1
-    buffer2: (uint8_t *) buffer2 width: (int) width height: (int) height
-{
-    [[self openGLContext] makeCurrentContext];
-
-    if( width != fWidth || height != fHeight )
-    {
-        fWidth  = width;
-        fHeight = height;
-        if( fHasQE )
-        {
-            fTexWidth  = fWidth;
-            fTexHeight = fHeight;
-            fCoordX    = (float) fWidth;
-            fCoordY    = (float) fHeight;
-        }
-        else
-        {
-            fTexWidth  = GetAlignedSize( fWidth );
-            fTexHeight = GetAlignedSize( fHeight );
-            fCoordX    = (float) fWidth  / (float) fTexWidth;
-            fCoordY    = (float) fHeight / (float) fTexHeight;
-        }
-        [self clearGLContext];
-        [self openGLContext];
-        [self reshape];
-    }
-
-    fBuffers[0] = buffer1;
-    fBuffers[1] = buffer2;
-
-    /* Swap buffers only during the vertical retrace of the monitor.
-       http://developer.apple.com/documentation/GraphicsImaging/
-       Conceptual/OpenGL/chap5/chapter_5_section_44.html */
-    #if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_4
-    long params[] = { 1 };
-    #else
-    int params[] = { 1 };
-    #endif
-    CGLSetParameter( CGLGetCurrentContext(), kCGLCPSwapInterval, params );
-
-    if( !( anim & HB_ANIMATE_NONE ) )
-    {
-        [self drawAnimation: anim];
-    }
-    
-    [self drawRect: [self bounds]];
-}
-
-@end