[cgkit-commits] SF.net SVN: cgkit:[303] cgkit/trunk/cgkit/tool.py
Brought to you by:
mbaas
From: <mb...@us...> - 2009-04-26 18:11:14
|
Revision: 303 http://cgkit.svn.sourceforge.net/cgkit/?rev=303&view=rev Author: mbaas Date: 2009-04-26 18:11:03 +0000 (Sun, 26 Apr 2009) Log Message: ----------- Passing the resolution on the command line didn't work because it was treated as a string. Modified Paths: -------------- cgkit/trunk/cgkit/tool.py Modified: cgkit/trunk/cgkit/tool.py =================================================================== --- cgkit/trunk/cgkit/tool.py 2009-04-07 21:39:56 UTC (rev 302) +++ cgkit/trunk/cgkit/tool.py 2009-04-26 18:11:03 UTC (rev 303) @@ -364,6 +364,12 @@ Returns a tuple (width, height, pixel aspect) """ res = getScene().getGlobal("resolution", (640,480)) + # If the resolution is a string, try to evaluate it + if isinstance(res, basestring): + try: + res = eval(res) + except: + pass try: if len(res)==2: w,h = res This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |