export to obj with groups and same mesh
Moderator: oliveroxtoby
Forum rules
and Helpful information for the FEM forum
and Helpful information for the FEM forum
-
- Posts: 4
- Joined: Sat Jan 10, 2015 4:12 pm
Re: export to obj with groups and same mesh
I tested the latest and it worked for me, adding unique names patch0, patch1, etc. The surface is closed, all is fine. Overall this provides a simpler, more robust way of labelling regions of the surface in the obj file than the earlier approaches. It is really great, thanks, it gives us something we can promote in conjunction with meshing in OpenFOAM.
The only possible improvement is if the user can specify their own group names, rather than using defaults patch0, patch1, etc. I guess that would mean somehow "attaching" them to the colour selection. It would be interesting to know if that is unrealistic based on the underlying code.
Again, thanks (wmayer, bernd) for putting this into FreeCAD, it is appreciated.
The only possible improvement is if the user can specify their own group names, rather than using defaults patch0, patch1, etc. I guess that would mean somehow "attaching" them to the colour selection. It would be interesting to know if that is unrealistic based on the underlying code.
Again, thanks (wmayer, bernd) for putting this into FreeCAD, it is appreciated.
Re: export to obj with groups and same mesh
I would just leave the default names patch0, ... when creating the mesh and then offer a function in the mesh workbench where these names can be changed.The only possible improvement is if the user can specify their own group names, rather than using defaults patch0, patch1, etc. I guess that would mean somehow "attaching" them to the colour selection. It would be interesting to know if that is unrealistic based on the underlying code.
Re: export to obj with groups and same mesh
Does it mean the segments off the mesh have names in FreeCAD mesh data structure already? I thought the names where given to the segments (groups) during export.wmayer wrote:I would just leave the default names patch0, ... when creating the mesh and then offer a function in the mesh workbench where these names can be changed.The only possible improvement is if the user can specify their own group names, rather than using defaults patch0, patch1, etc. I guess that would mean somehow "attaching" them to the colour selection. It would be interesting to know if that is unrealistic based on the underlying code.
Re: export to obj with groups and same mesh
Yes.Does it mean the segments off the mesh have names in FreeCAD mesh data structure already?
On export a new mesh is created. If the selected mesh feature already has segments then they are copied over to the new mesh. If not then the whole mesh is added as segment and its label is used as group name.I thought the names where given to the segments (groups) during export.
Re: export to obj with groups and same mesh
But there is no python API to neither read or write the name off a segment. Or at least I could not found a method which returns the name?!wmayer wrote:Yes.Does it mean the segments off the mesh have names in FreeCAD mesh data structure already?
Re: export to obj with groups and same mesh
The naming of segments and the flag to mark them for export is something that has been added recently. The Python API hasn't been adjusted.But there is no python API to neither read or write the name off a segment. Or at least I could not found a method which returns the name?!
Re: export to obj with groups and same mesh
Shall we open a feature Request in the tracker?
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Re: export to obj with groups and same mesh
IMHO: As long as noone explizit ask for it no.
Re: export to obj with groups and same mesh
Hello all,
I'm currently struggling with this issue, and I'm still unable to achieve the single mesh with multiple groups .obj file.
For my particular case, I have a wing.obj file with a single group, that I need to split into 3 different groups. So far I've been able to split the original .obj into 3 different .objs, but if I try to export them all together only one group is created. I've also tried to convert the .obj into a solid object, and using the colour hack, convert it back into a mesh. But this does not work either since the checkbox to "Define segments by face colors" does not show up, and the end result only has 1 group.
I'm running free cad v0.16 on ubunto 17.10.
Any help would be very welcome.
I'm currently struggling with this issue, and I'm still unable to achieve the single mesh with multiple groups .obj file.
For my particular case, I have a wing.obj file with a single group, that I need to split into 3 different groups. So far I've been able to split the original .obj into 3 different .objs, but if I try to export them all together only one group is created. I've also tried to convert the .obj into a solid object, and using the colour hack, convert it back into a mesh. But this does not work either since the checkbox to "Define segments by face colors" does not show up, and the end result only has 1 group.
I'm running free cad v0.16 on ubunto 17.10.
Any help would be very welcome.
Re: export to obj with groups and same mesh
First start with 0.17 and second https://forum.freecadweb.org/viewtopic.php?f=3&t=2264