gl_engine: fix compile error. accepted/tizen_6.0_unified accepted/tizen_6.0_unified_hotfix tizen_6.0 tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.120901 accepted/tizen/6.0/unified/hotfix/20201103.050014 accepted/tizen/unified/20200928.072819 submit/tizen/20200927.213403 submit/tizen_6.0/20201029.205103 submit/tizen_6.0_hotfix/20201102.192503 submit/tizen_6.0_hotfix/20201103.114803 tizen_6.0.m2_release
authorHermet Park <chuneon.park@samsung.com>
Fri, 25 Sep 2020 04:56:47 +0000 (13:56 +0900)
committerHermet Park <chuneon.park@samsung.com>
Fri, 25 Sep 2020 05:01:42 +0000 (14:01 +0900)
After refactoring header includsion, gl_engine has a break at file dependencies.
now this fixes it.

Change-Id: I876e552392bd330b0c5dfe1821d7bfa046b50af8

17 files changed:
src/lib/gl_engine/tvgGlCommon.h
src/lib/gl_engine/tvgGlGeometry.cpp
src/lib/gl_engine/tvgGlGeometry.h
src/lib/gl_engine/tvgGlGpuBuffer.cpp
src/lib/gl_engine/tvgGlGpuBuffer.h
src/lib/gl_engine/tvgGlProgram.cpp
src/lib/gl_engine/tvgGlProgram.h
src/lib/gl_engine/tvgGlPropertyInterface.cpp
src/lib/gl_engine/tvgGlPropertyInterface.h
src/lib/gl_engine/tvgGlRenderTask.cpp
src/lib/gl_engine/tvgGlRenderTask.h
src/lib/gl_engine/tvgGlRenderer.cpp
src/lib/gl_engine/tvgGlRenderer.h
src/lib/gl_engine/tvgGlRendererProperties.h
src/lib/gl_engine/tvgGlShader.cpp
src/lib/gl_engine/tvgGlShader.h
src/lib/gl_engine/tvgGlShaderSrc.cpp

index 6acee47a28a621371fb964b6abadea49efbe4c29..7c5ba2e687f3ad08dd382e38701b2c7996feb907 100644 (file)
 #ifndef _TVG_GL_COMMON_H_\r
 #define _TVG_GL_COMMON_H_\r
 \r
-#include "tvgCommon.h"\r
 #include <assert.h>\r
+#include <GLES2/gl2.h>\r
+#include "tvgCommon.h"\r
+#include "tvgRender.h"\r
 \r
 \r
 #define GL_CHECK(x) \\r
index e940f26bb32b578819be94c220169cfa148a0ae6..7af492eb67bf57ca80f2b0fba3403dd6bae72f9a 100644 (file)
  * SOFTWARE.
  */
 
+#include <float.h>
 #include "tvgGlGpuBuffer.h"
 #include "tvgGlGeometry.h"
-#include "tvgGlCommon.h"
-
-#include <GLES2/gl2.h>
 
 
 uint32_t GlGeometry::getPrimitiveCount()
index 68dc99d4a3b05f6f618c01446c940174dc5b2201..2fb83f5cdb2be0d127172dedec483c09775b0dd1 100644 (file)
@@ -23,6 +23,8 @@
 #ifndef _TVG_GL_GEOMETRY_H_
 #define _TVG_GL_GEOMETRY_H_
 
+#include <math.h>
+#include <vector>
 #include "tvgGlCommon.h"
 
 class GlPoint
index f4024252ee15608517ada8b3a47510cee9f0b633..9ca680c4cfc5404dd2cf32732d4d019057ec5b36 100644 (file)
  * SOFTWARE.
  */
 
-#include "tvgGlCommon.h"
 #include "tvgGlGpuBuffer.h"
 
-#include <assert.h>
+/************************************************************************/
+/* Internal Class Implementation                                        */
+/************************************************************************/
 
 GlGpuBuffer::GlGpuBuffer()
 {
index e3ed97cf3ad928c6fad26f32ee07c4f798e74aed..bf42941e909d13b41a49384bcfd6f5f207e916b6 100644 (file)
@@ -23,8 +23,7 @@
 #ifndef _TVG_GL_GPU_BUFFER_H_
 #define _TVG_GL_GPU_BUFFER_H_
 
-#include <stdlib.h>
-#include <GLES2/gl2.h>
+#include "tvgGlCommon.h"
 
 class GlGpuBuffer
 {
index 38ed3e1bbe7115994c85a744a6ab7b2eba2bb620..63ee42b6aa705d06678cbf791aad5cf66d5eed18 100644 (file)
  * SOFTWARE.
  */
 
-#include "tvgGlCommon.h"
+#include <iostream>
 #include "tvgGlProgram.h"
 
-#include <GLES2/gl2.h>
 
+/************************************************************************/
+/* Internal Class Implementation                                        */
+/************************************************************************/
 
 uint32_t GlProgram::mCurrentProgram = 0;
 
 
+/************************************************************************/
+/* External Class Implementation                                        */
+/************************************************************************/
+
 unique_ptr<GlProgram> GlProgram::gen(std::shared_ptr<GlShader> shader)
 {
     return make_unique<GlProgram>(shader);
index 730274f668a991257904b0498e62adfa71b4ea0c..173c5cdf5ed3674080c4c09c3ec8b71c4b71b5ff 100644 (file)
 #ifndef _TVG_GL_PROGRAM_H_
 #define _TVG_GL_PROGRAM_H_
 
-#include "tvgGlShader.h"
-
-#include <memory>
 #include <map>
+#include "tvgGlShader.h"
 
 class GlProgram
 {
index ebb1c57bad699f990c919283292059d3783e96e4..af011ebac584a3045a56266488f07c768ef26fe6 100644 (file)
@@ -1,8 +1,38 @@
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
+
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
 #include "tvgGlPropertyInterface.h"
-#include "tvgGlRenderTask.h"
+
+/************************************************************************/
+/* Internal Class Implementation                                        */
+/************************************************************************/
 
 VertexProperty  PropertyInterface::mEmptyProperty;
 
+
+/************************************************************************/
+/* External Class Implementation                                        */
+/************************************************************************/
+
 VertexProperty& PropertyInterface::addProperty(GlRenderTask* rTask, std::shared_ptr<GlProgram> prog, std::string name, uint32_t propFormatSize, VertexProperty::PropertyType propType)
 {
     std::map<int32_t, VertexProperty>* vertexProperty = nullptr;
index c8f309ca5f0b784e549dc389faf4557e4a3de27d..6c09e6dfe6b10afe591413cebf09dedb9a6cc275 100644 (file)
@@ -1,12 +1,30 @@
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
+
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
 #ifndef _TVG_GL_PROPERTY_INTERFACE_H_
 #define _TVG_GL_PROPERTY_INTERFACE_H_
 
-#include "tvgGlRendererProperties.h"
 #include "tvgGlRenderTask.h"
 
-#include <string>
-#include <memory>
-#include <map>
 
 #define ADD_ATTRIBUTE_PROPERTY(var, rtask, prog, varName, formatSize, location) \
     var = &PropertyInterface::addProperty(rtask, prog, varName, formatSize, VertexProperty::PropertyType::ATTRIBUTE); \
index accb957eb76f992ecdcadaca11c7b18296318b8e..fc47416175e96cab8bd43d74f643b79901fc9f81 100644 (file)
@@ -1,12 +1,33 @@
-#include "tvgGlCommon.h"
-#include "tvgGlShaderSrc.h"
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
+
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
 #include "tvgGlRenderTask.h"
+#include "tvgGlShaderSrc.h"
 #include "tvgGlPropertyInterface.h"
 
-#include <memory>
-#include <string>
-#include <GLES2/gl2.h>
 
+/************************************************************************/
+/* External Class Implementation                                        */
+/************************************************************************/
 
 GlRenderTask::GlRenderTask(RenderTypes renderType, shared_ptr<GlShader> shader)
 {
index d4b28e5efef312f557705f36332ccfd8e9b32a77..d753bcc2a6b3a8ce5c54d28ad81575a81c13c998 100644 (file)
@@ -1,14 +1,30 @@
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
+
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
 #ifndef _TVG_GL_RENDER_TASK_H_
 #define _TVG_GL_RENDER_TASK_H_
 
-#include "tvgGlShader.h"
-#include "tvgGlProgram.h"
 #include "tvgGlRendererProperties.h"
 
-#include <string>
-#include <memory>
-#include <map>
-
 #define MAX_GRADIENT_STOPS 4
 
 class GlRenderTask
index 9e63e24a12547f927cb877e4ba4e4a3abda6cf60..896a80be265bb88e7e91f728f00e3464c12e4c26 100644 (file)
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-#include "tvgGlShaderSrc.h"
+
+#include "tvgGlRenderer.h"
 #include "tvgGlGpuBuffer.h"
 #include "tvgGlGeometry.h"
-#include "tvgGlCommon.h"
-#include "tvgGlRenderer.h"
 #include "tvgGlPropertyInterface.h"
 
 /************************************************************************/
@@ -32,6 +31,7 @@
 static bool initEngine = false;
 static uint32_t rendererCnt = 0;
 
+
 static void _termEngine()
 {
     if (rendererCnt > 0) return;
index 79addd64c2f9bdb42687707cc982d547f1627b8e..7d63c5a7b34050de4fdf83ce6d4895b0cc47ade3 100644 (file)
@@ -23,8 +23,6 @@
 #ifndef _TVG_GL_RENDERER_H_
 #define _TVG_GL_RENDERER_H_
 
-#include "tvgGlCommon.h"
-#include "tvgGlProgram.h"
 #include "tvgGlRenderTask.h"
 
 class GlRenderer : public RenderMethod
index dd00923734f108645fabf913544ef23bfa22c95a..9aa56df0611d9d40d1457bd76e288c181abc41fa 100644 (file)
@@ -1,13 +1,31 @@
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
+
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
 #ifndef _TVG_GL_RENDER_PROPERTIES_H_
 #define _TVG_GL_RENDER_PROPERTIES_H_
 
-#include "tvgGlShader.h"
-#include "tvgGlProgram.h"
-
-#include <string>
-#include <memory>
 #include <vector>
-#include <map>
+#include "tvgGlCommon.h"
+#include "tvgGlProgram.h"
 
 class PropertyValue
 {
index 9838393f7ed8913ed1a7b1941a1af63752820127..4d94d918fd384854c22729e03754776ae5de3346 100644 (file)
  * SOFTWARE.
  */
 
-#include "tvgGlCommon.h"
+#include <iostream>
 #include "tvgGlShader.h"
 
-#include <GLES2/gl2.h>
 
+/************************************************************************/
+/* External Class Implementation                                        */
+/************************************************************************/
 
 shared_ptr<GlShader> GlShader::gen(const char* vertSrc, const char* fragSrc)
 {
index 60793e12c9a0a398f4ed259d73857535578cc687..4cb29b6ed5a938b7650dd901e0e50643ad5876d0 100644 (file)
@@ -23,7 +23,7 @@
 #ifndef _TVG_GL_SHADER_H_
 #define _TVG_GL_SHADER_H_
 
-#include <memory>
+#include "tvgGlCommon.h"
 
 class GlShader
 {
index 91c31de0924d638703cb4f693c838c729cd0f3e2..63d796eb150ce3a9754f81d0906a7be2fd6b9d01 100644 (file)
@@ -20,9 +20,8 @@
  * SOFTWARE.
  */
 
-#include "tvgGlShaderSrc.h"
-
 #include <string>
+#include "tvgGlShaderSrc.h"
 
 #define TVG_COMPOSE_SHADER(shader) #shader