From fd448b185ad20c994421d55eebcb62b8e5959950 Mon Sep 17 00:00:00 2001
From: Paul Wisbey
Date: Tue, 28 Mar 2017 19:36:10 +0100
Subject: [PATCH] Port the sparkle effect demo
(Based on original demo by Xiangyin Ma)
Change-Id: I3afe255cea69df3794ffdbafa7171f17f5518dec
---
com.samsung.dali-demo.xml | 3 +
demo/dali-demo.cpp | 1 +
examples/sparkle/sparkle-effect-example.cpp | 568 +++++++++++++++++++++++++
examples/sparkle/sparkle-effect.h | 393 +++++++++++++++++
resources/images/sparkle_normal_background.png | Bin 0 -> 32234 bytes
resources/images/sparkle_particle.png | Bin 0 -> 1095 bytes
resources/po/as.po | 3 +
resources/po/de.po | 3 +
resources/po/en_GB.po | 3 +
resources/po/en_US.po | 3 +
resources/po/es.po | 3 +
resources/po/ko.po | 3 +
resources/po/ml.po | 3 +
resources/po/ur.po | 3 +
resources/po/zn_CH.po | 3 +
shared/dali-demo-strings.h | 2 +
16 files changed, 994 insertions(+)
create mode 100644 examples/sparkle/sparkle-effect-example.cpp
create mode 100644 examples/sparkle/sparkle-effect.h
create mode 100755 resources/images/sparkle_normal_background.png
create mode 100755 resources/images/sparkle_particle.png
diff --git a/com.samsung.dali-demo.xml b/com.samsung.dali-demo.xml
index 3db69ee..843f862 100644
--- a/com.samsung.dali-demo.xml
+++ b/com.samsung.dali-demo.xml
@@ -181,4 +181,7 @@
+
+
+
diff --git a/demo/dali-demo.cpp b/demo/dali-demo.cpp
index cebd1d0..c3d5a6d 100644
--- a/demo/dali-demo.cpp
+++ b/demo/dali-demo.cpp
@@ -80,6 +80,7 @@ int DALI_EXPORT_API main(int argc, char **argv)
demo.AddExample(Example("mesh-visual.example", DALI_DEMO_STR_TITLE_MESH_VISUAL));
demo.AddExample(Example("primitive-shapes.example", DALI_DEMO_STR_TITLE_PRIMITIVE_SHAPES));
demo.AddExample(Example("styling.example", DALI_DEMO_STR_TITLE_STYLING));
+ demo.AddExample(Example("sparkle.example", DALI_DEMO_STR_TITLE_SPARKLE));
demo.AddExample(Example("rendering-line.example", DALI_DEMO_STR_TITLE_RENDERING_DRAW_LINE));
demo.AddExample(Example("rendering-triangle.example", DALI_DEMO_STR_TITLE_RENDERING_DRAW_TRIANGLE));
demo.AddExample(Example("rendering-cube.example", DALI_DEMO_STR_TITLE_RENDERING_DRAW_CUBE));
diff --git a/examples/sparkle/sparkle-effect-example.cpp b/examples/sparkle/sparkle-effect-example.cpp
new file mode 100644
index 0000000..1cc465a
--- /dev/null
+++ b/examples/sparkle/sparkle-effect-example.cpp
@@ -0,0 +1,568 @@
+/*
+ * Copyright (c) 2016 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
+#include
+
+#include
+#include
+#include