Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement 3MF export for multi-color 3D printing of maps #3616

Closed
wants to merge 91 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
91 commits
Select commit Hold shift + click to select a range
f0e38e4
Prototype: multi-color STL export feature
olexandr-savchuk-mw Dec 20, 2023
c0d148b
Multi-color export: group all greys into one (to keep the baseplate a…
olexandr-savchuk-mw Dec 20, 2023
c4d0741
Multi-color export: use openSCAD instead of multi-STL
olexandr-savchuk-mw Mar 12, 2024
a979959
Merge branch 'MaibornWolff:main' into main
olexs Mar 12, 2024
537255e
Add 3MF export
benedikt-mehl-mw Mar 18, 2024
5ca316b
Add baseplate
benedikt-mehl-mw Mar 18, 2024
f6405c4
Add MW logo
benedikt-mehl-mw Mar 20, 2024
7a14765
Add multi colors to map
benedikt-mehl-mw Mar 20, 2024
30c3535
Objects are object parts
benedikt-mehl-mw Mar 20, 2024
85c7b50
WIP
benedikt-mehl-mw Mar 21, 2024
ea929b6
fix: Open edges
benedikt-mehl-mw Mar 21, 2024
0a48b90
fix: model file
benedikt-mehl-mw Mar 21, 2024
ee3d3ad
fix: different colors
benedikt-mehl-mw Mar 21, 2024
7d9140f
fix: open edges
benedikt-mehl-mw Mar 21, 2024
1c23896
chore: move serialize3mf to service file
benedikt-mehl-mw Mar 22, 2024
40de8d5
refactor: serializeGeometries method
benedikt-mehl-mw Mar 22, 2024
9878c9e
feat: Add baseplate
benedikt-mehl-mw Mar 25, 2024
27c63b7
feat: Add fronttext
benedikt-mehl-mw Mar 25, 2024
44f7bb5
feat: Add MW Logo
benedikt-mehl-mw Mar 25, 2024
68af76c
feat: Add print preview
benedikt-mehl-mw Mar 25, 2024
ca1cc73
Merge branch 'main' into feature/3mf-without-jscad to later override …
benedikt-mehl-mw Mar 26, 2024
7222ba1
feat: Check if ColorMode is absolute
benedikt-mehl-mw Mar 26, 2024
5c49c79
feat: Add size slider
benedikt-mehl-mw Mar 27, 2024
4ad55ee
fix: Display correct size
benedikt-mehl-mw Mar 27, 2024
ddadc60
feat: Add textfield to change frontText
benedikt-mehl-mw Mar 27, 2024
bfcc47f
feat: Serializer takes mesh position into account
benedikt-mehl-mw Mar 28, 2024
05ed7f6
feat: Add custom logo upload
benedikt-mehl-mw Mar 28, 2024
769e077
fix: Logo and text have correct height
benedikt-mehl-mw Mar 28, 2024
0b00cfa
feat: Serializer ignores invisible meshs
benedikt-mehl-mw Mar 28, 2024
c3421dc
feat: Consider scale attribute when serializing
benedikt-mehl-mw Mar 28, 2024
dcf412c
feat: Add metrics back print
benedikt-mehl-mw Mar 28, 2024
314c70e
feat: The current Size is calculated only on map and baseplate, so e.…
benedikt-mehl-mw Mar 29, 2024
d18da5b
feat: Add codeChartaLogo to back
benedikt-mehl-mw Mar 29, 2024
47b5186
feat: Add MW logo to back
benedikt-mehl-mw Mar 29, 2024
a28e7f9
feat: Rearrange back print
benedikt-mehl-mw Mar 29, 2024
1080801
feat: Add option to directly change color mode to absolute
benedikt-mehl-mw Mar 29, 2024
c7b2713
refactor: Separate extraction and string building
benedikt-mehl-mw Apr 2, 2024
b30c3b6
feat: Add values to metric text
benedikt-mehl-mw Apr 2, 2024
391747b
feat: Add possibility to serialize child meshes
benedikt-mehl-mw Apr 3, 2024
2f84ef9
fix: Map not serialized correctly
benedikt-mehl-mw Apr 3, 2024
812a7f7
feat: Colored text on back print
benedikt-mehl-mw Apr 3, 2024
c9c7547
refactor: Make preview3DPrintMeshBuilder.ts a class so the font only …
benedikt-mehl-mw Apr 3, 2024
58b79d6
fix: Not serializing baseplate
benedikt-mehl-mw Apr 3, 2024
9e480a8
fix: Children not transformed correctly when serialized
benedikt-mehl-mw Apr 3, 2024
15c6e5d
feat: Add dropdown to select printer
benedikt-mehl-mw Apr 3, 2024
69fb619
feat: Change metadata of 3mf so it can be opened in BambuStudio
benedikt-mehl-mw Apr 3, 2024
7ee8096
feat: Change metadata of 3mf so it can be opened in BambuStudio
benedikt-mehl-mw Apr 3, 2024
bddb98d
refactor: geometryOptions is an attribute now
benedikt-mehl-mw Apr 7, 2024
52c073a
fix: reduce z-fighting of baseplate and back print
benedikt-mehl-mw Apr 7, 2024
3229b10
feat: add border around EVERY colorPicker to also be visible if color…
benedikt-mehl-mw Apr 7, 2024
d0a29fc
feat: add color picker for custom logo
benedikt-mehl-mw Apr 7, 2024
232ded1
feat: custom logo options only visible if a file is chosen
benedikt-mehl-mw Apr 7, 2024
943b285
feat: Shader material can be serialized
benedikt-mehl-mw Apr 7, 2024
b3a6d33
feat: default Shader material is applied to baseplate
benedikt-mehl-mw Apr 8, 2024
f9b28b4
fix: center metrics mesh
benedikt-mehl-mw Apr 8, 2024
eb50b39
fix: svg text not loading correctly
benedikt-mehl-mw Apr 8, 2024
e9b832f
fix: front text not changing
benedikt-mehl-mw Apr 8, 2024
ff79812
feat: colors change according to numberOfColors of selected printer
benedikt-mehl-mw Apr 8, 2024
308459d
feat: backprint fits to selected printer size
benedikt-mehl-mw Apr 8, 2024
d47c3f7
chore: remove jscad depencies
benedikt-mehl-mw Apr 8, 2024
338c175
fix: max map size calculation
benedikt-mehl-mw Apr 8, 2024
f891051
refactor: use functions for color calculation
benedikt-mehl-mw Apr 8, 2024
eceeb4f
refactor: preview3DPrintMesh has printMesh now instead of the dialog
benedikt-mehl-mw Apr 10, 2024
cdeece8
fix: moving of preview Mesh
benedikt-mehl-mw Apr 10, 2024
b761fb5
feat: back print is invisible if there is only one color
benedikt-mehl-mw Apr 10, 2024
25b8f93
refactor: geometryOptions is a parameter instead of an attribute
benedikt-mehl-mw Apr 10, 2024
4830c36
refactor: previewMesh has parts as attributes
benedikt-mehl-mw Apr 12, 2024
0a4f01d
fix: only listen to first color Mode change
benedikt-mehl-mw Apr 12, 2024
2adc73c
test: add test for 3DMapButton
benedikt-mehl-mw Apr 12, 2024
681905e
refactor: printer
benedikt-mehl-mw Apr 12, 2024
94ce1a8
refactor: remove store from 3DMapDialog
benedikt-mehl-mw Apr 12, 2024
57d18c3
test: add first test for 3DMapDialog
benedikt-mehl-mw Apr 12, 2024
c89dfa4
refactor: createScene method for better testing
benedikt-mehl-mw May 2, 2024
909777d
test: add first printMesh test
benedikt-mehl-mw May 2, 2024
5e19fec
feat: download stl exports the previewMeshMap
benedikt-mehl-mw May 2, 2024
24eedf3
fix: error in prusa slicer
benedikt-mehl-mw May 2, 2024
e5f1a3d
fix: snap Map size to fit layer height
benedikt-mehl-mw May 2, 2024
79286ff
fix: back text visible for too long
benedikt-mehl-mw May 2, 2024
9fbdd44
feat: add ITS text
benedikt-mehl-mw May 2, 2024
dbd5a44
refactor: rename some methods
benedikt-mehl-mw May 2, 2024
1389fc2
feat: make XL plate smaller for prime tower
benedikt-mehl-mw May 3, 2024
8d6bd2e
fix: floating floors
benedikt-mehl-mw May 3, 2024
9db7c22
Merge branch 'MaibornWolff:main' into main
olexs May 14, 2024
188b276
Add fflate dependency
olexandr-savchuk-mw May 14, 2024
5a38fc7
Run prettier on export3DMapButton.module.ts
olexandr-savchuk-mw May 14, 2024
8288983
Clean up 3D print export dialog
olexandr-savchuk-mw May 14, 2024
f23af0d
Fix test expectation
olexandr-savchuk-mw May 14, 2024
da6ec4a
Add changelog entry
olexandr-savchuk-mw May 14, 2024
4e7cd15
Fix another test expectation
olexandr-savchuk-mw May 14, 2024
d08abf6
Merge branch 'main' into main
phanlezz May 17, 2024
13c1763
Remove unnecessarily added dependency in root
olexandr-savchuk-mw May 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions visualization/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/)

