hey, can anyone help me with this import script? i cant remember who made it.
########################################
# Importer for maxscript output #
# from Voodoo camera tracker #
########################################
# Modify the path / filename #
# then ALT-P to start..... #
########################################
# Almost no error checking I'm afraid! #
# It is entirely possible that your #
# computer could explode if you run #
# this script!!!! #
########################################
import Blender
from Blender import *
from math import *
#Change the filename below to the name of your maxscript exported from Voodoo
max_file = 'c:\Camerascript.ms'
sc = Scene.getCurrent()
# Main code
# Open the file specified in max_file
fp = open(max_file)
dt = fp.read()
fp.close()
source = dt.splitlines()
total_lines = len(source)
no_points = 0
ref_points = []
# Now loop through each line in the file
for i in range(total_lines):
line = source[i]
if line[:8] == 'at time ':
pass
# Will fix camera creation later on
#
# Now check for points
if line[:12] == ' point pos:':
# Parse out the three numbers
part1 = line.split("[")
part2 = part1[1].split("]")
part3 = part2[0].split(",")
points = [float(part3[0]),float(part3[1]),float(part3[2])]
ref_points.append(points)
no_points = no_points + 1
ref_mesh = NMesh.New()
# Now create the mesh of reference points
for i in range(no_points):
mypoint = NMesh.Vert(ref_points[i][2],ref_points[i][0]*-1,ref_points[i][1]*-1)
ref_mesh.verts.append(mypoint)
NMesh.PutRaw(ref_mesh, "Reference points")
Blender.Redraw()
no matter where i put the file, blender says “error, check console” and the console says that the file doesnt exist. but it does, it tried it three times in 3 different places
in case it helps, windows xp comp, no 3ds max on it.