Merge branch 'tizen' into devel/new_mesh
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / devel-api / controls / bloom-view / bloom-view.cpp
1 /*
2  * Copyright (c) 2015 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17
18 // CLASS HEADER
19 #include <dali-toolkit/devel-api/controls/bloom-view/bloom-view.h>
20
21 // INTERNAL INCLUDES
22 #include <dali-toolkit/internal/controls/bloom-view/bloom-view-impl.h>
23
24 namespace Dali
25 {
26
27 namespace Toolkit
28 {
29
30 BloomView::BloomView()
31 {
32 }
33
34 BloomView::~BloomView()
35 {
36 }
37
38 BloomView::BloomView(const BloomView& handle)
39   : Control( handle )
40 {
41 }
42
43 BloomView& BloomView::operator=(const BloomView& rhs)
44 {
45   if( &rhs != this )
46   {
47     Control::operator=(rhs);
48   }
49   return *this;
50 }
51
52 BloomView BloomView::New()
53 {
54   return Internal::BloomView::New();
55 }
56
57 BloomView BloomView::New( const unsigned int numSamples, const float blurBellCurveWidth, const Pixel::Format renderTargetPixelFormat,
58                                         const float downsampleWidthScale, const float downsampleHeightScale)
59 {
60   return Internal::BloomView::New( numSamples, blurBellCurveWidth, renderTargetPixelFormat,
61                                            downsampleWidthScale, downsampleHeightScale);
62 }
63
64 BloomView::BloomView( Internal::BloomView& implementation )
65 : Control( implementation )
66 {
67 }
68
69 BloomView::BloomView( Dali::Internal::CustomActor* internal )
70 : Control( internal )
71 {
72   VerifyCustomActorPointer<Internal::BloomView>(internal);
73 }
74
75 BloomView BloomView::DownCast( BaseHandle handle )
76 {
77   return Control::DownCast<BloomView, Internal::BloomView>(handle);
78 }
79
80 void BloomView::Add(Actor child)
81 {
82   GetImpl(*this).Add(child);
83 }
84
85 void BloomView::Remove(Actor child)
86 {
87   GetImpl(*this).Remove(child);
88 }
89
90 void BloomView::Activate()
91 {
92   GetImpl(*this).Activate();
93 }
94
95 void BloomView::Deactivate()
96 {
97   GetImpl(*this).Deactivate();
98 }
99
100 Property::Index BloomView::GetBloomThresholdPropertyIndex() const
101 {
102   return GetImpl(*this).GetBloomThresholdPropertyIndex();
103 }
104
105 Property::Index BloomView::GetBlurStrengthPropertyIndex() const
106 {
107   return GetImpl(*this).GetBlurStrengthPropertyIndex();
108 }
109
110 Property::Index BloomView::GetBloomIntensityPropertyIndex() const
111 {
112   return GetImpl(*this).GetBloomIntensityPropertyIndex();
113 }
114
115 Property::Index BloomView::GetBloomSaturationPropertyIndex() const
116 {
117   return GetImpl(*this).GetBloomSaturationPropertyIndex();
118 }
119
120 Property::Index BloomView::GetImageIntensityPropertyIndex() const
121 {
122   return GetImpl(*this).GetImageIntensityPropertyIndex();
123 }
124
125 Property::Index BloomView::GetImageSaturationPropertyIndex() const
126 {
127   return GetImpl(*this).GetImageSaturationPropertyIndex();
128 }
129
130 } // namespace Toolkit
131
132 } // namespace Dali