OpenGLContextSpecWin.h
1 //##################################################################################################
2 //
3 // Ceetron Desktop Components
4 // Component: Win
5 //
6 // --------------------------------------------------------------------------------------------
7 // Copyright (C) 2013, Ceetron AS
8 // This is UNPUBLISHED PROPRIETARY SOURCE CODE of Ceetron AS. The contents of this file may
9 // not be disclosed to third parties, copied or duplicated in any form, in whole or in part,
10 // without the prior written permission of Ceetron AS.
11 //##################################################################################################
12 
13 #pragma once
14 
15 #include "CeeWin/Base.h"
16 
17 namespace cee {
18 namespace win {
19 
20 
21 //==================================================================================================
22 //
23 // Specification class for creation of a Windows OpenGL context. Currently used for enabling
24 // multi sampling (anti-aliasing) WGL extension, but could be used for more OpenGL context specs
25 // or extensions for increased flexibility.
26 //
27 //==================================================================================================
28 class CEE_WIN_EXPORT OpenGLContextSpecWin
29 {
30 public:
32 
33  void setDefault();
34 
35  void setColorBitsCount(unsigned char count);
36  unsigned char colorBitsCount() const;
37 
38  void setMultiSampling(bool set, int samplesCount = -1);
39  bool multiSampling() const;
40  int samplesCount() const;
41 
42  bool needsWGLExtensions() const;
43 
44 private:
45  unsigned char m_colorBitsCount;
46  bool m_multiSampling;
47  int m_samplesCount;
48 };
49 
50 }
51 }
Namespace cee contains all functionality and structures under the Core component. ...
Definition: AppComponent.cpp:26
Specification class for creation of a Windows OpenGL context.
Definition: OpenGLContextSpecWin.h:28