Beschreibung |
---|
Das Makro erstellt ein 3D-Bild von einem 8-bit (256 Farben) BMP-Bild. Mit andern Worten: Es ermöglicht ein 3D-Projekt sehr einfach von einem Bitmap-Bild, das eine Grauskala mit 256 Graustufen verwendet, ausgehend aufzubauen. Ist ein 32-bit BMP-Bild ausgewählt, wird das Bild durch Punkte dargestellt. Das Makro FCCreaLoft Macro Loft wird verwendet, um die mehrfache Loft-Ausführung zu automatisieren. Versionsmakro : 0.15 Datum der letzten Änderung : 2025/01/04 FreeCAD version : 0.18 und neuer Herunterladen : ToolBar-Icon Autor: Mario52 |
Autor |
Mario52 |
Herunterladen |
ToolBar-Icon |
Links |
Makros Rezepte Wie installiere ich Makros So passen Sie Symbolleisten an |
Macro-Version |
0.15 |
Datum der letzten Änderung |
2025/01/04 |
FreeCAD-Version(s) |
0.18 und neuer |
Standardverknüpfung |
None |
Siehe auch |
![]() |
Mit diesem kleinen Makro können Sie aus einem Bitmap-Bild mit 256 Graustufen sehr einfach ein 3D-Projekt erstellen.
Ich hoffe, dass dieses Makro unsere Denkweise beim Modellieren mit CAD und CNC revolutionieren wird, wenn das Konvertieren in 3D-Objekte kaum bis gar keine Eingriffe braucht.
Alles wird möglich, unabhängig von der Komplexität des Bildes!
Das Makro Loft wird zum Automatisieren der Multi-Loft-Operation benutzt.
Temporary code for external macro link. Do not use this code. This code is used exclusively by Addon Manager. Link for optional manual installation: Macro
# This code is copied instead of the original macro code # to guide the user to the online download page. # Use it if the code of the macro is larger than 64 KB and cannot be included in the wiki # or if the RAW code URL is somewhere else in the wiki. from PySide import QtGui, QtCore diag = QtGui.QMessageBox(QtGui.QMessageBox.Information, "Information", "This macro must be downloaded from this link\n" "\n" "https://gist.githubusercontent.com/mario52a/262317bc7d8555885b0e/raw/f18613c8bfd142e644ba79fc8dd34a5f72282f18/Macro%2520FCTexture.FCMacro" + "\n" "\n" "Quit this window to access the download page") diag.setWindowFlags(QtCore.Qt.WindowStaysOnTopHint) diag.setWindowModality(QtCore.Qt.ApplicationModal) diag.exec_() import webbrowser webbrowser.open("https://gist.githubusercontent.com/mario52a/262317bc7d8555885b0e/raw/f18613c8bfd142e644ba79fc8dd34a5f72282f18/Macro%2520FCTexture.FCMacro")
Texture 004 Honda
Dieses Makro benötigt ein Bild mit 256 Graustufen (0-255), daher konvertieren Sie Ihr Bild vor dem Verwenden des Makros in Graustufen (Schwarzweiß). Bei der Ausführung des Makros wird die Anzahl der Farben automatisch erkannt. Hinweis: Falls das Bild mehr als 256 Farben enthält, wird eine andere Funktion erwartet (in Arbeit). Jede Farbe (Graustufe) wird als tiefes, weißes (255) als hoch und schwarz (0) als niedrigster Pegel (tief) angesehen.
Die Konfiguration erfolgt vor dem Öffnen der Datei. Die Standardwerte sind die Einstellungen, um die Dimensionen eines Projekts zu ermitteln:
Die Bilddatei wird wie ein Scanner x1 x2 x3 ... in 1-mm-Schritten in FreeCAD ähnlich dem Wert y von jeweils 1 mm aufgefächert. Der Wert von z ergibt sich aus dem Wert der Farbe. Diese Werte sind im Makro konfigurierbar.
Wichtiger Hinweis: Je nach Größe des Bildes kann das Projekt sehr groß werden! Bspw. ergibt ein Bild mit einer Breite von 100 px und einer Höhe von 100 px 100 x 100 = 10000 Punkte und da jeder Punkt einer Koordinate entspricht, sind es 10000 X-, 10000 Y- und 10000 Z-Koordinaten.
Der Anfangswert des Bedienungswerts passt sich automatisch an die ausgewählte Funktion an: 0, wenn die Einstellung auf Schwarz (Schwarz) 255 oder 20 steht, wenn die Einstellung Weiß ist (Weiß).
true
an (standardmäßig false
).
Macro_Texture.FCMacro
Laden Sie das Makro in Gist herunter Macro FCTexture.FCMacro
The images were inclined to enhance the 3D effect.
Honda
Here with option contour
Here an example of a bmp image converted to points and restoring picture the width of the image is 6.5 nm
thanks for the permission of Yorik
Here an example of a bmp image converted to object 3D of 6.7 nm width.
thanks for the permission of Yorik
The logo of FreeCAD.
A portion of the screen FreeCAD. The file.
A portion of a tablecloth.
A diamond plate.
Mode Plan: the image on the left the white background has been ignored in the right image the colour black has been ignored (an example on the forum)
Topography from a drawing or each level is represented with a degrees of different color.
Image converted in ASCII caracter.
Procedure for create solid:
1: Create loft with the tools or with the
Macro Loft
2: Select all and extrude with the tools
3A: For Linux Download GMSHMesh (author psicofil) Macro_GMSH Wiki page
3B: For Windows Download GmshMesh2.zip unzip the file and install it in your Mod directory (author ulrich1a)
4: Create your Mesh file and use it
Convert solid in mesh with GmshMesh.
Die Diskussion über the forum Um Ihre Eindrücke zu vermitteln oder kontaktieren Sie mich.
Das Makro Macro Loft wird zum Automatisieren der Multi Loft-Operation benutzt.
How to handle pdf import properly and feasibly?
####new2
pathFile = os.path.dirname(SaveName) + "/" #= C:/Provisoire400/
formatFichier = os.path.splitext(SaveName)[1] #= .png
SaveName = os.path.splitext(SaveName)[0] #= /home/kubuntu/.FreeCAD/Macro/Texture_007_H #= C:/Provisoire400/image3D
SaveNameformatFichier = SaveName + formatFichier #= C:/Provisoire400/image3D.png
####new2
FreeCAD.ParamGet("User parameter:BaseApp/Preferences/Macros/FCMmacros/FCTexture").SetString("Path",pathFile)
####new
that causes an error with the version FreeCAD : Version: 0.14.3343 (Git), Python version: 2.7.6, Qt version: 4.8.5