mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-09-03 14:10:33 +03:00
0029367: Visualization - simplify interface of V3d_View and V3d_Viewer
The interface of V3d_View and V3d_Viewer has been simplified. For the fields myDefinedViews, myActiveViews, myDefinedLights, myActiveLights were added appropriate methods returning the internal raw data. Make the next methods deprecated: IfMoreLights(), InitActiveLights(), MoreActiveLights(), NextActiveLights(), ActiveLight() and InitActiveViews(), MoreActiveViews(), NextActiveViews(), ActiveView(), InitDefinedViews(), MoreDefinedViews(), NextDefinedViews(), DefinedView(), InitActiveLights(), MoreActiveLights(), NextActiveLights(), ActiveLight(), InitDefinedLights(), MoreDefinedLights(), NextDefinedLights(), DefinedLight(). Remove deprecated methods added in scope of tasks 0029290 and 0028987 (Target Version 7.3.0): SelectMgr_SelectableObject: Init(), More(), Next(), CurrentSelection(). SelectMgr_Selection: Init(), More(), Next(), Sensitive(). V3d_AmbientLight: one constructor. V3d_DirectionalLight: two constructors. V3d_PositionalLight: one constructor. V3d_SpotLight: two constructors.
This commit is contained in:
@@ -707,24 +707,12 @@ public:
|
||||
//! Returns the current visualisation mode.
|
||||
Standard_EXPORT V3d_TypeOfVisualization Visualization() const;
|
||||
|
||||
//! Returns True if One light more can be
|
||||
//! activated in this View.
|
||||
Standard_EXPORT Standard_Boolean IfMoreLights() const;
|
||||
//! Returns a list of active lights.
|
||||
const V3d_ListOfLight& ActiveLights() const { return myActiveLights; }
|
||||
|
||||
//! Return iterator for defined lights.
|
||||
V3d_ListOfLightIterator ActiveLightIterator() const { return V3d_ListOfLightIterator (myActiveLights); }
|
||||
|
||||
//! initializes an iteration on the active Lights.
|
||||
void InitActiveLights() { myActiveLightsIterator.Initialize (myActiveLights); }
|
||||
|
||||
//! returns true if there are more active Light(s) to return.
|
||||
Standard_Boolean MoreActiveLights() const { return myActiveLightsIterator.More(); }
|
||||
|
||||
//! Go to the next active Light (if there is not, ActiveLight will raise an exception)
|
||||
void NextActiveLights() { myActiveLightsIterator.Next(); }
|
||||
|
||||
const Handle(V3d_Light)& ActiveLight() const { return myActiveLightsIterator.Value(); }
|
||||
|
||||
//! Returns the MAX number of light associated to the view.
|
||||
Standard_EXPORT Standard_Integer LightLimit() const;
|
||||
|
||||
@@ -969,6 +957,28 @@ public:
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(V3d_View,Standard_Transient)
|
||||
|
||||
public: //! @name deprecated methods
|
||||
|
||||
//! Returns True if One light more can be
|
||||
//! activated in this View.
|
||||
Standard_DEPRECATED ("Deprecated method - ActiveLights() should be used instead")
|
||||
Standard_EXPORT Standard_Boolean IfMoreLights() const;
|
||||
|
||||
//! initializes an iteration on the active Lights.
|
||||
Standard_DEPRECATED ("Deprecated method - ActiveLights() should be used instead")
|
||||
void InitActiveLights() { myActiveLightsIterator.Initialize (myActiveLights); }
|
||||
|
||||
//! returns true if there are more active Light(s) to return.
|
||||
Standard_DEPRECATED ("Deprecated method - ActiveLights() should be used instead")
|
||||
Standard_Boolean MoreActiveLights() const { return myActiveLightsIterator.More(); }
|
||||
|
||||
//! Go to the next active Light (if there is not, ActiveLight will raise an exception)
|
||||
Standard_DEPRECATED ("Deprecated method - ActiveLights() should be used instead")
|
||||
void NextActiveLights() { myActiveLightsIterator.Next(); }
|
||||
|
||||
Standard_DEPRECATED ("Deprecated method - ActiveLights() should be used instead")
|
||||
const Handle(V3d_Light)& ActiveLight() const { return myActiveLightsIterator.Value(); }
|
||||
|
||||
protected:
|
||||
|
||||
Standard_EXPORT void ImmediateUpdate() const;
|
||||
|
Reference in New Issue
Block a user