Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntony Riakiotakis <kalast@gmail.com>2012-08-22 23:01:09 +0400
committerAntony Riakiotakis <kalast@gmail.com>2012-08-22 23:01:09 +0400
commit7683f87f273884ffc918377608526565c0eb693b (patch)
treedd8ebb8401cf1358abe5a1dcf586cd59cfbd3f94 /source/blender/imbuf/intern/dds
parentb0dd030ba61fe81914d14e520f710684a2406900 (diff)
Fix compilation on MinGW after recent utf 16 fixes (possibly win32 too). gcc ostream does not support wchar_t, I hope it works as expected with unicode filenames.
Diffstat (limited to 'source/blender/imbuf/intern/dds')
-rw-r--r--source/blender/imbuf/intern/dds/CMakeLists.txt1
-rw-r--r--source/blender/imbuf/intern/dds/SConscript3
-rw-r--r--source/blender/imbuf/intern/dds/dds_api.cpp4
3 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/imbuf/intern/dds/CMakeLists.txt b/source/blender/imbuf/intern/dds/CMakeLists.txt
index ae5f1ca9d09..e514b7ab6f9 100644
--- a/source/blender/imbuf/intern/dds/CMakeLists.txt
+++ b/source/blender/imbuf/intern/dds/CMakeLists.txt
@@ -31,6 +31,7 @@ set(INC
../../../blenlib
../../../makesdna
../../../../../intern/guardedalloc
+ ../../../../../intern/utfconv
)
set(INC_SYS
diff --git a/source/blender/imbuf/intern/dds/SConscript b/source/blender/imbuf/intern/dds/SConscript
index 918ae7b530b..4245f5001b9 100644
--- a/source/blender/imbuf/intern/dds/SConscript
+++ b/source/blender/imbuf/intern/dds/SConscript
@@ -11,7 +11,8 @@ incs = ['.',
'../../../blenkernel',
'../../../blenlib',
'intern/include',
- '#/intern/guardedalloc']
+ '#/intern/guardedalloc',
+ '#/intern/utfconv']
defs = ['WITH_DDS']
diff --git a/source/blender/imbuf/intern/dds/dds_api.cpp b/source/blender/imbuf/intern/dds/dds_api.cpp
index 1aaeb4766e1..71313d4438f 100644
--- a/source/blender/imbuf/intern/dds/dds_api.cpp
+++ b/source/blender/imbuf/intern/dds/dds_api.cpp
@@ -32,7 +32,7 @@
#include <stdio.h> // printf
#include <fstream>
-#ifdef WIN32
+#if defined (WIN32) && !defined(FREE_WINDOWS)
#include "utfconv.h"
#endif
@@ -54,7 +54,7 @@ int imb_save_dds(struct ImBuf * ibuf, const char *name, int flags)
/* open file for writing */
std::ofstream fildes;
-#ifdef WIN32
+#if defined (WIN32) && !defined(FREE_WINDOWS)
wchar_t *wname = alloc_utf16_from_8(name, 0);
fildes.open(wname);
free(wname);