Cinema4D to Javascript 3D (using three.js) exporte



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 29/11/2010 at 10:38, xxxxxxxx wrote:

    Hi,
    Don't know if this is the best place to post this on the forum, but here goes:
    I've finished writing a script that exports Polygon meshes to mr.doob's three.js engine(http://github.com/mrdoob/three.js)
    Three.js comes with 3 renderes: CanvasRenderer, SVG Renderer and WebGL renderer.
    Obviously, the WebGL is the fastest, but not all browsers support WebGL at the moment.
    UV Texturing works well with WebGL Renderer, but it's a bit slow with the Canvas renderer,
    which is supported for most browsers. As an alternative for low poly models that work well
    with colours as opposed to complicated textures, there's an option.
    You could assign Materials to Selection tags and the colors will get exported.
    You grab the script from my slightly outdate github branch(https://github.com/orgicus/three.js). There are more details on this on the disturb media blog(http://disturbmedia.com/blog/post/exploring-threejs-part-1-exporting-models-from-cinema-4d-to-javascript/ ) and the wiki(http://www.disturbmedia.com/wiki/index.php/C4D_to_three_js.html)
    There are few Examples too (http://www.disturbmedia.com/wiki/index.php/C4D_to_three_js.html#Examples)


    DeltaInc Designs:

    Big thanks to Sebastian for explaining how to work with Materials and Selections (http://www.py4d.com/forum/?wpforumaction=viewtopic&t=223.0)



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 01/04/2011 at 19:20, xxxxxxxx wrote:

    Oh wow! Seeing this plugin has made my year! Thanks so much for putting this plugin together. One thing though is that I was getting this error when trying to run export_to_three.js in R12:

    Traceback (most recent call last) : File "_<_ex_to_three.js.py_>_", line 41,_<_module_>_ule> ImportError: cannot import name symbols

    tfacWhich happened even on the example project box6.c4d. Do you have any insights on the problem? My thought is that it cannot find cinema.symbols, meaning there was maybe an api change? I du_<_module_<_ex_to_three.js.py_>_hree.js.py>



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 04/04/2011 at 10:54, xxxxxxxx wrote:

    Update on the error: some threads in the forums elluded to the fact that symbols have become absorbed by the c4d object in R12:

    https://plugincafe.maxon.net/topic/5619/5649_symbols-in-r12
    .

    I have updated the export_to_three.js to reflect the new r12 api structure, but have hit roadblocks, particularly the following error: 'c4d.SelectionTag' object has no attribute 'GetSelection' any insights to code or resources would be helpful. I'm happy to see a script like this for C4D and would love to help make it so secksy, that it would be reintegrated into mr. doobs repo. :)



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 04/04/2011 at 10:55, xxxxxxxx wrote:

    oh yeah, here's my fork:

    https://github.com/flyingoctopus/three.js



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 20/05/2011 at 15:12, xxxxxxxx wrote:

    Mighty Vincent!

    Thanks for the hard work; but, I ran the script and I'm still getting the error that you initially mentioned when running R12: line 41 cannot import name symbols.

    Any suggestions?

    Cheers,
    Hoyd



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 20/05/2011 at 16:41, xxxxxxxx wrote:

    The symbols package was part of Py4D which was removed in R12.



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 20/05/2011 at 17:42, xxxxxxxx wrote:

    s_rath, thanks for the quick reply but since I'm a newbie to C4D and Python, I'm not quite sure what I can do to make it work.



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 20/05/2011 at 18:31, xxxxxxxx wrote:

    I removed the symbols package and added it to my fork here:https://github.com/flyingoctopus/three.js

    There are still bugs, but it's 75% there. anybody that knows the new c45d r12 api, help/wisdom on this would be awesome. Cheers!



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 13/11/2012 at 14:03, xxxxxxxx wrote:

    Hi there!  I am getting the following error when I export to three.js:

    AttributeError: 'c4d.PolygonObject' object has no attribute 'GetPos'

    I am running R13....help?



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 14/11/2012 at 02:35, xxxxxxxx wrote:

    Originally posted by xxxxxxxx

    Hi there!  I am getting the following error when I export to three.js:

    AttributeError: 'c4d.PolygonObject' object has no attribute 'GetPos'

    I am running R13....help?

    If you're not afraid by editing the Python script, you can change 'GetPos' with 'GetAbsPos'.


Log in to reply