     xmlDoc=new ActiveXObject("Microsoft.XMLDOM")
     xmlDoc.async=false
     xml.loadXML(text)
+
+hermiteSpline = (s, v, t) -> # see http://en.wikipedia.org/wiki/Cubic_Hermite_spline
+  # (2*s^3 - 3*s^2 + 1)*v[0] + (s^3 - 2*s^2 + s)*t[0] + (-2*s^3 + 3*s^2)*v[1] + (s^3-s^2)*t[1]
+  c = [
+    [ 2*Math.pow(s,3) - 3*Math.pow(s,2) + 1, Math.pow(s,3) - 2*Math.pow(s,2) + s ],
+    [ -2*Math.pow(s,3) + 3*Math.pow(s,2), Math.pow(s,3) - Math.pow(s,2) ]
+  ]
+  v[0][i]*c[0][0] + t[0][i]*c[0][1] + v[1][i]*c[1][0] + t[1][i]*c[1][1] for i in [0..2]
 
 base64_encode = (data) ->
   # http://kevin.vanzonneveld.net

        f.normals[i][j] = vN[j] for j in [0..2]

  # Splits the object into 2^16 vert chunks and returns the chunks
  split: () =>
    bytesPerMesh = Math.pow(2,16) # is this even in bytes!?
    bytesPerMesh -= bytesPerMesh % 9 # Rounding the bytes per mesh down to the nearest face


      undefined

    # Scaling the object to mm
    #console.log xml
    unitStr = root.getAttribute("unit") || root.getAttribute("units")
    scale = @_toMillimeters unitStr

    # initializing indice and vert counts
    vertCount = 0; indiceCount = 0
