[Bf-python] svg2obj script.

Campbell Barton cbarton at metavr.com
Wed Mar 28 16:56:03 CEST 2007


jmsoler at free.fr wrote:
> Selon Campbell Barton <cbarton at metavr.com>:
> 
>> Also, your using find in a way thats not very readable.
>>
>> if pathname.find(os.sep)!=-1:
>>
>> is better
>> if os.sep in pathname:
>> if ndata.find('-')!=-1 and ndata[ndata.find('-')-1] not in [' ', ',', 'e']:
>>
>> can be
>>
>> if '-' in ndata and ndata[ndata.find('-')-1] not in ' ,e':
>>
>>
> 
> I did a lot of test on a lot of files and for a normal user
> the script works fine, so it is better to do not change anything.
> 
> jms

I understand, but syntax changes can be made with care.

try and make a batch import test. I have some commented out at the 
bottom of the LWO and 3DS importer.

This means you can make changes and then test the script on 100's of 
files, so small errors dont get in. also means you can throw a load of 
files at your importer (1000's even) and see if it chokes on any.



More information about the Bf-python mailing list