Closed kylebeggs closed 2 weeks ago
I think to fix this we just need to add a convert
in the constructor here (https://github.com/JuliaGeometry/Meshes.jl/blob/master/src/primitives/box.jl#L22) but maybe you guys have a plan on how you are going about converting units. Is it even necessary to have the points of a box be the same units? Perhaps we can relax the type annotation in the struct?
Thanks for catching this! We probably need a conversion method as you suggested, to make sure that both points (min and max) have the same CRS. The main assumption in the current design is that geometries and domains with multiple points must share a unique CRS.
In that case, what unit should we always convert to? meters? How do you design a convert method for this? What if you have mm or cm? Its ambiguous
We used a simple promote call to fix the issue in this algorithm. Promotion rules for geometries is something that we can also consider in the future.
Em ter., 2 de jul. de 2024, 18:04, Kyle Beggs @.***> escreveu:
In that case, what unit should we always convert to? meters? How do you design a convert method for this? What if you have mm or cm? Its ambiguous
— Reply to this email directly, view it on GitHub https://github.com/JuliaGeometry/Meshes.jl/issues/920#issuecomment-2204416153, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAZQW3JQDLY4BWKJT3PJRZDZKMIWBAVCNFSM6AAAAABKIFPRRSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBUGQYTMMJVGM . You are receiving this because you commented.Message ID: @.***>