-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathduke_osx2021.patch
86 lines (80 loc) · 3.12 KB
/
duke_osx2021.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4033567..326a8e3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -42,5 +42,5 @@ endif()
add_subdirectory(src/duke)
# tests
-add_subdirectory(third_party/gtest-1.7.0)
-add_subdirectory(test)
+# add_subdirectory(third_party/gtest-1.7.0)
+# add_subdirectory(test)
diff --git a/src/duke/CMakeLists.txt b/src/duke/CMakeLists.txt
index 34681ed..2e8122b 100644
--- a/src/duke/CMakeLists.txt
+++ b/src/duke/CMakeLists.txt
@@ -80,13 +80,18 @@ add_definitions(-DDUKE_OIIO)
include_directories(${PC_OIIO_INCLUDE_DIRS})
link_directories(${PC_OIIO_LIBRARY_DIRS})
+pkg_check_modules(PC_OPENEXR REQUIRED OpenEXR)
+include_directories(${PC_OPENEXR_INCLUDE_DIRS})
+link_directories(${PC_OPENEXR_LIBRARY_DIRS})
+
+
#
# LibAv
#
-pkg_check_modules(PC_LIBAV REQUIRED libavformat=55.12.0 libavcodec=55.34.1 libavutil=53.3.0 libswscale=2.1.2)
-add_definitions(-DDUKE_LIBAV)
-include_directories(${PC_LIBAV_INCLUDE_DIRS})
-link_directories(${PC_LIBAV_LIBRARY_DIRS})
+#pkg_check_modules(PC_LIBAV REQUIRED libavformat>=55.12.0 libavcodec>=55.34.1 libavutil>=53.3.0 libswscale>=2.1.2)
+#add_definitions(-DDUKE_LIBAV)
+#include_directories(${PC_LIBAV_INCLUDE_DIRS})
+#link_directories(${PC_LIBAV_LIBRARY_DIRS})
# Fast DPX
add_definitions(-DDUKE_FAST_DPX)
@@ -96,4 +101,4 @@ add_executable(duke ${DUKE_PLUGINS_FILES} main.cpp)
target_link_libraries(duke duke_core)
target_link_libraries(duke ${PC_OIIO_LIBRARIES})
-target_link_libraries(duke ${PC_LIBAV_LIBRARIES})
\ No newline at end of file
+#target_link_libraries(duke ${PC_LIBAV_LIBRARIES})
diff --git a/src/duke/io_plugins/openimageio/OpenImageIO.cpp b/src/duke/io_plugins/openimageio/OpenImageIO.cpp
index 5703eff..479b3d5 100644
--- a/src/duke/io_plugins/openimageio/OpenImageIO.cpp
+++ b/src/duke/io_plugins/openimageio/OpenImageIO.cpp
@@ -122,11 +122,11 @@ class OpenImageIOReader : public IImageReader {
public:
OpenImageIOReader(const char* filename) : m_pImageInput(ImageInput::create(filename)) {
if (!m_pImageInput) {
- m_Error = OpenImageIO::geterror();
+ m_Error = OIIO::geterror();
return;
}
if (!m_pImageInput->open(filename, m_Spec)) {
- m_Error = OpenImageIO::geterror();
+ m_Error = OIIO::geterror();
return;
}
if (m_Spec.depth > 1) {
@@ -207,7 +207,7 @@ class OpenImageIOReader : public IImageReader {
if (options.subimage != 0) return error("plugin does not support subimage yet");
auto description = m_Description.subimages.at(0);
auto data = frame.setDescriptionAndAllocate(description, allocator);
- if (!m_pImageInput->read_image(m_Spec.format, data.begin())) return error(OpenImageIO::geterror());
+ if (!m_pImageInput->read_image(m_Spec.format, data.begin())) return error(OIIO::geterror());
return true;
}
};
diff --git a/third_party/Makefile b/third_party/Makefile
index b2ed535..dc27d37 100644
--- a/third_party/Makefile
+++ b/third_party/Makefile
@@ -175,7 +175,7 @@ libraw.zip:
touch $@
gtest-1.7.0.zip:
- $(CURL) $@ https://googletest.googlecode.com/files/gtest-1.7.0.zip
+ $(CURL) $@ https://github.com/google/googletest/archive/release-1.7.0.zip
touch $@
# clean