Voxel Workbench

Show off your FreeCAD projects here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
yorik
Founder
Posts: 13640
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: Voxel Workbench

Post by yorik »

ok this is fixed! But the videos still appear as a black box...
User avatar
kkremitzki
Veteran
Posts: 2511
Joined: Thu Mar 03, 2016 9:52 pm
Location: Illinois

Re: Voxel Workbench

Post by kkremitzki »

It looks like the file is not actually available via HTTPS on their server. The fix then would be to copy http://phpbbex.com/api/bbmedia.js onto freecadweb.org via FTP and update the forum [video] macro once more to point to wherever you store it, making sure to do it like src="//freecadweb.org/path/to/bbmedia.js"
Like my FreeCAD work? I'd appreciate any level of support via Patreon, Liberapay, or PayPal! Read more about what I do at my blog.
JMG
Posts: 287
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Voxel Workbench

Post by JMG »

I've been playing with coin3d and I have managed to set up a simple "voxelizer" algorithm:

Image

Now I have to work in the selection nodes....

Javier.
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
User avatar
r-frank
Veteran
Posts: 2180
Joined: Thu Jan 24, 2013 6:26 pm
Location: Möckmühl, Germany
Contact:

Re: Voxel Workbench

Post by r-frank »

bernd wrote:Might be a lot of fun if this would be combined with Rolands Anker stones viewtopic.php?f=24&t=10802
Well, there are three "Anker-specific" CAD-Systems out there, for example AnkerCAD.
But they don't export to STL/OBJ which I needed for import and rendering in Kerkythea.
[AnkerCAD exports to POVRay though ...].

By the way:
Searching for voxel CAD's turned up a huge amount of hits ...
At first look, Voxel Builder and Voxel Painter look quite interesting ...
Deutsche FreeCAD Tutorials auf Youtube
My GrabCAD FreeCAD-Projects
FreeCAD lessons for beginners in english

Native german speaker - so apologies for my english, no offense intended :)
JMG
Posts: 287
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Voxel Workbench

Post by JMG »

I have updated the workbench and now is possible to convert from voxels to a normal FreeCAD object:

Video: https://www.youtube.com/watch?v=DQ7plBOnOyg

Github: https://github.com/JMG1/VoxelWorkbench/ ... /README.md


Javier.
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Voxel Workbench

Post by microelly2 »

It would be nice to have the possibility to create a graph of the connected midpoints of the voxels instead of the cube model.
having such a graph it is easy to add special curves (circles, bsplines) on the edges and then loft them together.
JMG
Posts: 287
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Voxel Workbench

Post by JMG »

Hi microelly, if I understood correctly, you need the center points of each cube and the relation between them.

This script will do the first thing, center_points_list contains (x,y,z) center values for each cube in the screen:

Code: Select all

center_points_list = []
bcube = FreeCAD.ActiveDocument.BaseCube
for geom in bcube.GeometryDescriptor:
    center_points_list.append( (geom[1]+0.5,geom[2]+0.5, geom[3]+0.5) )
    
What else would be needed?


Javier.
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Voxel Workbench

Post by microelly2 »

Thats enough for me, thank you.
EDIT
I have combined the outcome with networkx and it works fine.
The voxel cloud and its connectivity structure :)
bp_383.png
bp_383.png (84.21 KiB) Viewed 2802 times
JMG
Posts: 287
Joined: Wed Dec 25, 2013 9:32 am
Location: Spain
Contact:

Re: Voxel Workbench

Post by JMG »

Really nice! :)
FreeCAD scripts, animations, experiments and more: http://linuxforanengineer.blogspot.com.es/
Open source CNC hot wire cutter project (NiCr): https://github.com/JMG1/NiCr
Exploded Assembly Workbench: https://github.com/JMG1/ExplodedAssembly
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Voxel Workbench

Post by microelly2 »

JMG wrote:I've been playing with coin3d and I have managed to set up a simple "voxelizer" algorithm:
Will you add your method to your workbench?
It would be nice to have a way to get a voxel model of a grid point cloud
I create my points clouds by simple boolean commons and image processing with cv2.

https://youtu.be/fP1UyqtkCE8
https://youtu.be/qT8u7NjSZ4c
bp_384.png
bp_384.png (28.28 KiB) Viewed 2776 times
Post Reply