Blender Real-time Exporter (simple version)

Sometimes, working with tools like Processing or Grasshopper I’ve felt the lack of maneuverability of blender meshes modeling. I therefore decided to develop a small script for export my mesh refreshing it in real-time. This will make it possible to read information from different software programs interactively with the ability to store files prefix.vertices and prefix.faces, containing respectively the vertices and faces of the mesh.
Is also possible to simultaneously export multiple objects with the ability to apply the modifiers before exporting. The export deals only with the mesh, so there are not applied the transformations like translation / rotation / scale of the object.

Following is a brief description of the syntax adopted for export .vertices file:

vertex_01_x vertex_01_y vertex_01_z
vertex_02_x vertex_02_y vertex_02_z
vertex_03_x vertex_03_y vertex_03_z
vertex_04_x vertex_04_y vertex_04_z
vertex_05_x vertex_05_y vertex_05_z

and .faces file:

face_01_vertex_01_ID face_01_vertex_02_ID face_01_vertex_03_ID face_01_vertex_04_ID
face_02_vertex_01_ID face_02_vertex_02_ID face_02_vertex_03_ID face_02_vertex_04_ID
face_03_vertex_01_ID face_03_vertex_02_ID face_03_vertex_03_ID face_03_vertex_04_ID
face_04_vertex_01_ID face_04_vertex_02_ID face_04_vertex_03_ID face_04_vertex_04_ID

In the future, the intention would be to expand export opportunities allowing you to export files with different formats and reporting information about the vertex-colors.

Installation of Blender Real-time Exporter:
Download and open it with blender text editor, press Alt-P for run the script and in Object Data menu it will appear the new panel: Real-time Mesh Exporter.

You can also try the exporter with my simple Processing sketch BlenderToProcessing.pde. I don’t use libraries like toxiclibs or hemesh, but only Processing function beginShape(). So with particular quad faces it gives some errors of visualization.

Happy Blending


Here is an updated versione of the script to blender 2.79: [updated 31/01/2018]]


20 Responses to “Blender Real-time Exporter (simple version)”

  1. Hello. I am wondering if you can help me. I have installed your scripts as you show in your video but I can not see the blender object in the processing window when the script is running.
    Any help please?

    Thank you


  2. hi Marco!
    try to check if the files have been written correctly, opening with your text editor. Then check if the processing path is set for the same directory. Which version of blender / processing do tou use?

  3. which files do you mean for me to check? And I am using Blender 2.6 and processing 2.0.
    thank you

    • Well, the script was deprecated, this is a newer version that I tested with blender 2.65:

      After running the script, in blender intarface you will find the exporter panel inside the “Object Data” menu. Here set the path where you want to save your mesh informations. It is important that you use the same path for both blender and processing. It is a good choice to store information from blender directly inside processing sketch.
      I also updated the .pde file for a small fix. Now it looks directly for files “myMesh.vertices” and “myMesh.faces” inside the sketch folder. (obviously you must use the right name)

  4. it works! 😀
    I think it was the updated script version for blender. But thanks a lot! Its great.

  5. Hello Alessandro 🙂
    You have done such a nice work with this script. Unfortunately I can’t run it. I’m trying to follow your steps in the tutorial you’ve made, but somehow, something is missing. Let’s try again and you will tell me if I’m wrong – step by step.
    So 1-st:
    -> I’m importing .py script to blender (should I save it after, or before that? Curently I’m using the last version of Blender which is 2.69, is that a problem also?)

    -> I already opened processing with the script there, and saved the sketch into the same folder/place with the blend file is. In my case “BlenderToProcessing” sketch folder.
    Now, my question as a begginer in this case is – should I have 2 more files into the same folder, after I run the script(.py) or they should appear in separate folder?), again in my case “.faces”; “.vetices” into same folder.

    -> and at the end
    Thank you again for your time and work imput – developing such script. If I find out how to use it – I will try to collaborate it for my next art work.
    Thank you!

    p.s: The current message from Processing (version 2) is :

    “Framebuffer error (unknown error), rendering will probably not work as expected Read for help.
    OpenGL error 1286 at bot beginDraw(): invalid framebuffer operation
    OpenGL error 1286 at bot endDraw(): invalid framebuffer operation
    Framebuffer error (unknown error), rendering will probably not work as expected Read for help.
    OpenGL error 1286 at top endDraw(): invalid framebuffer operation”.

    • Hi dama! Thank for your feedback. The issues are probably related to the version of both blender and processing. I’ll update both script soon 😉

      • Thank you Alessandro!
        Good luck 🙂

      • Hi Dama,
        I updated the blender script to the version 2.69. I also tested the processing one, and with the latest 2.1.1 it works perfectly.
        Try to run it again.
        Answering to your question regarding the files location, you need to export both files “myMesh.faces” and “myMesh.vertices” directly in the sketch folder. Let me know 😉


      • Thanks Alessandro! 🙂 I do the test soon, and will get back again 🙂 Thank you again

  6. You are welcome!
    Let me know 😉

  7. Hi, thanks a lot for the code, i’ll be sure to reference it on the project i’m working on!

    I was wondering if you know how to color the model that has been imported in processing with something like the mousedragged function? I want it so that I can color the model by treating the mouse cursor like a color pencil, instead of just coloring the whole model immediately with something like say, the fill function.


  8. Is it possible to make animation than just changing step by step?



Inserisci i tuoi dati qui sotto o clicca su un'icona per effettuare l'accesso:


Stai commentando usando il tuo account Chiudi sessione /  Modifica )

Google+ photo

Stai commentando usando il tuo account Google+. Chiudi sessione /  Modifica )

Foto Twitter

Stai commentando usando il tuo account Twitter. Chiudi sessione /  Modifica )

Foto di Facebook

Stai commentando usando il tuo account Facebook. Chiudi sessione /  Modifica )


Connessione a %s...

%d blogger hanno fatto clic su Mi Piace per questo: