Add RivContourMapElevationProvider and extend RivContourMapProjectionPartMgr so the contour map surface and contour lines can be projected onto the terrain/grid geometry of the 3d view instead of only being drawn as a flat map.
All unnamed critical regions map to the same implicit name, so a single process wide lock was shared by summary import, geometry generation, grid bounding box computation and NNC merging. Unrelated parallel loops therefore serialized against each other.
Give each region a critical_section_ name describing what it protects. The two regions guarding RifOpmCommonEclipseSummary::sm_createdEsmryFileCount deliberately share one name, as they protect the same counter.
The loop was declared with an ordered clause, but the body contains no ordered region, so the clause only enabled the ordered scheduling machinery without providing any ordering. The intended deterministic vertex order was not achieved either, because the actual synchronization was a critical section, which does not preserve iteration order.
Collect vertices in per thread buffers and merge them in thread order after the parallel region, following the pattern already used in RivFaultGeometryGenerator. This removes a lock acquisition per triangle in the innermost polygon loop, and makes the generated geometry identical from run to run.
Use I as the default direction when creating an IJK intersection, and center the fixed index on the I axis.
Allow multiselect of surfaces for a Surface Curve. The field keyword is changed from Surface1 to Surfaces, with a keyword alias so existing project files are read as before. One curve is drawn per selected surface, each with its own label and color.
Use the color defined in the Surfaces collection for Surface Band and Surface Curve. The color is shown as read only, and a Custom Color option allows the user to specify a color. Bands created from an ensemble surface keep the structural uncertainty colors, as the statistics surfaces share the same color.
Remove 95 cvf include lines that the including file does not use. Found by
extracting the symbols declared by every VizFwk header, including symbols they
re-export, and flagging includes where none of those symbols appear anywhere in
the file. Each removal is verified by a full build.
Most of them are cvfVector3.h and cvfObject.h, left behind as the files they
were once needed by changed.
pch.h is left untouched. It includes cvfObject.h and cvfVector3.h on purpose, so
that the files using the precompiled header do not have to.
Note that a clean build after removing an include does not prove the include was
unnecessary, only that the declarations still arrive some other way. That path
can differ between platforms and with RESINSIGHT_ENABLE_UNITY_BUILD, so this
needs a CI round on Linux as well.
cvfBase.h includes cvfAssert.h, so these six files were the last indirect route
into the assert header that the previous commit removed from ApplicationLibCode.
Five files dropped the include with no further change. RimSeismicAlphaMapper
declared alphaValue as returning cvf::ubyte, a typedef defined in cvfBase.h
itself, so no smaller VizFwk header provides it. Since cvf::ubyte is
unsigned char, use that directly in the declaration, the definition and the
cast. The type is identical, so callers are unaffected, and the class no longer
depends on VizFwk at all.
Migrate all assert macros in ApplicationLibCode to CAF_ASSERT and remove every
use of cvfAssert.h.
CVF_ASSERT is replaced one to one. CVF_TIGHT_ASSERT is also replaced by
CAF_ASSERT, which is semantically exact: CVF_ENABLE_TIGHT_ASSERTS is 1 only
under _DEBUG, and that is what CAF_ASSERT now does. The two CVF_FAIL_MSG sites
become CAF_ASSERT( false && "message" ), preserving the message with the idiom
already used elsewhere in the code base.
Counts before and after: CVF_ASSERT 1044 to 0, CVF_TIGHT_ASSERT 66 to 0,
CVF_FAIL_MSG 2 to 0, cvfAssert.h references 154 to 0.
Include handling: files that included cvfAssert.h directly now include
cafAssert.h instead, includes left dead by the migration are removed, and files
that were relying on cvfAssert.h transitively get an explicit cafAssert.h. Files
that reach cafAssert.h through another caf header are left unchanged; a missing
include here is a compile error, not a silently disabled assert.
ResultStatisticsCache links only LibCore and therefore had no path to
cafAssert.h. Add the cafPdmCore directory as a private include path rather than
linking the library, since cafAssert.h is header only.
Note that this stops these asserts from firing in Release and RelWithDebInfo,
where CVF_ASSERT was previously active.
RivSingleCellPartGenerator uses the grid and cell index stored in the 3D
selection item. These are plain indices, and they are not revalidated when
the case data is rebuilt behind a live selection. Both RigMainGrid::gridByIndex()
and RigGridBase::cell() guard only with CVF_ASSERT, so in release builds a stale
index reads out of bounds and the resulting garbage corner indices crash in
RigGridBase::cellCornerVertices().
Validate the grid and cell index before creating the mesh drawable.
The label is moved from the anchor point towards the camera to be drawn in front of other geometry. The offset was derived from the zoom level, and was not related to the distance between the camera and the anchor point. In a 3D view the offset is usually larger than this distance, moving the label behind the camera. Labels outside the view frustum are silently discarded by the text renderer.
Limit the offset to the smaller of half the distance to the anchor point and the distance to the near plane. The limit is derived from the anchor point and not from the near plane, as the label parts are part of the scene and are used to compute the clipping planes.
Reject anchor point candidates behind the camera. Coordinates behind the camera are mirrored into the viewport by the perspective divide in cvf::Camera::project(), and could be selected as the coordinate closest to the label position.
* Add RivSurfaceIntersectionCurveTools for shared surface intersection curve geometry
* Move the surface intersection collection to RimIntersection
* Add surface curtain footprints for the box and i/j/k intersections
* Build surface intersection curves for the box and i/j/k intersections
* Follow the pillar tilt when projecting a surface onto an intersection
* Estimate the surface intersection by continuing the pillar past the curtain
A lateral gets its well path geometry from the parent well, and is
visualized even when it has no active well targets. Building the well
target spheres then calls setVectors() with empty arrays, which asserts.
* #14226 Add intersection along i/j/k axis
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.
A file-based well path whose source file is missing has a null wellPathGeometry(). Add null checks at the remaining call sites that dereferenced it without one, so operations on such a well path no longer crash:
- RimWellPathGroup: skip geometry merging for a child with no geometry (grouping runs on import and project load).
- RimWellPathFracture::computeFractureDirectionNormal: return undefined when geometry is missing.
- RivWellPathPartMgr: extend the existing well path null checks to also require geometry in the attribute, well measurement, and valve append paths.
- RimCompletionCellIntersectionCalc, RicExportLgrFeature, RicCreateMultipleWellPathLaterals, RigLasFileExporter, RiuWellPathComponentPlotItem: guard the geometry before use.
Sites that were already guarded or only reachable through guarded paths were left unchanged.
Well disks are flat, zero-thickness discs drawn at a fixed elevation above each
well head. When the disks of different wells overlap horizontally they end up
coplanar at the same depth and z-fight.
Offset each disk along Z by a small per-well amount derived from the stable
resultWellIndex(), scaled by arrowLength so the spacing tracks the disk scale and
view zoom. Coincident disks fan out into a readable vertical stack instead of
fighting.
Production disks were drawn for wells that the visible-cells filter
hides, because RimSimWellInView::isWellDiskVisible() never consulted
the showWellsIntersectingVisibleCells toggle.
Add a frameIndex parameter and the same active-intersection / visible-
cells filter logic that isWellPipeVisible already uses, and update the
two call sites to pass the current frame.
* CMake: Remove dead CODE_HEADER_FILES variable
* CMake: Remove dead COMMAND_CODE_HEADER_FILES and COMMAND_MOC_SOURCE_FILES
* CMake: Remove dead MOC_SOURCE_FILES and FORM_FILES_CPP references
* CMake: Remove dead HEADER_FILES reference
* CMake: Delete unused CustomPCH.cmake superseded by target_precompile_headers
Introduce RimDataFilterCollection on RimEclipseCase to hold filter
configuration that is shared across all views of the case. Each
RimEclipseView gets a RimDataFilterInViewCollection of
RimDataFilterInView wrappers that auto-sync with the case-level list
and expose an independent on/off toggle per view. The wrapper's
applyToCellVisibility delegates to the wrapped RimCellFilter via the
existing unified virtual, so property, range, and combined filters all
work uniformly.
RimDataFilterCollection is built on caf::PdmObjectCollection<RimCellFilter>
and emits a filtersChanged signal on add/remove/reorder/child changes.
The wrapper collection mirrors RimSurfaceInViewCollection's sync pattern:
new wrappers default to checked, removed sources drop their wrappers,
and the wrapper list follows the case order. Per-view wrappers feed into
RivReservoirViewPartMgr::computePropertyVisibility after the existing
view-level property-filter loop.
The RicNew*Feature commands now route into a selected RimDataFilterCollection,
and the existing combined-filter path is generalized to allow combined
filters living under either a per-view RimEclipsePropertyFilterCollection
or the new case-level collection. Several Asserted ancestor lookups in
RimEclipsePropertyFilter, RimCellFilter and RimEclipseResultDefinition
that assumed a Rim3dView ancestor were relaxed to the non-asserting
variant with graceful fallbacks, so case-level filters can be created
and edited without a host view.
Backwards compatible: empty Data Filter collection is a no-op,
existing per-view RimEclipsePropertyFilterCollection and
RimCellFilterCollection paths are unchanged. GeoMech parity deferred.
Switch the message parameter from const QString& to std::string_view so
callers with std::string in hand no longer need a QString::fromStdString
wrapper. The internal duration formatting still uses QString::arg, fed
from a single QString::fromUtf8 conversion.
Callers passing QString locals are updated with .toStdString() at the
call site.
Robustness fixes in RivPipeGeometryGenerator:
- updateFilteredPipeCenterCoords: drop NaN/Inf input coords. The main loop
now skips iterations where any of the three sampled coords is undefined,
and the trailing endpoint walks back to the last finite coord so the
segment-to-result bookkeeping invariant holds.
- computeExtrudedCoordsAndNormals: stop asserting on parallel plane/ray
intersections (these can occur at very sharp bends due to numerical
issues) and return early when the extruded node count does not match the
expected cross-section node count.
Promote sector-export refinement from inline wizard fields to first-class
PDM objects so users can create, edit, and preview refinement regions in
the 3D view before opening the export dialog.
Add RimCombinedFilter, a node placed under the Eclipse property-filter
collection that holds child filters (cell or property) and combines their
results with a user-chosen AND or OR mode. Supports nesting and is exposed
to Python via the generated rips CombinedFilter class.
To let the same evaluation machinery handle any filter type, introduce a
unified applyToCellVisibility(cellVis, grid, timeStep) virtual on
RimCellFilter with a default implementation that bridges the existing
range/index dispatch. RimEclipsePropertyFilter overrides it with the body
extracted from RivReservoirViewPartMgr::computePropertyVisibility, which
collapses to a generic per-child call and preserves the prior behavior
for ordinary property filters.
Loosen RimEclipsePropertyFilterCollection::m_propertyFilters to
PdmChildArrayField<RimCellFilter*>, keeping the XML tag "PropertyFilters"
and the typed propertyFilters() accessor. Add recursive helpers
(hasActiveEvaluatableDescendant, hasActiveDynamicPropertyDescendant,
hasActiveFormationNamesPropertyDescendant) so hasActiveFilters,
hasActiveDynamicFilters and isUsingFormationNames see property filters
nested inside a combined filter. Bridge filter changes inside a combined
filter to updateDisplayModelNotifyManagedViews, since the property-filter
collection doesn't subscribe to filterChanged signals.
The existing RicNew* cell-filter creation features now route the new child
into a selected combined filter when one is selected, otherwise into the
top-level cell-filter collection as before. The combined filter's context
menu offers the full mixed set: property, polygon, range, index,
user-defined, and nested combined filter.
* #11371 Remove GLEW dependency and use Qt's QOpenGLFunctions
Replace embedded GLEW library with Qt's native OpenGL function loading
(QOpenGLFunctions/QOpenGLExtraFunctions) to resolve Qt 6 compatibility
warnings about GLEW conflicts with qopenglfunctions.h.
- Update CVF_CALLSITE_OPENGL macro to provide QOpenGLExtraFunctions pointer
- Replace GLEW initialization with Qt OpenGL context validation
- Keep direct calls for fixed-function GL (glBegin, glEnd, glMatrixMode, etc.)
- Remove glew/ directory containing embedded GLEW source
* #11371 Remove GLU dependency to fix Windows build error
GL/glu.h conflicts with Qt's OpenGL headers on Windows due to APIENTRY
redefinition. Replace gluBuild2DMipmaps with glTexImage2D + glGenerateMipmap,
and gluOrtho2D with glOrtho.
Migrate all callers to use type-safe ReservoirCellIndex and
ActiveCellIndex wrappers, then remove the deprecated isActive(size_t),
cellResultIndex(size_t), and setCellResultIndex(size_t, size_t) methods.
Remove the redundant wrapper function and update all call sites to use RimWellPathCollection::instance() directly.
Remove unused #include "RimTools.h" from files using RimWellPathCollection::instance() directly
Replace hard transparent/opaque edge cutoff with a weighted alpha
derived from the bilinear corner weights. Pixels at the boundary fade
proportionally to how much of their area falls within the defined
region, eliminating the hard staircase artefact.
Scale texture up 4x and bilinearly interpolate between adjacent vertex
values to eliminate block artefacts. Pixels adjacent to any undefined
(infinity) vertex are rendered transparent.
Extract and clean up prototype from contour-map-01 branch:
- RivContourMapProjectionPartMgr: add appendProjectionAsTexturedQuad(),
createSingleTexturedQuadPart(), createXYPlaneQuadGeoWithTexCoords(),
and createTexture() — renders the map as a single GPU-textured quad
with transparency (alpha=0) for undefined/infinity cells
- RimContourMapProjection: add m_showTextureImage (default true) and
m_showTrianglesWithColor (default false) PDM fields; guard triangle
mesh generation when showTrianglesWithColor() is false
- RimEclipseContourMapView, RimGeoMechContourMapView: branch
appendContourMapProjectionToModel() to use texture or triangle path
based on the new flags; Statistics view inherits Eclipse path
Prototype dead code (debug file save, SurfaceEffectGenerator fallback,
redundant createImage()) not carried forward.
Support (bool, something) pairs as tuples on python side.
Support custom outlet valve md
Add python test for custom outlet valve md
Use tie-in depth as default for custom valve md
Standalone valve creation and display updates
Update MSW valve export
Add valve open/shut flag.
Add python examples
Refactored RimMswSegmentCollection::updateSegments from an instance method to a static method that requires explicit top-level RimWellPath and RimEclipseCase parameters. Updated RimWellPathCollection to collect unique top-level wells and call the new static method.
Add a Color Mode dropdown to surfaces and surface collections that
controls how surfaces are rendered:
- Both: Show surface color and cell result colors
- Surface Color: Show only the uniform surface color
- Cell Result Colors: Show only cell results mapped to surface
Individual surfaces default to inherit from their parent collection but can override with their own setting.
Add a "Show Intersection Geometry" checkbox to RimExtrudedCurveIntersection that
controls visibility of intersection faces and mesh lines independently from the
surface intersection bands and curves.
When unchecked, the intersection geometry is hidden but bands and curves continue
to display based on their individual checked states.
Fixes#13466.
Replaced hardcoded scaling factors for MSW segment radius, marker length, and marker radius with named constants. This improves code readability and maintainability by centralizing visualization parameters for MSW segments and boundary markers.
Introduce support for rendering MSW (Multi-Stage Well) segments in well path visualizations, including alternating color cylinders and boundary markers. Integrate MSW segment display into both regular and flattened geometry builders. Add picking support in the viewer: when an MSW segment is selected, display its properties (segment number, branch, MD range, diameter) and select it in the UI. Also, increase perforation visualization radius for improved clarity.
* Configures automated spell checking with codespell
Adds GitHub workflows and configuration files for automated spell checking using `codespell`.
This includes:
- A workflow for checking pull requests and preventing new typos
- A workflow for automatically fixing typos in the main codebase
- Configuration files for `codespell` to ignore specific terms and file types
- Documentation on how to use and configure the spell checking workflows.
* Corrects minor spelling and grammar errors.
* Add radial display mode to preferences
* Adds isRadial to grid
* Improve mesh lines for radial cells
For temporary radial LGRs, show mesh outline based on the aggregated geometry of all LGRs of the parent cell clicked on.
* Improve warning message
* Modify cell selection in pick event handler
If the angular cell count is low, especially 1, the geometry representation of a cell requires refinement in angular(J) direction. Show this geometry as a cylinder segment when holding CTRL and clicking on the radial geometry.
Refactored RigGridBase::cellCornerVertices to return std::array<cvf::Vec3d, 8> by value instead of taking a reference to std::array as an output parameter. This change improves code readability and leverages modern C++ return value optimizations.
Updated all call sites across the codebase to reflect the new function signature.