Home | All Classes | Grouped Classes | Index | Search

Class CL_DisplayMode

Display mode class. More...

Derived from: none
Derived by: none
Group: Display (Display 2D)

#include <ClanLib/display.h>

Construction:

CL_DisplayMode

Attributes:

get_resolution

Returns the resolution of the displaymode.

get_bpp

Returns the numbers of bytes per pixel of the displaymode.

get_refresh_rate

Returns the refresh rate of the displaymode.

get_string

Returns the information as a string in the format "640x480x32@60"

get_display_modes

Returns a list over all available display modes.

Operations:

operator =

Copy assignment operator.

Detailed description:

!group=Display/Display 2D! !header=display.h!

This class contains information about one display mode available. It also contains a static function to get a list of all available display modes.

Code example which dumps a list over all available modes:

  std::vector < CL_DisplayMode > &modes = CL_DisplayMode::get_display_modes();
  for(unsigned int i=0; i < modes.size(); ++i)
      std::cout << modes[i].get_string() << std::endl;
  


Questions or comments, write to the
ClanLib mailing list.