Merge base & optional
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / shader-effects / image-region-effect.cpp
index 18bb1c3..ee9b256 100644 (file)
@@ -1,18 +1,19 @@
-//
-// Copyright (c) 2014 Samsung Electronics Co., Ltd.
-//
-// Licensed under the Flora License, Version 1.0 (the License);
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://floralicense.org/license/
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an AS IS BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
 
 #include <dali-toolkit/public-api/shader-effects/image-region-effect.h>
 
@@ -48,11 +49,11 @@ ImageRegionEffect::~ImageRegionEffect()
 ImageRegionEffect ImageRegionEffect::New()
 {
   std::string vertexShader(
-    "uniform vec2 uTopLeft;\n"
-    "uniform vec2 uBottomRight;\n"
+    "uniform mediump vec2 uTopLeft;\n"
+    "uniform mediump vec2 uBottomRight;\n"
     "void main()\n"
     "{\n"
-    "  vec4 position = vec4(aPosition,1.0);\n"
+    "  mediump vec4 position = vec4(aPosition,1.0);\n"
     "  gl_Position = uMvpMatrix * position;\n"
     // The line below is doing the same as the following commented lines:
     //"  vec2 imageSize = sTextureRect.zw - sTextureRect.xy;\n"
@@ -97,4 +98,3 @@ const std::string& ImageRegionEffect::GetBottomRightPropertyName() const
 } // namespace Toolkit
 
 } // namespace Dali
-