Allegro.cc - Online Community

Allegro.cc Forums » Programming Questions » antialias

This thread is locked; no one can reply to it. rss feed Print
antialias
superstar4410
Member #926
January 2001
avatar

How do I achieve antialias with allegro 5.0

Thanks,

Don't take yourself too seriously, but do take your responsibilities very seriously.

SiegeLord
Member #7,827
October 2006
avatar

al_set_new_display_option(ALLEGRO_SAMPLE_BUFFERS, 1, ALLEGRO_REQUIRE); /* Make this a ALLEGRO_SUGGEST if you don't want it to fail if your GPU doesn't support multisampling */
al_set_new_display_option(ALLEGRO_SAMPLES, 4, ALLEGRO_SUGGEST);

before creating the display.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

Todd Cope
Member #998
November 2000
avatar

You may also want to do this before loading your bitmaps:

al_set_new_bitmap_flags(ALLEGRO_MIN_LINEAR | ALLEGRO_MAG_LINEAR);

superstar4410
Member #926
January 2001
avatar

Cool thanks, and what do you mean by allegro_suggest, how do I do it that way, thanks.

Did allegro 4 have antialias, i'm learning about soo many cool things about allegro 5

-WNL

[EDIT]

I see what you mean by allegro suggest, nvrmnd

Don't take yourself too seriously, but do take your responsibilities very seriously.

Felix-The-Ghost
Member #9,729
April 2008
avatar

His next line has the ALLEGRO_SUGGEST. Just have the first line but switch the last argument.

==========================
<--- The ghost with the most!
---------------------------
[Website] [Youtube]

superstar4410
Member #926
January 2001
avatar

I'm not sure if its working, when I call allegro_suggest using both functions above, the program dosent start, it fails(no errors) to create the display window.

I am calling it before display is created. When I call allegro_require on both functions it creates the display window but i'm not sure if its actually working, i'm trying to see now if I can notice a difference with it on and off.

Don't take yourself too seriously, but do take your responsibilities very seriously.

larienna
Member #3,185
January 2003
avatar

I there antialiassing options for allegro 4.4?

Does it applies only to ttf and text, or can it also be used for bitmaps?

Enjoy! and have fun

Todd Cope
Member #998
November 2000
avatar

Some TTF add-ons for Allegro 4 support anti-aliasing. There are also add-ons to handle anti-aliased bitmap drawing. You can find these in the Libraries section of this site.

superstar4410
Member #926
January 2001
avatar

Are you saying this antialias in 5.0.6 is only for text?

Don't take yourself too seriously, but do take your responsibilities very seriously.

Todd Cope
Member #998
November 2000
avatar

No. larienna asked about anti-aliasing with Allegro 4. In A5, anti-aliasing affects everything if you have it enabled.

superstar4410
Member #926
January 2001
avatar

I'm thinking maybe my lenovo laptop does not support msaa. But I tried the game on my desktop which I know supports msaa because I've played MW2 on it with AA settings and I've played Crysis on my desktop with AA on. It fails to create the display also when I run it on my desktop, nothing happen I double click the exe.

Any ideas?

Don't take yourself too seriously, but do take your responsibilities very seriously.

Go to: