summaryrefslogtreecommitdiff
path: root/external/collada2gltf
diff options
context:
space:
mode:
authorZolnai Tamás <tamas.zolnai@collabora.com>2014-04-10 13:37:38 +0200
committerMatúš Kukan <matus.kukan@collabora.com>2014-05-13 16:34:49 +0200
commitd575917016f65a7322817a8e13ec25c52d18a600 (patch)
treecb61c65510981ea1cc6f91cb5fe766ecf0ee9aba /external/collada2gltf
parentaa5fe7958d087fbd6e64b29bbf2fa6e4d9ba5ab6 (diff)
Introduce Collada2gltf external library
Change-Id: I157f175ee6ea719e98ba45133f53cb4d2c3045bb
Diffstat (limited to 'external/collada2gltf')
-rw-r--r--external/collada2gltf/GitSHA1.cpp2
-rw-r--r--external/collada2gltf/Makefile14
-rw-r--r--external/collada2gltf/Module_collada2gltf.mk17
-rw-r--r--external/collada2gltf/README4
-rw-r--r--external/collada2gltf/StaticLibrary_collada2gltf.mk100
-rw-r--r--external/collada2gltf/UnpackedTarball_collada2gltf.mk16
6 files changed, 153 insertions, 0 deletions
diff --git a/external/collada2gltf/GitSHA1.cpp b/external/collada2gltf/GitSHA1.cpp
new file mode 100644
index 000000000000..bd2cffe1f375
--- /dev/null
+++ b/external/collada2gltf/GitSHA1.cpp
@@ -0,0 +1,2 @@
+#define GIT_SHA1 "6258611a6a4b4b94b963db5f1fe41c5290be1f87"
+char g_GIT_SHA1[] = GIT_SHA1;
diff --git a/external/collada2gltf/Makefile b/external/collada2gltf/Makefile
new file mode 100644
index 000000000000..569ad8a0ba7a
--- /dev/null
+++ b/external/collada2gltf/Makefile
@@ -0,0 +1,14 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
+
+include $(module_directory)/../../solenv/gbuild/partial_build.mk
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/collada2gltf/Module_collada2gltf.mk b/external/collada2gltf/Module_collada2gltf.mk
new file mode 100644
index 000000000000..789a8cb64530
--- /dev/null
+++ b/external/collada2gltf/Module_collada2gltf.mk
@@ -0,0 +1,17 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_Module_Module,collada2gltf))
+
+$(eval $(call gb_Module_add_targets,collada2gltf,\
+ StaticLibrary_collada2gltf \
+ UnpackedTarball_collada2gltf \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/collada2gltf/README b/external/collada2gltf/README
new file mode 100644
index 000000000000..15060554b103
--- /dev/null
+++ b/external/collada2gltf/README
@@ -0,0 +1,4 @@
+An open-source converter produces glTF assets from COLLADA using OpenCOLLADA.
+
+From:
+[https://github.com/amd/glTF/tree/master/converter/COLLADA2GLTF].
diff --git a/external/collada2gltf/StaticLibrary_collada2gltf.mk b/external/collada2gltf/StaticLibrary_collada2gltf.mk
new file mode 100644
index 000000000000..a25f63d9a5e9
--- /dev/null
+++ b/external/collada2gltf/StaticLibrary_collada2gltf.mk
@@ -0,0 +1,100 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_StaticLibrary_StaticLibrary,collada2gltf))
+
+$(eval $(call gb_StaticLibrary_use_unpacked,collada2gltf,collada2gltf))
+
+$(eval $(call gb_StaticLibrary_use_externals,collada2gltf, \
+ opencollada_parser \
+ png \
+))
+
+$(eval $(call gb_StaticLibrary_set_warnings_not_errors,collada2gltf))
+
+$(eval $(call gb_StaticLibrary_add_defs,collada2gltf,\
+ -DUSE_OPEN3DGC \
+))
+
+ifeq ($(COM),MSC)
+$(eval $(call gb_StaticLibrary_add_defs,collada2gltf,\
+ -D_CRT_SECURE_NO_WARNINGS \
+ -EHsc \
+))
+
+endif
+
+$(eval $(call gb_StaticLibrary_set_generated_cxx_suffix,collada2gltf,cpp))
+
+$(eval $(call gb_StaticLibrary_set_include,collada2gltf,\
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf) \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/assetModifiers \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/convert \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/dependencies/json/include/rapidjson \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/extensions/o3dgc-compression \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/GLTF \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/helpers \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/JSON \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/profiles/webgl-1.0 \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/shaders \
+ $$(INCLUDE) \
+))
+
+$(eval $(call gb_StaticLibrary_add_generated_exception_objects,collada2gltf,\
+ UnpackedTarball/collada2gltf/COLLADA2GLTFWriter \
+ UnpackedTarball/collada2gltf/GitSHA1 \
+ UnpackedTarball/collada2gltf/GLTFOpenCOLLADAUtils \
+ UnpackedTarball/collada2gltf/assetModifiers/GLTFFlipUVModifier \
+ UnpackedTarball/collada2gltf/convert/meshConverter \
+ UnpackedTarball/collada2gltf/convert/animationConverter \
+ UnpackedTarball/collada2gltf/extensions/o3dgc-compression/GLTF-Open3DGC \
+ UnpackedTarball/collada2gltf/GLTF/GLTFAccessor \
+ UnpackedTarball/collada2gltf/GLTF/GLTFAccessorCache \
+ UnpackedTarball/collada2gltf/GLTF/GLTFAsset \
+ UnpackedTarball/collada2gltf/GLTF/GLTFAnimation \
+ UnpackedTarball/collada2gltf/GLTF/GLTFBuffer \
+ UnpackedTarball/collada2gltf/GLTF/GLTFConfig \
+ UnpackedTarball/collada2gltf/GLTF/GLTFEffect \
+ UnpackedTarball/collada2gltf/GLTF/GLTFExtraDataHandler \
+ UnpackedTarball/collada2gltf/GLTF/GLTFInputStream \
+ UnpackedTarball/collada2gltf/GLTF/GLTFMesh \
+ UnpackedTarball/collada2gltf/GLTF/GLTFOutputStream \
+ UnpackedTarball/collada2gltf/GLTF/GLTFPrimitive \
+ UnpackedTarball/collada2gltf/GLTF/GLTFProfile \
+ UnpackedTarball/collada2gltf/GLTF/GLTFSkin \
+ UnpackedTarball/collada2gltf/GLTF/GLTFUtils \
+ UnpackedTarball/collada2gltf/GLTF/GLTFWriter \
+ UnpackedTarball/collada2gltf/helpers/geometryHelpers \
+ UnpackedTarball/collada2gltf/helpers/mathHelpers \
+ UnpackedTarball/collada2gltf/JSON/JSONArray \
+ UnpackedTarball/collada2gltf/JSON/JSONNumber \
+ UnpackedTarball/collada2gltf/JSON/JSONObject \
+ UnpackedTarball/collada2gltf/JSON/JSONString \
+ UnpackedTarball/collada2gltf/JSON/JSONValue \
+ UnpackedTarball/collada2gltf/profiles/webgl-1.0/GLTFWebGL_1_0_Profile \
+ UnpackedTarball/collada2gltf/shaders/commonProfileShaders \
+))
+
+# o3dgc external library compiled from collada2gltf
+$(eval $(call gb_StaticLibrary_set_include,collada2gltf,\
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/dependencies/o3dgc/src/o3dgc_common_lib/inc \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/dependencies/o3dgc/src/o3dgc_decode_lib/inc \
+ -I$(call gb_UnpackedTarball_get_dir,collada2gltf)/dependencies/o3dgc/src/o3dgc_encode_lib/inc \
+ $$(INCLUDE) \
+))
+
+$(eval $(call gb_StaticLibrary_add_generated_exception_objects,collada2gltf,\
+ UnpackedTarball/collada2gltf/dependencies/o3dgc/src/o3dgc_common_lib/src/o3dgcArithmeticCodec \
+ UnpackedTarball/collada2gltf/dependencies/o3dgc/src/o3dgc_common_lib/src/o3dgcTools \
+ UnpackedTarball/collada2gltf/dependencies/o3dgc/src/o3dgc_common_lib/src/o3dgcTriangleFans \
+ UnpackedTarball/collada2gltf/dependencies/o3dgc/src/o3dgc_decode_lib/src/o3dgcDynamicVectorDecoder \
+ UnpackedTarball/collada2gltf/dependencies/o3dgc/src/o3dgc_encode_lib/src/o3dgcDynamicVectorEncoder \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/external/collada2gltf/UnpackedTarball_collada2gltf.mk b/external/collada2gltf/UnpackedTarball_collada2gltf.mk
new file mode 100644
index 000000000000..92bc775e5989
--- /dev/null
+++ b/external/collada2gltf/UnpackedTarball_collada2gltf.mk
@@ -0,0 +1,16 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+$(eval $(call gb_UnpackedTarball_UnpackedTarball,collada2gltf))
+
+$(eval $(call gb_UnpackedTarball_set_tarball,collada2gltf,$(COLLADA2GLTF_TARBALL)))
+
+$(eval $(call gb_UnpackedTarball_add_file,collada2gltf,.,external/collada2gltf/GitSHA1.cpp))
+
+# vim: set noet sw=4 ts=4: