diff options
author | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2013-02-10 14:17:59 +0400 |
---|---|---|
committer | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2013-02-10 14:17:59 +0400 |
commit | ac9ec06ec121589fedbfeaa10137140b45bfd668 (patch) | |
tree | ab08f9528136f0b8813593b78621f869d98d655e /source/creator | |
parent | 3c064f4553e4be988fe4fcec450b59b935fa3c80 (diff) | |
parent | 63af7068ad17f30a526ccb81fbe74253b064bc89 (diff) |
Merged changes in the trunk up to revision 54421.
Conflicts resolved:
release/datafiles/startup.blend
release/scripts/startup/bl_ui/properties_render.py
source/blender/SConscript
source/blender/blenloader/intern/readfile.c
Diffstat (limited to 'source/creator')
-rw-r--r-- | source/creator/CMakeLists.txt | 4 | ||||
-rw-r--r-- | source/creator/creator.c | 26 |
2 files changed, 19 insertions, 11 deletions
diff --git a/source/creator/CMakeLists.txt b/source/creator/CMakeLists.txt index 4ac8364aa19..8fe7d5e6faf 100644 --- a/source/creator/CMakeLists.txt +++ b/source/creator/CMakeLists.txt @@ -933,7 +933,7 @@ endif() if(WITH_COMPOSITOR) # added for opencl compositor list_insert_before(BLENDER_SORTED_LIBS "bf_blenkernel" "bf_compositor") - list_insert_after(BLENDER_SORTED_LIBS "bf_compositor" "bf_opencl") + list_insert_after(BLENDER_SORTED_LIBS "bf_compositor" "bf_intern_opencl") endif() if(WITH_LIBMV) @@ -986,7 +986,7 @@ endif() endif() if(WITH_BULLET) - list_insert_after(BLENDER_SORTED_LIBS "bf_blenkernel" "bf_rigidbody") + list_insert_after(BLENDER_SORTED_LIBS "bf_blenkernel" "bf_intern_rigidbody") endif() if(WITH_BULLET AND NOT WITH_BULLET_SYSTEM) diff --git a/source/creator/creator.c b/source/creator/creator.c index 5aa0ca51a58..c664ae4540a 100644 --- a/source/creator/creator.c +++ b/source/creator/creator.c @@ -162,7 +162,10 @@ extern char build_system[]; #endif /* Local Function prototypes */ -#ifndef WITH_PYTHON_MODULE +#ifdef WITH_PYTHON_MODULE +int main_python_enter(int argc, const char **argv); +void main_python_exit(void); +#else static int print_help(int argc, const char **argv, void *data); static int print_version(int argc, const char **argv, void *data); #endif @@ -177,10 +180,10 @@ static int print_version(int argc, const char **argv, void *data); /* Initialize callbacks for the modules that need them */ static void setCallbacks(void); -static bool use_crash_handler = true; - #ifndef WITH_PYTHON_MODULE +static bool use_crash_handler = true; + /* set breakpoints here when running in debug mode, useful to catch floating point errors */ #if defined(__linux__) || defined(_WIN32) || defined(OSX_SSE_FPE) static void fpe_handler(int UNUSED(sig)) @@ -549,10 +552,10 @@ static void blender_crash_handler(int signum) char fname[FILE_MAX]; if (!G.main->name[0]) { - BLI_make_file_string("/", fname, BLI_temporary_dir(), "blender.crash.txt"); + BLI_join_dirfile(fname, sizeof(fname), BLI_temporary_dir(), "blender.crash.txt"); } else { - BLI_strncpy(fname, G.main->name, sizeof(fname)); + BLI_join_dirfile(fname, sizeof(fname), BLI_temporary_dir(), BLI_path_basename(G.main->name)); BLI_replace_extension(fname, sizeof(fname), ".crash.txt"); } @@ -925,7 +928,7 @@ static int set_ge_parameters(int argc, const char **argv, void *data) } - } /* if (*(argv[a+1]) == '=') */ + } /* if (*(argv[a + 1]) == '=') */ } return a; @@ -1478,12 +1481,15 @@ int main(int argc, const char **argv) setupArguments(C, ba, &syshandle); BLI_argsParse(ba, 1, NULL, NULL); -#endif if (use_crash_handler) { /* after parsing args */ signal(SIGSEGV, blender_crash_handler); } +#else + G.factory_startup = true; /* using preferences or user startup makes no sense for py-as-module */ + (void)syshandle; +#endif /* after level 1 args, this is so playanim skips RNA init */ RNA_init(); @@ -1494,10 +1500,12 @@ int main(int argc, const char **argv) #if defined(WITH_PYTHON_MODULE) || defined(WITH_HEADLESS) - G.background = 1; /* python module mode ALWAYS runs in background mode (for now) */ + G.background = true; /* python module mode ALWAYS runs in background mode (for now) */ #else /* for all platforms, even windos has it! */ - if (G.background) signal(SIGINT, blender_esc); /* ctrl c out bg render */ + if (G.background) { + signal(SIGINT, blender_esc); /* ctrl c out bg render */ + } #endif /* background render uses this font too */ |