Add NativeImageSurface
[platform/core/uifw/dali-adaptor.git] / dali / internal / window-system / macos / native-image-surface-impl-mac.h
1 #pragma once
2
3 /*
4  * Copyright (c) 2021 Samsung Electronics Co., Ltd.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  *
18  */
19
20 // EXTERNAL INCLUDES
21 #include <dali/public-api/object/any.h>
22
23 // INTERNAL INCLUDES
24 #include <dali/devel-api/adaptor-framework/native-image-source-queue.h>
25 #include <dali/internal/window-system/common/native-image-surface-impl.h>
26
27 namespace Dali
28 {
29 namespace Internal
30 {
31 namespace Adaptor
32 {
33 class NativeImageSurfaceCocoa : public Dali::Internal::Adaptor::NativeImageSurface
34 {
35 public:
36   /**
37     * @param [in] queue the NativeImageSourceQueue pointer
38     */
39   NativeImageSurfaceCocoa(Dali::NativeImageSourceQueuePtr queue);
40
41   /**
42    * @brief Destructor
43    */
44   ~NativeImageSurfaceCocoa();
45
46 public:
47   /**
48    * @copydoc Dali::NativeImageSurface::GetNativeRenderable()
49    */
50   Any GetNativeRenderable() override;
51
52   /**
53    * @copydoc Dali::NativeImageSurface::InitializeGraphics()
54    */
55   void InitializeGraphics() override;
56
57   /**
58    * @copydoc Dali::NativeImageSurface::TerminateGraphics()
59    */
60   void TerminateGraphics() override;
61
62   /**
63    * @copydoc Dali::NativeImageSurface::PreRender()
64    */
65   void PreRender() override;
66
67   /**
68    * @copydoc Dali::NativeImageSurface::PostRender()
69    */
70   void PostRender() override;
71
72   /**
73    * @copydoc Dali::NativeImageSurface::CanRender()
74    */
75   bool CanRender() override;
76
77   /**
78    * @copydoc Dali::NativeImageSurface::SetGraphicsConfig()
79    */
80   bool SetGraphicsConfig(bool depth, bool stencil, int msaa, int version) override;
81 };
82
83 } // namespace Adaptor
84 } // namespace Internal
85 } // namespace Dali