## [unreleased] (Added 🚀 | Changed | Removed 🗑 | Fixed 🐞 | Chore 👨‍💻 👩‍💻)

### Added 🚀

- Export multi-material 3MF for 3D printing of maps in color [#3616](https://github.com/MaibornWolff/codecharta/pull/3616)

## [1.125.0] - 2024-04-24

### Added 🚀
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,281 changes: 1,281 additions & 0 deletions visualization/app/codeCharta/assets/helvetiker_regular.typeface.json

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions visualization/app/codeCharta/assets/mw_logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
49 changes: 49 additions & 0 deletions visualization/app/codeCharta/assets/mw_logo_text.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
import { Preview3DPrintMesh } from "./preview3DPrintMesh"

jest.mock("three", () => {
const originalModule = jest.requireActual("three")

// Mock FontLoader class
originalModule.FontLoader = jest.fn().mockImplementation(() => {
return {
load: jest.fn((url, onLoad) => {
const mockFont = {} // Replace this with a mock font object if needed
onLoad(mockFont)
})
}
})
return originalModule
})

jest.mock("three/examples/jsm/loaders/SVGLoader", () => {
return jest.fn().mockImplementation(() => {
return {
load: jest.fn((url, onLoad) => {
const mockData = {
paths: [] // Replace this with mock data if needed
}
onLoad(mockData)
})
}
})
})

describe("Preview3DPrintMesh", () => {
let preview3DPrintMesh: Preview3DPrintMesh

beforeEach(() => {
preview3DPrintMesh = new Preview3DPrintMesh()
})

it("should load font without error", async () => {
await expect(preview3DPrintMesh["loadFont"]()).resolves.not.toThrow()
})
})
Loading
Loading