blendershell.py updates

This commit is contained in:
Jack Andersen 2015-08-06 09:10:12 -10:00
parent 23bc65c4b9
commit 669c598f4b
7 changed files with 10 additions and 5 deletions

View File

@ -197,7 +197,7 @@ BlenderConnection::BlenderConnection(bool silenceBlender)
}
wchar_t cmdLine[2048];
_snwprintf(cmdLine, 2048, L" --background -P shellscript.py -- %08X %08X",
_snwprintf(cmdLine, 2048, L" --background -P shellscript.py -- %08X %08X",
(uint32_t)m_writepipe[0], (uint32_t)m_readpipe[1]);
STARTUPINFO sinfo = {sizeof(STARTUPINFO)};

View File

@ -150,7 +150,7 @@ public:
static inline BlenderConnection& SharedConnection()
{
if (!SharedBlenderConnection)
SharedBlenderConnection = new BlenderConnection();
SharedBlenderConnection = new BlenderConnection(HECL::VerbosityLevel?false:true);
return *SharedBlenderConnection;
}

View File

@ -3,7 +3,7 @@ import bpy, sys, os, re
ARGS_PATTERN = re.compile(r'''(?:"([^"]+)"|'([^']+)'|(\S+))''')
# Extract pipe file descriptors from arguments
print(sys.argv)
print('HECL Blender Launch', sys.argv)
if '--' not in sys.argv:
bpy.ops.wm.quit_blender()
args = sys.argv[sys.argv.index('--')+1:]

View File

@ -33,7 +33,10 @@ protected:
bool m_good = false;
public:
ToolBase(const ToolPassInfo& info)
: m_info(info) {}
: m_info(info)
{
HECL::VerbosityLevel = info.verbosityLevel;
}
virtual ~ToolBase() {}
virtual HECL::SystemString toolName() const=0;
virtual int run()=0;

@ -1 +1 @@
Subproject commit aeb6089053a46c51b55727e68406bb7577c2e60e
Subproject commit 592c4484e705cf58d15d0b62931df6845b1fcc86

View File

@ -35,6 +35,7 @@
namespace HECL
{
extern unsigned VerbosityLevel;
extern LogVisor::LogModule LogModule;
#if _WIN32 && UNICODE

View File

@ -2,6 +2,7 @@
namespace HECL
{
unsigned VerbosityLevel = 0;
LogVisor::LogModule LogModule("HECL");
void SanitizePath(std::string& path)