00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 INLINE FrameBufferProperties::
00022 FrameBufferProperties(const FrameBufferProperties ©) {
00023 (*this) = copy;
00024 }
00025
00026
00027
00028
00029
00030
00031 INLINE FrameBufferProperties::
00032 ~FrameBufferProperties() {
00033 }
00034
00035
00036
00037
00038
00039
00040 INLINE bool FrameBufferProperties::
00041 operator != (const FrameBufferProperties &other) const {
00042 return !operator == (other);
00043 }
00044
00045
00046
00047
00048
00049
00050 INLINE bool FrameBufferProperties::
00051 is_single_buffered() const {
00052 return (_property[FBP_back_buffers] == 0);
00053 }
00054
00055
00056
00057
00058
00059
00060 INLINE bool FrameBufferProperties::
00061 is_stereo() const {
00062 return (_property[FBP_stereo] != 0);
00063 }
00064
00065
00066
00067
00068
00069
00070 INLINE ostream &
00071 operator << (ostream &out, const FrameBufferProperties &properties) {
00072 properties.output(out);
00073 return out;
00074 }
00075
00076
00077
00078
00079
00080
00081 INLINE int FrameBufferProperties::
00082 get_depth_bits() const {
00083 return _property[FBP_depth_bits];
00084 }
00085
00086
00087
00088
00089
00090
00091 INLINE int FrameBufferProperties::
00092 get_color_bits() const {
00093 return _property[FBP_color_bits];
00094 }
00095
00096
00097
00098
00099
00100
00101 INLINE int FrameBufferProperties::
00102 get_alpha_bits() const {
00103 return _property[FBP_alpha_bits];
00104 }
00105
00106
00107
00108
00109
00110
00111 INLINE int FrameBufferProperties::
00112 get_stencil_bits() const {
00113 return _property[FBP_stencil_bits];
00114 }
00115
00116
00117
00118
00119
00120
00121 INLINE int FrameBufferProperties::
00122 get_accum_bits() const {
00123 return _property[FBP_accum_bits];
00124 }
00125
00126
00127
00128
00129
00130
00131 INLINE int FrameBufferProperties::
00132 get_aux_rgba() const {
00133 return _property[FBP_aux_rgba];
00134 }
00135
00136
00137
00138
00139
00140
00141 INLINE int FrameBufferProperties::
00142 get_aux_hrgba() const {
00143 return _property[FBP_aux_hrgba];
00144 }
00145
00146
00147
00148
00149
00150
00151 INLINE int FrameBufferProperties::
00152 get_aux_float() const {
00153 return _property[FBP_aux_float];
00154 }
00155
00156
00157
00158
00159
00160
00161 INLINE int FrameBufferProperties::
00162 get_multisamples() const {
00163 return _property[FBP_multisamples];
00164 }
00165
00166
00167
00168
00169
00170
00171
00172 INLINE int FrameBufferProperties::
00173 get_coverage_samples() const {
00174 return _property[FBP_coverage_samples];
00175 }
00176
00177
00178
00179
00180
00181
00182 INLINE int FrameBufferProperties::
00183 get_back_buffers() const {
00184 return _property[FBP_back_buffers];
00185 }
00186
00187
00188
00189
00190
00191
00192 INLINE int FrameBufferProperties::
00193 get_indexed_color() const {
00194 return _property[FBP_indexed_color];
00195 }
00196
00197
00198
00199
00200
00201
00202 INLINE int FrameBufferProperties::
00203 get_rgb_color() const {
00204 return _property[FBP_rgb_color];
00205 }
00206
00207
00208
00209
00210
00211
00212 INLINE int FrameBufferProperties::
00213 get_stereo() const {
00214 return _property[FBP_stereo];
00215 }
00216
00217
00218
00219
00220
00221
00222 INLINE int FrameBufferProperties::
00223 get_force_hardware() const {
00224 return _property[FBP_force_hardware];
00225 }
00226
00227
00228
00229
00230
00231
00232 INLINE int FrameBufferProperties::
00233 get_force_software() const {
00234 return _property[FBP_force_software];
00235 }
00236
00237
00238
00239
00240
00241
00242 INLINE void FrameBufferProperties::
00243 set_depth_bits(int n) {
00244 _property[FBP_depth_bits] = n;
00245 _specified[FBP_depth_bits] = true;
00246 }
00247
00248
00249
00250
00251
00252
00253 INLINE void FrameBufferProperties::
00254 set_color_bits(int n) {
00255 _property[FBP_color_bits] = n;
00256 _specified[FBP_color_bits] = true;
00257 }
00258
00259
00260
00261
00262
00263
00264 INLINE void FrameBufferProperties::
00265 set_alpha_bits(int n) {
00266 _property[FBP_alpha_bits] = n;
00267 _specified[FBP_alpha_bits] = true;
00268 }
00269
00270
00271
00272
00273
00274
00275 INLINE void FrameBufferProperties::
00276 set_stencil_bits(int n) {
00277 _property[FBP_stencil_bits] = n;
00278 _specified[FBP_stencil_bits] = true;
00279 }
00280
00281
00282
00283
00284
00285
00286 INLINE void FrameBufferProperties::
00287 set_accum_bits(int n) {
00288 _property[FBP_accum_bits] = n;
00289 _specified[FBP_accum_bits] = true;
00290 }
00291
00292
00293
00294
00295
00296
00297 INLINE void FrameBufferProperties::
00298 set_aux_rgba(int n) {
00299 nassertv(n < 4);
00300 _property[FBP_aux_rgba] = n;
00301 _specified[FBP_aux_rgba] = true;
00302 }
00303
00304
00305
00306
00307
00308
00309 INLINE void FrameBufferProperties::
00310 set_aux_hrgba(int n) {
00311 nassertv(n < 4);
00312 _property[FBP_aux_hrgba] = n;
00313 _specified[FBP_aux_hrgba] = true;
00314 }
00315
00316
00317
00318
00319
00320
00321 INLINE void FrameBufferProperties::
00322 set_aux_float(int n) {
00323 nassertv(n < 4);
00324 _property[FBP_aux_float] = n;
00325 _specified[FBP_aux_float] = true;
00326 }
00327
00328
00329
00330
00331
00332
00333 INLINE void FrameBufferProperties::
00334 set_multisamples(int n) {
00335 _property[FBP_multisamples] = n;
00336 _specified[FBP_multisamples] = true;
00337 }
00338
00339
00340
00341
00342
00343
00344
00345 INLINE void FrameBufferProperties::
00346 set_coverage_samples(int n) {
00347 _property[FBP_coverage_samples] = n;
00348 _specified[FBP_coverage_samples] = true;
00349 }
00350
00351
00352
00353
00354
00355
00356 INLINE void FrameBufferProperties::
00357 set_back_buffers(int n) {
00358 _property[FBP_back_buffers] = n;
00359 _specified[FBP_back_buffers] = true;
00360 }
00361
00362
00363
00364
00365
00366
00367 INLINE void FrameBufferProperties::
00368 set_indexed_color(int n) {
00369 _property[FBP_indexed_color] = n;
00370 _specified[FBP_indexed_color] = true;
00371 }
00372
00373
00374
00375
00376
00377
00378 INLINE void FrameBufferProperties::
00379 set_rgb_color(int n) {
00380 _property[FBP_rgb_color] = n;
00381 _specified[FBP_rgb_color] = true;
00382 }
00383
00384
00385
00386
00387
00388
00389 INLINE void FrameBufferProperties::
00390 set_stereo(int n) {
00391 _property[FBP_stereo] = n;
00392 _specified[FBP_stereo] = true;
00393 }
00394
00395
00396
00397
00398
00399
00400 INLINE void FrameBufferProperties::
00401 set_force_hardware(int n) {
00402 _property[FBP_force_hardware] = n;
00403 _specified[FBP_force_hardware] = true;
00404 }
00405
00406
00407
00408
00409
00410
00411 INLINE void FrameBufferProperties::
00412 set_force_software(int n) {
00413 _property[FBP_force_software] = n;
00414 _specified[FBP_force_software] = true;
00415 }