1. 05 4月, 2011 1 次提交
    • A
      Added edges computation to OBJ converter. · f7e3a80d
      alteredq 提交于
      If you want to get edges, run converter like with "-e" flag:
      
      python convert_obj_three.py -i model.obj -o model.js -e
      
      Output seems to match Blender exporter.
      f7e3a80d
  2. 04 4月, 2011 3 次提交
    • M
      Merging with alteredq. · abb4a774
      Mr.doob 提交于
      abb4a774
    • A
      Fleshed out more face color pipeline (OBJ converter, Blender importer and loaders). · 00b0f6df
      alteredq 提交于
      - OBJ converter now has "-b" option for baking materials' diffuse colors into face colors
        (if there are morph colormap OBJs/MTLs, first colormap will be used)
        (material will get "vertexColors" property set to "face")
      
      - Blender importer now bakes JSON face colors into Blender vertex colors
      
      - Loader now handles "material.vertexColors" with more options
          - nonexistant property or false will set material to THREE.NoColors
          - "face" will set material to THREE.FaceColors
          - anything else will get THREE.VertexColors
      
      - fixed bug in JSONLoader where face colors were not properly initialized
      00b0f6df
    • A
      Added handling of morph colors to OBJ converter. · df7216e7
      alteredq 提交于
      To be used like this:
      
      python convert_obj_three.py -i model.obj -o model.js -m "morphA_*.obj morphB_*.obj" -c "modelA_colors.obj modelB_colors.obj" -s flat -a none
      df7216e7
  3. 26 3月, 2011 1 次提交
  4. 21 3月, 2011 4 次提交
  5. 02 3月, 2011 1 次提交
  6. 09 11月, 2010 1 次提交
  7. 05 11月, 2010 1 次提交
  8. 04 11月, 2010 1 次提交
    • A
      Added Loader class providing both asynchronous JS and web worker based loading of models. · 5192428f
      alteredq 提交于
      The idea is that later there will be more loaders which would load different formats (like OBJLoader, ColladaLoader).
      
      Usage (async JS):
      
      var loader = new THREE.Loader();
      loader.loadAsync( "obj/torus/Torus.js", function() { createScene( new Torus() ) } );
      
      Usage (web worker):
      
      var loader = new THREE.Loader();
      loader.loadWorker( "obj/torus/Torus_slim.js", function( geometry ) { createScene( geometry ) } );
      
      Web worker loader is useful for large meshes, where it allows browser to stay responsive for longer time and also it can handle larger meshes than async JS loader.
      
      Web worker loader needs a simpler format of the model. Web workers can communicate with the main application only via message passing, where messages are JSON objects.
      
      There is a new version of OBJ -> Three.js converter (convert_obj_threejs_slim.py) which can produce model in format needed for web workers.
      
      All examples which were using models from OBJ converter were refactored to use Loader.
      
      Except large mesh example, all examples are using just async JS loading. Web worker loading is there, it's just commented out, as it's a bit pain for local development.
      
      Chrome doesn't allow to run web workers from pages accessed via file://, so you need either to run it with "--allow-file-access-from-files" flag, or access examples via local server (http://localhost/example.html).
      5192428f