Thread: Allegro

  1. #1
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    Allegro

    I went and downloaded the binary zip from the allegro website. I put them in the include and library folders. I got 26 error messages while compiling any regular thing, hello world doesn't even work. I thought I followed the directions right, I even checked the c code in notepad. Anyone know what I did wrong?

  2. #2
    Used Registerer jdinger's Avatar
    Join Date
    Feb 2002
    Posts
    1,065
    Email or PM TechWins. As far as I know he's our resident Allegro guru.

  3. #3
    Unregistered Leeman_s's Avatar
    Join Date
    Oct 2001
    Posts
    753
    I can help! First, download the bat file below. Then copy it into your allegro directory. Then open up an MS DOS window and get to you allegro directory ex. cd \desktop\allegro or wherever it is. Then type vcvars32.bat and hit enter. Then type msvcmake.bat. Now it's installing and there you go!

  4. #4
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    ?

    vcvars32.bat is missing. It says its a bad command or file name.

  5. #5
    Unregistered Leeman_s's Avatar
    Join Date
    Oct 2001
    Posts
    753
    ugh, silly me. you arent even using MSVC++, borland is different

  6. #6
    Sir Mister Insane Sako Klinerr1's Avatar
    Join Date
    May 2002
    Posts
    608
    techwins used a setup program and like me uses dev c++. hes not to sure where he got the setup if anyone knows please share!(m rying to set it up salso, i got it to work once before)
    Email: [email protected] || AIM: MisterSako || MSN: [email protected]

    -the shroom has spoken

  7. #7
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    Please..

    Anyone that knows how to install allegro into borland, reply.

  8. #8
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    techwin...

    when was the last time techwin was on? he hasn't responded to my message... its been 24 hours. Anyone else give it a try?

  9. #9
    I too had many problems when I was trying to install allegro (with VC++)
    And JustinW helped me alot. To bad I haven't seen him around for the last few months.
    But I remember his website. He made some Allegro installer programs for different compilers
    You might want to give those a try.
    here is the URL:
    http://galileo.spaceports.com/~springs/

  10. #10
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    ...

    I don't know if it worked because I still get the same 26 error messages... about not being able to load so and so. Heres the example code that came with allegro... I tried to compile it but thats when the errors come in...

    Code:
    #include <stdio.h>
    #include <allegro.h>
    
    int main(void)
    {
        int i;
    
        allegro_init();
    
        install_keyboard();
    
        printf("\nThe program will show some dots, then wait a keypress.\n");
        printf("After sucesive keypresses the screen will be cleared to different colors\n");
        printf("\nPress any key to begin\n\n");
    
        readkey();
    
        if (set_gfx_mode(GFX_AUTODETECT, 320, 200, 0, 0) < 0) {
    	printf("%s\n", allegro_error);
    	exit(1);
        }
        // Now prepare for some random dots...
    
        for (i = 0; i < 64000; i++) {
    	putpixel(screen, rand() % SCREEN_W, rand() % SCREEN_H, rand() % 256);
        }
    
        readkey();
    
        for (i = 0; i < 16; i++) {
    	clear_to_color(screen, i);
    	readkey();
        }
    
        return 0;
    }
    END_OF_MAIN();

  11. #11
    I don't have allegro installed anymore, so I can't help you with that.
    But perhaps you can ask it at allegro.cc. Maybe you'll run in to JustinW
    They have a "Installation, Setup & Configuration" board. Maybe do a search over there.

  12. #12
    Registered User
    Join Date
    Feb 2002
    Posts
    19
    Are the error's Link errors or Compiler errors?

    If they are compile errors it probably means that Allegro was not compiled correctly.

    If they are Link errors it means that you are not linking to the Allegro DLL's.

    What I had to do to get rid of my link errors was to first make sure my compiler knew the location of the DLL's and then I added each specific DLL to the project settings Object/library modules list.

    Of course how I set that up would be different for Borland so I cant help you with the actual process of making DLL's link to your program.
    Compilers: MSVC++ 6.0, Dev-C++ 4.0, DJGPP
    Operating System: Windows 98

  13. #13
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    ...

    It was 26 compiler errors.

  14. #14
    Unregistered Leeman_s's Avatar
    Join Date
    Oct 2001
    Posts
    753
    Ok, I'll fill you in. First of all you need to make sure you've actually INSTALLED allegro. I recommend doing this in a DOS window. You will actually get a message that says it's installed correctly. And make sure when you do this that the allegro folder is in the directory for your compiler. The install instructions come with allegro. It's somewhere like allegro > lib > build > borland. Also, make sure you link alleg.lib in your program.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Allegro in C for a newb
    By Ideius in forum C Programming
    Replies: 5
    Last Post: 12-29-2005, 04:36 PM
  2. Game Programming FAQ
    By TechWins in forum Game Programming
    Replies: 5
    Last Post: 09-29-2004, 02:00 AM
  3. double buffering for allegro
    By Leeman_s in forum C++ Programming
    Replies: 6
    Last Post: 09-12-2002, 02:45 PM
  4. Special Allegro Information
    By TechWins in forum Game Programming
    Replies: 12
    Last Post: 08-20-2002, 11:35 PM
  5. Allegro programming in a window
    By Person Man in forum Windows Programming
    Replies: 0
    Last Post: 11-16-2001, 03:23 PM