2015-04-20 02:02:33 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2015- Statoil ASA
|
|
|
|
// Copyright (C) 2015- Ceetron Solutions AS
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2015-04-20 02:02:33 -05:00
|
|
|
// ResInsight is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2015-04-20 02:02:33 -05:00
|
|
|
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
2015-04-20 02:02:33 -05:00
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2018-01-16 02:37:08 -06:00
|
|
|
#include "RimGridView.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
|
2015-04-20 02:02:33 -05:00
|
|
|
#include "cafAppEnum.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
#include "cafPdmChildField.h"
|
|
|
|
#include "cafPdmField.h"
|
2019-09-06 03:40:57 -05:00
|
|
|
#include "cafPdmFieldCvfColor.h"
|
|
|
|
#include "cafPdmFieldCvfMat4d.h"
|
2015-07-31 11:58:23 -05:00
|
|
|
#include "cafPdmObject.h"
|
|
|
|
#include "cafPdmPointer.h"
|
2015-04-20 02:02:33 -05:00
|
|
|
|
2015-04-27 06:51:22 -05:00
|
|
|
#include "cvfObject.h"
|
|
|
|
|
2015-07-31 11:58:23 -05:00
|
|
|
class RigFemPart;
|
2018-04-25 01:14:48 -05:00
|
|
|
class RigFemPartCollection;
|
2015-04-20 02:02:33 -05:00
|
|
|
class Rim3dOverlayInfoConfig;
|
2015-07-31 11:58:23 -05:00
|
|
|
class RimCellRangeFilterCollection;
|
2015-04-27 06:51:22 -05:00
|
|
|
class RimGeoMechCase;
|
2015-07-31 11:58:23 -05:00
|
|
|
class RimGeoMechCellColors;
|
|
|
|
class RimGeoMechPropertyFilterCollection;
|
2018-04-25 01:14:48 -05:00
|
|
|
class RimGeoMechResultDefinition;
|
|
|
|
class RimRegularLegendConfig;
|
2018-02-05 02:28:16 -06:00
|
|
|
class RimTensorResults;
|
2015-07-31 11:58:23 -05:00
|
|
|
class RiuViewer;
|
2015-04-27 06:51:22 -05:00
|
|
|
class RivGeoMechPartMgr;
|
2015-05-22 10:01:59 -05:00
|
|
|
class RivGeoMechVizLogic;
|
2018-02-08 09:43:12 -06:00
|
|
|
class RivTensorResultPartMgr;
|
2015-05-21 08:39:44 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
namespace cvf
|
|
|
|
{
|
|
|
|
class CellRangeFilter;
|
|
|
|
class Transform;
|
|
|
|
} // namespace cvf
|
2015-04-20 02:02:33 -05:00
|
|
|
|
|
|
|
//==================================================================================================
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
|
|
|
///
|
2015-04-20 02:02:33 -05:00
|
|
|
//==================================================================================================
|
2018-01-12 07:12:31 -06:00
|
|
|
class RimGeoMechView : public RimGridView
|
2015-04-20 02:02:33 -05:00
|
|
|
{
|
2015-05-08 03:38:10 -05:00
|
|
|
CAF_PDM_HEADER_INIT;
|
2015-04-20 02:02:33 -05:00
|
|
|
|
|
|
|
public:
|
2019-09-06 03:40:57 -05:00
|
|
|
RimGeoMechView( void );
|
|
|
|
~RimGeoMechView( void ) override;
|
2015-04-20 02:02:33 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setGeoMechCase( RimGeoMechCase* gmCase );
|
|
|
|
RimGeoMechCase* geoMechCase() const;
|
|
|
|
RimCase* ownerCase() const override;
|
2015-04-30 07:19:43 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmChildField<RimGeoMechCellColors*> cellResult;
|
|
|
|
RimGeoMechResultDefinition* cellResultResultDefinition() const;
|
2015-08-27 15:54:37 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
const RimPropertyFilterCollection* propertyFilterCollection() const override;
|
2015-11-12 03:48:13 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
RimGeoMechPropertyFilterCollection* geoMechPropertyFilterCollection();
|
|
|
|
const RimGeoMechPropertyFilterCollection* geoMechPropertyFilterCollection() const;
|
|
|
|
void setOverridePropertyFilterCollection( RimGeoMechPropertyFilterCollection* pfc );
|
2015-04-20 02:02:33 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
bool isTimeStepDependentDataVisible() const override;
|
2015-04-20 02:02:33 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
cvf::Transform* scaleTransform() override;
|
|
|
|
void scheduleGeometryRegen( RivCellSetEnum geometryType ) override;
|
|
|
|
void updateIconStateForFilterCollections();
|
2015-07-01 05:07:01 -05:00
|
|
|
|
2019-11-01 04:13:32 -05:00
|
|
|
void defineAxisLabels( cvf::String* xLabel, cvf::String* yLabel, cvf::String* zLabel ) override;
|
2015-11-23 00:24:50 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
bool isUsingFormationNames() const override;
|
2016-09-12 04:36:59 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void calculateCurrentTotalCellVisibility( cvf::UByteArray* totalVisibility, int timeStep ) override;
|
2017-08-24 02:27:08 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void updateLegendTextAndRanges( RimRegularLegendConfig* legendConfig, int timeStepIndex );
|
2018-02-01 10:45:22 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
const cvf::ref<RivGeoMechVizLogic> vizLogic() const;
|
|
|
|
const RimTensorResults* tensorResults() const;
|
|
|
|
RimTensorResults* tensorResults();
|
2018-02-08 09:43:12 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
std::vector<RimLegendConfig*> legendConfigs() const override;
|
2018-04-18 03:32:51 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
const RigFemPartCollection* femParts() const;
|
|
|
|
RigFemPartCollection* femParts();
|
2018-04-25 01:14:48 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void convertCameraPositionFromOldProjectFiles();
|
2018-05-18 12:23:36 -05:00
|
|
|
|
2015-10-19 05:10:18 -05:00
|
|
|
protected:
|
2019-09-06 03:40:57 -05:00
|
|
|
void defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering ) override;
|
|
|
|
void defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering, QString uiConfigName = "" ) override;
|
|
|
|
void onLoadDataAndUpdate() override;
|
2020-02-12 04:43:15 -06:00
|
|
|
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
|
2019-10-09 02:21:28 -05:00
|
|
|
void initAfterRead() override;
|
2019-09-06 03:40:57 -05:00
|
|
|
|
2019-10-31 09:32:30 -05:00
|
|
|
void onCreateDisplayModel() override;
|
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
RimPropertyFilterCollection* nativePropertyFilterCollection();
|
2018-12-14 06:41:35 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
private:
|
|
|
|
QString createAutoName() const override;
|
2015-05-22 10:01:59 -05:00
|
|
|
|
2019-10-31 09:32:30 -05:00
|
|
|
void onUpdateScaleTransform() override;
|
2015-05-08 03:38:10 -05:00
|
|
|
|
2019-11-08 03:39:40 -06:00
|
|
|
void onClampCurrentTimestep() override;
|
|
|
|
size_t onTimeStepCountRequested() override;
|
2015-05-08 03:38:10 -05:00
|
|
|
|
2019-11-01 04:13:32 -05:00
|
|
|
void onUpdateDisplayModelForCurrentTimeStep() override;
|
2019-10-31 09:32:30 -05:00
|
|
|
void onUpdateStaticCellColors() override;
|
2015-05-08 03:38:10 -05:00
|
|
|
|
2019-10-31 09:32:30 -05:00
|
|
|
void onResetLegendsInViewer() override;
|
2015-05-13 15:42:11 -05:00
|
|
|
|
2019-10-31 10:37:16 -05:00
|
|
|
void onUpdateLegends() override;
|
2018-02-20 06:38:45 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void updateTensorLegendTextAndRanges( RimRegularLegendConfig* legendConfig, int timeStepIndex );
|
2015-05-13 15:55:07 -05:00
|
|
|
|
2018-02-05 02:28:16 -06:00
|
|
|
caf::PdmChildField<RimTensorResults*> m_tensorResults;
|
2015-08-27 15:54:37 -05:00
|
|
|
caf::PdmChildField<RimGeoMechPropertyFilterCollection*> m_propertyFilterCollection;
|
|
|
|
caf::PdmPointer<RimGeoMechPropertyFilterCollection> m_overridePropertyFilterCollection;
|
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmPointer<RimGeoMechCase> m_geomechCase;
|
|
|
|
cvf::ref<RivGeoMechVizLogic> m_vizLogic;
|
|
|
|
cvf::ref<cvf::Transform> m_scaleTransform;
|
2015-04-27 06:51:22 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
cvf::ref<RivTensorResultPartMgr> m_tensorPartMgr;
|
2015-04-20 02:02:33 -05:00
|
|
|
};
|