The FileMerger is a utility to combine/merge several photon files into a new one.
This saves a lot of time when you have a lot of photon files of singular miniature models, which you occasionally reprint in different amounts.
- You can off course use ChiTuBox to add all stls, add supports (propbably manual placement is needed, see 3DPrintingPro for tips) and then run Validator to fix all islands to small for supports.
- But if you already have supported and validated photon files per model, with this tool you can combine these photonfiles as you need.
FileMerger is programmed in Python 3.6 and uses the additional libraries Cython (fast compression / mesh calculations), OpenCV (image drawing routines) and numpy (handling large image data).
FileMerger is alpha. There probably are bugs, the output files have not yet been tested on a real photon! Use at your own risk!
You can run FileMerger in Windows, OSX(not tested) and Linux. Your OS must be 64 bit. There is no binary release so you have to install Python3-64bit.
-
Download the source code in zip or tar.gz.
-
Install Python 3-64bit from https://www.python.org/downloads/
or install Anaconda 3.6 https://www.anaconda.com/download/ -
Check if the python version is above 3 and 64 bit by typing in the command line 'python --version'
-
Install the numpy and opencv libraries
- type 'python -m pip install -U numpy --user'
- type 'python -m pip install -U opencv-python --user'
- type 'python -m pip install -U Pillow --user'
-
You have two options to run PhotonFileMerger:
- from your file explorer find and run PhotonFileMerger.py
- from a dos prompt/linux terminal, navigate to the directory where you extracted the zip file and type 'phyton PhotonFileMerger.py' for windows or 'phyton3 PhotonFileMerger.py' for linux.
Attention: PhotonFileMerger will not work with Python 2 or in a 32 bit version of Python!
If you start FileMerger you are presented the following screen:
Toolbar: The buttons at the top allow you start fresh, load files to merge and save the merged file.
File area: The white box on the left lists all photon files you have loaded.
Layout area: The blue box in the middle shows the layout of the merged photon file
Properties area: The grey area on the right shows the print properties of the merged photon file. Per default the properties of the first loaded file are used.
Remarks: You can only merge files which have the same layerheight. The layout area will only allow placement of a source photon file (and show a rectangle) if there is room at the cursor.
Use the load button to load all photon files you want to combine. On each load FileMerger will analyse the photonfile you selected and extract the 3D-model (voxel-area) in it.
If you want to clear all models in the File area, use the new button:
- Select a model in the File area and move your cursor to the Layout area. If the layout area detects there is room at your cursor position, it displays a white rectangle.
- Use the right mouse button to rotate the model 90 degrees.
- Use the left mouse button to drop the model. (You can do this more than once.) A red rectangle appear with a number in the top left indicating the model from the File area.
Remove:
- Move your mouse cursor on top a placed model/red rectangle and use your left mouse button to remove.
Specify a name and FileMerger will construct a new photon file.