cvs.gedasymbols.org/archives/browse.cgi   search  
Mail Archives: djgpp/1999/08/22/09:15:07

From: "Al Morgan" <muaddib AT proaxis DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Page Flipping & Allegro
Date: Sun, 22 Aug 1999 03:24:31 -0700
Organization: Posted via Supernews, http://www.supernews.com
Lines: 31
Message-ID: <rrvjt380mkf8@corp.supernews.com>
X-Complaints-To: newsabuse AT supernews DOT com
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2314.1300
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Whats a good way to do page flipping with allegro?  Most of my attempts make
the program go way way way slower than it previously did.  I don't know if
that's unavoidable, or if I'm doing it wrong.

I did it something like this before:

void page_flip()
    {
    show_video_bitmap(screen2); // thats the screen i would write everything
onto
                                                   // would this function
copy screen2 to screen, or
                                                   // would it change the
viewport to screen2?

    }

void main()
    {
    // set the gfx mode to 320, 240 view, 320, 480 virtual size
    while(!gameover)
        {
        drawstuff();
        page_flip();
        }
    }

Thanks,
    Al [muaddib AT proaxis DOT com]


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019