14226 intersection along ijk axis#14341
Open
kriben wants to merge 9 commits into
Open
Conversation
Add a new persistent intersection type that follows the grid pillars at a fixed i, j or k index. Unlike the axis-aligned intersection box, the surface is built from the grid cell faces and therefore steps along faults and curved pillars, which is useful for structural restoration analysis. The user selects the axis, the fixed index, the two perpendicular index ranges and which cell face (front/back pillar) to use. The geometry generator emits the chosen cell face of every cell in the index plane directly from the native pillar corners, so cell result colors map exactly. The feature is available from the Intersections context menu for Eclipse views and supports 3D-view picking and cell result readout.
Left-clicking an IJK intersection surface fell through the pick handler without a matching source info branch, which cleared the current selection instead of showing cell values in Result Info. Add a branch for RivIjkIntersectionSourceInfo mirroring the intersection box handling.
The command was offered on the intersection collection and on IJK intersection nodes, but only copied curve and box intersections: IJK intersections were silently dropped when copying the collection, and the menu entry was permanently disabled when only an IJK intersection was selected. Add copyIjkIntersectionsToOtherViews and include the type in the selection composition, collapsing the per-type-combination enum values into a single SEL_INTERSECTION_ITEMS since empty lists are no-ops.
RicPasteIntersectionsFeature was in the IJK intersection context menu but did not recognize the type: findIntersectionCollection() did not map a selected IJK intersection to its collection, and the clipboard content was never searched for IJK intersections. In addition, RicCopyReferencesToClipboardFeature did not accept the type, so an IJK intersection could not be copied in the first place. Handle RimIjkIntersection in both features, mirroring the box intersection handling.
Cell range filters and the Result Info readout present 1-based grid indices, so showing 0-based indices here was off by one against the rest of the UI. Store 1-based values in the PDM fields so the slider editors display them directly, and convert in the public accessors and setters, which keep using 0-based grid indices. Also fix the stray double space in the range group titles.
The axis-change block claimed to re-center the fixed index but only repeated the clamp performed a few lines above, so remove it. The min/max ordering comment said the field that did not change is adjusted, while the code limits the field that did change; fix the comment to match.
The feature appended with appendIjkIntersectionAndUpdate and set the default values afterwards, which only worked because the scheduled redraw is asynchronous and the part manager is built lazily. It also repeated the updateConnectedEditors and selectAsCurrentItem calls already done by the append. Append without update, set the defaults, then update editors, select the new item and schedule the redraw once. Note that setToDefaultValues() cannot run before the append: it resolves the grid through the parent view, so the intersection must be in the project tree first.
The geometry generator indexes the hex grid with cell indices computed from the view's main grid, but createHexGridInterface() returns a different case's grid when a separate result definition is active, which could cause out-of-bounds reads. Construct the hex grid directly from the view's main grid so both grids are guaranteed to match, and guard against a null hex grid in calculateArrays().
… accessors Replace the six-int-reference ijkRange()/setIjkRange() signatures with a typed 0-based bounding box, making the index basing explicit in the API.
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.
Implements #14226.