Mercurial > hg > orthanc-stone
annotate Framework/Scene2D/ICompositor.h @ 905:88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
author | Alain Mazy <alain@mazy.be> |
---|---|
date | Wed, 17 Jul 2019 16:56:53 +0200 |
parents | |
children | 32b403a47b19 |
rev | line source |
---|---|
905
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
1 #pragma once |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
2 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
3 #include <boost/noncopyable.hpp> |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
4 #include <EmbeddedResources.h> |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
5 #include <Core/Enumerations.h> |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
6 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
7 namespace OrthancStone |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
8 { |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
9 class ICompositor : public boost::noncopyable |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
10 { |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
11 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
12 public: |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
13 virtual ~ICompositor() {} |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
14 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
15 virtual unsigned int GetCanvasWidth() const = 0; |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
16 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
17 virtual unsigned int GetCanvasHeight() const = 0; |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
18 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
19 virtual void Refresh() = 0; |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
20 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
21 #if ORTHANC_ENABLE_LOCALE == 1 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
22 virtual void SetFont(size_t index, |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
23 Orthanc::EmbeddedResources::FileResourceId resource, |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
24 unsigned int fontSize, |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
25 Orthanc::Encoding codepage) = 0; |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
26 #endif |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
27 |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
28 }; |
88bf49aebc13
introduced ICompositor and allow SdlViewport to work with a CairoCompositor (to run on machines without OpenGL drivers)
Alain Mazy <alain@mazy.be>
parents:
diff
changeset
|
29 } |