17INLINE
bool FrameBufferProperties::
19 return !operator == (other);
25INLINE
bool FrameBufferProperties::
26is_single_buffered()
const {
27 return (_property[FBP_back_buffers] == 0);
33INLINE
bool FrameBufferProperties::
35 return (_flags & FBF_stereo) != 0;
50INLINE
int FrameBufferProperties::
51get_depth_bits()
const {
52 return _property[FBP_depth_bits];
58INLINE
int FrameBufferProperties::
59get_color_bits()
const {
61 _property[FBP_color_bits],
62 _property[FBP_red_bits] +
63 _property[FBP_green_bits] +
64 _property[FBP_blue_bits]);
70INLINE
int FrameBufferProperties::
72 return _property[FBP_red_bits];
78INLINE
int FrameBufferProperties::
79get_green_bits()
const {
80 return _property[FBP_green_bits];
86INLINE
int FrameBufferProperties::
87get_blue_bits()
const {
88 return _property[FBP_blue_bits];
94INLINE
int FrameBufferProperties::
95get_alpha_bits()
const {
96 return _property[FBP_alpha_bits];
102INLINE
int FrameBufferProperties::
103get_stencil_bits()
const {
104 return _property[FBP_stencil_bits];
110INLINE
int FrameBufferProperties::
111get_accum_bits()
const {
112 return _property[FBP_accum_bits];
118INLINE
int FrameBufferProperties::
119get_aux_rgba()
const {
120 return _property[FBP_aux_rgba];
126INLINE
int FrameBufferProperties::
127get_aux_hrgba()
const {
128 return _property[FBP_aux_hrgba];
134INLINE
int FrameBufferProperties::
135get_aux_float()
const {
136 return _property[FBP_aux_float];
142INLINE
int FrameBufferProperties::
143get_multisamples()
const {
144 return _property[FBP_multisamples];
153 return _property[FBP_coverage_samples];
159INLINE
int FrameBufferProperties::
160get_back_buffers()
const {
161 return _property[FBP_back_buffers];
167INLINE
bool FrameBufferProperties::
168get_indexed_color()
const {
169 return (_flags & FBF_indexed_color) != 0;
175INLINE
bool FrameBufferProperties::
176get_rgb_color()
const {
177 return (_flags & FBF_rgb_color) != 0;
183INLINE
bool FrameBufferProperties::
185 return (_flags & FBF_stereo) != 0;
191INLINE
bool FrameBufferProperties::
192get_force_hardware()
const {
193 return (_flags & FBF_force_hardware) != 0;
199INLINE
bool FrameBufferProperties::
200get_force_software()
const {
201 return (_flags & FBF_force_software) != 0;
207INLINE
bool FrameBufferProperties::
208get_srgb_color()
const {
209 return (_flags & FBF_srgb_color) != 0;
215INLINE
bool FrameBufferProperties::
216get_float_color()
const {
217 return (_flags & FBF_float_color) != 0;
223INLINE
bool FrameBufferProperties::
224get_float_depth()
const {
225 return (_flags & FBF_float_depth) != 0;
231INLINE
void FrameBufferProperties::
232set_depth_bits(
int n) {
233 _property[FBP_depth_bits] = n;
234 _specified |= (1 << FBP_depth_bits);
247 _property[FBP_color_bits] = n;
248 _specified |= (1 << FBP_color_bits);
257 _property[FBP_red_bits] = r;
258 _property[FBP_green_bits] = g;
259 _property[FBP_blue_bits] = b;
260 _property[FBP_alpha_bits] = a;
261 _property[FBP_color_bits] = r + g + b;
262 _specified |= (1 << FBP_color_bits) | (1 << FBP_red_bits) |
263 (1 << FBP_green_bits) | (1 << FBP_blue_bits) |
264 (1 << FBP_alpha_bits);
270INLINE
void FrameBufferProperties::
272 _property[FBP_red_bits] = n;
273 _specified |= (1 << FBP_red_bits);
279INLINE
void FrameBufferProperties::
280set_green_bits(
int n) {
281 _property[FBP_green_bits] = n;
282 _specified |= (1 << FBP_green_bits);
288INLINE
void FrameBufferProperties::
289set_blue_bits(
int n) {
290 _property[FBP_blue_bits] = n;
291 _specified |= (1 << FBP_blue_bits);
297INLINE
void FrameBufferProperties::
298set_alpha_bits(
int n) {
299 _property[FBP_alpha_bits] = n;
300 _specified |= (1 << FBP_alpha_bits);
306INLINE
void FrameBufferProperties::
307set_stencil_bits(
int n) {
308 _property[FBP_stencil_bits] = n;
309 _specified |= (1 << FBP_stencil_bits);
315INLINE
void FrameBufferProperties::
316set_accum_bits(
int n) {
317 _property[FBP_accum_bits] = n;
318 _specified |= (1 << FBP_accum_bits);
324INLINE
void FrameBufferProperties::
327 _property[FBP_aux_rgba] = n;
328 _specified |= (1 << FBP_aux_rgba);
334INLINE
void FrameBufferProperties::
335set_aux_hrgba(
int n) {
337 _property[FBP_aux_hrgba] = n;
338 _specified |= (1 << FBP_aux_hrgba);
344INLINE
void FrameBufferProperties::
345set_aux_float(
int n) {
347 _property[FBP_aux_float] = n;
348 _specified |= (1 << FBP_aux_float);
354INLINE
void FrameBufferProperties::
355set_multisamples(
int n) {
356 _property[FBP_multisamples] = n;
357 _specified |= (1 << FBP_multisamples);
366 _property[FBP_coverage_samples] = n;
367 _specified |= (1 << FBP_coverage_samples);
373INLINE
void FrameBufferProperties::
374set_back_buffers(
int n) {
375 _property[FBP_back_buffers] = n;
376 _specified |= (1 << FBP_back_buffers);
382INLINE
void FrameBufferProperties::
383set_indexed_color(
bool n) {
385 _flags |= FBF_indexed_color;
387 _flags &= ~FBF_indexed_color;
389 _flags_specified |= FBF_indexed_color;
395INLINE
void FrameBufferProperties::
396set_rgb_color(
bool n) {
398 _flags |= FBF_rgb_color;
400 _flags &= ~FBF_rgb_color;
402 _flags_specified |= FBF_rgb_color;
408INLINE
void FrameBufferProperties::
411 _flags |= FBF_stereo;
413 _flags &= ~FBF_stereo;
415 _flags_specified |= FBF_stereo;
421INLINE
void FrameBufferProperties::
422set_force_hardware(
bool n) {
424 _flags |= FBF_force_hardware;
426 _flags &= ~FBF_force_hardware;
428 _flags_specified |= FBF_force_hardware;
434INLINE
void FrameBufferProperties::
435set_force_software(
bool n) {
437 _flags |= FBF_force_software;
439 _flags &= ~FBF_force_software;
441 _flags_specified |= FBF_force_software;
447INLINE
void FrameBufferProperties::
448set_srgb_color(
bool n) {
450 _flags |= FBF_srgb_color;
452 _flags &= ~FBF_srgb_color;
454 _flags_specified |= FBF_srgb_color;
460INLINE
void FrameBufferProperties::
461set_float_color(
bool n) {
463 _flags |= FBF_float_color;
465 _flags &= ~FBF_float_color;
467 _flags_specified |= FBF_float_color;
473INLINE
void FrameBufferProperties::
474set_float_depth(
bool n) {
476 _flags |= FBF_float_depth;
478 _flags &= ~FBF_float_depth;
480 _flags_specified |= FBF_float_depth;
A container for the various kinds of properties we might ask to have on a graphics frameBuffer before...
set_color_bits
Sets the number of requested color bits as a single number that represents the sum of the individual ...
void set_rgba_bits(int r, int g, int b, int a)
Convenience method for setting the red, green, blue and alpha bits in one go.
void output(std::ostream &out) const
Generates a string representation.
get_coverage_samples
If coverage samples are specified, and there is hardware support, we use coverage multisampling.
set_coverage_samples
If coverage samples are specified, and there is hardware support, we use coverage multisampling.