Repository navigation
mcdisplay: filled surfaces at --trace=2 for McStas contrib mirrors - #2956
Merged
Merged
Conversation
Replace line-only MCDISPLAY with polygon() facets, so --trace=2 shows surfaces; --trace=1 keeps outlines. Mirror_Elliptic, Mirror_Parabolic, Mirror_Elliptic_Bispectral, Mirror_Curved_Bispectral, Mirror_conic, SupermirrorFlat (triangle/quad faces; other faces keep lines), FlatEllipse_finite_mirror (both +-w(z) sheets of the conic.h FlatSurf, y in [ll,rl]). Display only, no change to simulation results. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follows #2952, #2953 and #2955: McStas contrib mirrors that only drew lines now emit
polygon()facets, somcdisplay --trace=2shows surfaces. At--trace=1polygons fall back to closed multilines.conic.hFlatSurf (x² = k1+k2z+k3z², y in [ll, rl]) as quad stripsDisplay only: no change to TRACE / simulation results.
Tested (macOS arm64, clang):
mcrun --trace=2and--trace=1 -n 0on Test_FocalisationMirrors, Test_Mirror_conic, Supermirror_thin_substrate, Test_FlatEllipse_finite_mirror plus an ad-hoc instrument for the two Bispectral mirrors; per-component bounding boxes identical to the original line drawings. Not tested: Linux, Windows, GPU, webgl/pyqtgraph.🤖 Generated with Claude Code