Thanks for your interest in contributing to Blender 3MF Format.
This addon provides comprehensive 3MF Core Spec v1.4.0 import/export for Blender 5.0+ (minimum Blender 4.2+), with multi-material paint support for Orca Slicer, BambuStudio, PrusaSlicer, and SuperSlicer. It's a complete modernization of the original add-on (created by Ghostkeeper) with a focus on correctness, spec compliance, and predictable import/export behavior.
Development and issue tracking happens in this repository.
Historical upstream (no longer maintained):
Good contributions include:
- Fixes for Blender 4.2+ / 5.0+ API changes / regressions
- 3MF import/export correctness fixes (especially edge cases)
- Test coverage (unit or integration)
- Documentation improvements (README, API docs, copilot instructions)
- MMU Paint Suite improvements (paint panel, texture handling)
- Small quality-of-life improvements that don't change file semantics
- Triangle Sets / Materials Extension support improvements
Non-goals (usually):
- "Opinionated" transformations of scene data on import/export
- Silent data loss or auto-fixing invalid files without clearly reporting it
- Large refactors without a clear benefit or test coverage
- Breaking changes to the public API (
api.py) without strong justification
Before opening a new issue, please search existing issues first.
When reporting a bug, include:
- Blender version (e.g. 4.2.x LTS / 5.0.x - primary dev version is 5.0)
- OS (Windows/macOS/Linux) and relevant hardware notes
- Steps to reproduce (a minimal, reliable recipe)
- Expected vs actual behavior
- Logs / traceback (copy/paste from the system console, accessible via Window → Toggle System Console)
- If relevant, a minimal .3mf sample file
- For paint/segmentation issues: screenshots of the texture or face colors
If your file contains sensitive data, don't post it publicly. Instead, try to reproduce the issue with a sanitized/minimal file.
Feature requests are welcome, but please keep the scope aligned with the project:
- The add-on's purpose is to load and save 3MF files.
- Changes that modify geometry/materials beyond what the format requires should be kept minimal.
When requesting a feature, describe:
- The user problem being solved
- Why it belongs in the add-on (vs being handled elsewhere)
- Any references to the 3MF spec or examples from other tools
Pull requests are welcome.
- Fork the repo
- Create a feature branch
- Make your changes
- Run tests (see below)
- Open a PR with a clear description and screenshots/files when relevant
This project has unit tests and integration tests. All tests run in real Blender headless mode — no mocking. They require Blender's Python interpreter.
GitHub Actions runs the code-style check and both test suites on every push and pull request. The test matrix uses Ubuntu 24.04 with the latest patch releases of Blender 4.5 LTS, Blender 5.2 LTS, and the latest stable Blender release. Blender downloads are cached by exact version; the latest stable release may coincide with one of the LTS entries.
Windows (PowerShell):
python tests/run_all_tests.pyThis spawns separate Blender processes for unit and integration tests, reporting pass/fail for both suites.
To use a particular Blender installation, pass --blender <path> or set the BLENDER_EXE
environment variable.
Tests for individual functions (colors, segmentation codec, XML parsing, units, etc.) without creating Blender objects:
blender --background --factory-startup --python-exit-code 1 -noaudio -q --python tests/run_unit_tests.pyLocated in tests/unit/
End-to-end tests that create real Blender objects, import/export .3mf files, and validate materials/geometry:
blender --background --factory-startup --python-exit-code 1 -noaudio -q --python tests/run_tests.pyLocated in tests/integration/
Test resources (sample files) are in tests/resources/ and tests/resources/3mf_consortium/
Note: The individual test suites require Blender's Python. The master runner uses system Python
to launch Blender, which must be on your PATH unless --blender or BLENDER_EXE is set.
- Follow Blender's Python style guide
- PEP-8 compatible (
<pep8 compliant>in headers) - Keep changes focused and readable
- Prefer adding tests for bug fixes and behavior changes
Architecture notes:
- Context dataclasses —
ImportContext/ExportContextreplace mutable operator state. All helpers takectxas first arg. - NO
loggingmodule — usecommon.logging(debug(),warn(),error()) exclusively. Python'sloggingdoes nothing in Blender. - NO
print()calls — usedebug()for dev output,warn()/error()for real issues. - Cache Blender strings before XML ops — Python may GC the C string behind
blender_object.name - Blender properties can't start with
_— use3mf_prefix for custom properties - Sub-package imports — use
from ..common import ...for common utilities - See
.github/copilot-instructions.mdfor full architecture documentation
Write meaningful commit messages. Avoid generic messages like “Update file” or “Fix stuff”.
Good examples:
Fix material slot indexing when exporting empty slotsUpdate import operator for Blender 4.2 depsgraph API
Please don't update CHANGELOG.md unless you're asked to. Maintainers will handle release notes.
If you're not ready to code, you can still help by:
- Trying the add-on on your Blender version and reporting results
- Testing PR branches
- Improving docs
- Sharing minimal repro files for tricky import/export bugs