material, add new key

A forum to discuss the implementation of a good Materials system in FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
User avatar
bernd
Veteran
Posts: 12849
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

material, add new key

Post by bernd »

I would like to add another key to the materials. It is another stress needed to implement plastic material in FEM. What do I need to do for this?

- add it to the template file /src/Mod/Material/StandardMaterial/TEMPLATE.FCMat https://github.com/FreeCAD/FreeCAD/blob ... LATE.FCMat
- add the new key and the value to the materials
- what else ?!?
User avatar
bernd
Veteran
Posts: 12849
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: material, add new key

Post by bernd »

up
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: material, add new key

Post by PrzemoF »

Sorry, I missed it!!

Scenario B from README [1]. Let me know if you hit any problems, so we can improve the scripts and manual.

B. Adding a property

1. Add the property to headers file and to the TEMPLATE.FCMat file with a description
2. Run ./make_ods.sh to create Materials.ods
3. Edit Materials.ods and fill the values of the new property (empty properties are not written to FCMat files)
3. Run ./make_FCMats.sh to create directory with new FCMat files
4. Copy FCMat files to StandardMaterials directory

[1] https://github.com/FreeCAD/FreeCAD/blob ... ols/README
User avatar
bernd
Veteran
Posts: 12849
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: material, add new key

Post by bernd »

I knew there was something I did not know about :D Thanks Przemo!
Post Reply