mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
// Continued expansion of Animation storage functionality
Updated Operation classes to smart pointer classes First iteration of Animation getting and setting object First version of XCAF tool to deal with Animation Implemented new GUID for clear definition of Animation attributes
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
// Copyright (c) 2023 OPEN CASCADE SAS
|
||||
// Copyright (c) 2023 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
@@ -14,25 +15,8 @@
|
||||
#ifndef _XCAFDoc_AnimationTool_HeaderFile
|
||||
#define _XCAFDoc_AnimationTool_HeaderFile
|
||||
|
||||
#include <Standard.hxx>
|
||||
|
||||
#include <XCAFDoc_DataMapOfShapeLabel.hxx>
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <TDataStd_NamedData.hxx>
|
||||
#include <TDataStd_GenericEmpty.hxx>
|
||||
#include <TDF_LabelMap.hxx>
|
||||
#include <TDF_LabelSequence.hxx>
|
||||
#include <Standard_Integer.hxx>
|
||||
#include <Standard_OStream.hxx>
|
||||
#include <TColStd_SequenceOfHAsciiString.hxx>
|
||||
#include <TDF_AttributeSequence.hxx>
|
||||
#include <TopTools_SequenceOfShape.hxx>
|
||||
|
||||
class Standard_GUID;
|
||||
class TDF_Label;
|
||||
class TopoDS_Shape;
|
||||
class TopLoc_Location;
|
||||
class XCAFDoc_GraphNode;
|
||||
|
||||
//! A tool to store shapes in an XDE
|
||||
//! document in the form of assembly structure, and to maintain this structure.
|
||||
@@ -55,28 +39,67 @@ class XCAFDoc_AnimationTool : public TDataStd_GenericEmpty
|
||||
public:
|
||||
|
||||
Standard_EXPORT static const Standard_GUID& GetID();
|
||||
|
||||
|
||||
//! Create (if not exist) ShapeTool from XCAFDoc on <L>.
|
||||
Standard_EXPORT static Handle(XCAFDoc_AnimationTool) Set (const TDF_Label& theLabel);
|
||||
|
||||
Standard_EXPORT static Handle(XCAFDoc_AnimationTool) Set(const TDF_Label& theLabel);
|
||||
|
||||
//! Creates an empty tool
|
||||
//! Creates a tool to work with a document <Doc>
|
||||
//! Attaches to label XCAFDoc::LabelShapes()
|
||||
Standard_EXPORT XCAFDoc_AnimationTool();
|
||||
|
||||
|
||||
//! returns the label under which shapes are stored
|
||||
Standard_EXPORT TDF_Label BaseLabel() const;
|
||||
|
||||
Standard_EXPORT Standard_OStream& Dump (Standard_OStream& theOStream, const Standard_Boolean theDepth) const;
|
||||
|
||||
Standard_EXPORT virtual Standard_OStream& Dump (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//!
|
||||
Standard_EXPORT bool IsAnimation(const TDF_Label& theLabel) const;
|
||||
|
||||
//!
|
||||
Standard_EXPORT void SetAnimation(const TDF_Label& theShLabel,
|
||||
const TDF_Label& theAnimLabel) const;
|
||||
|
||||
//!
|
||||
Standard_EXPORT bool GetGlobalFPS(double& theFPS) const;
|
||||
|
||||
//!
|
||||
Standard_EXPORT void SetGlobalFPS(const double theFPS) const;
|
||||
|
||||
//! Returns a sequence of Animation labels currently stored
|
||||
//! in the Animation table.
|
||||
Standard_EXPORT void GetAnimationLabels(TDF_LabelSequence& theLabels) const;
|
||||
|
||||
//! Returns Animation label defined for shape.
|
||||
Standard_EXPORT bool GetRefAnimationLabel(const TDF_Label& theShLabel,
|
||||
TDF_Label& theAnimLabel) const;
|
||||
|
||||
//! Returns Animation label defined for shape.
|
||||
Standard_EXPORT bool GetRefShapeLabel(const TDF_Label& theAnimLabel,
|
||||
TDF_Label& theShLabel) const;
|
||||
|
||||
//! Adds a animation definition to the Animation table and returns its label.
|
||||
Standard_EXPORT TDF_Label AddAnimation() const;
|
||||
|
||||
//! Returns true if the given Animation is marked as locked.
|
||||
Standard_EXPORT bool IsLocked(const TDF_Label& theAnimLabel) const;
|
||||
|
||||
//! Mark the given Animation as locked.
|
||||
Standard_EXPORT void Lock(const TDF_Label& theAnimLabel) const;
|
||||
|
||||
//! Unlock the given Animation.
|
||||
Standard_EXPORT void Unlock(const TDF_Label& theAnimLabel) const;
|
||||
|
||||
Standard_EXPORT Standard_OStream& Dump(Standard_OStream& theOStream, const bool theDepth) const;
|
||||
|
||||
Standard_EXPORT virtual Standard_OStream& Dump(Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT const Standard_GUID& ID() const Standard_OVERRIDE;
|
||||
|
||||
//! Dumps the content of me into the stream
|
||||
Standard_EXPORT virtual void DumpJson (Standard_OStream& theOStream, Standard_Integer theDepth = -1) const Standard_OVERRIDE;
|
||||
|
||||
DEFINE_DERIVED_ATTRIBUTE(XCAFDoc_AnimationTool,TDataStd_GenericEmpty)
|
||||
//! Dumps the content of me into the stream
|
||||
Standard_EXPORT virtual void DumpJson(Standard_OStream& theOStream, Standard_Integer theDepth = -1) const Standard_OVERRIDE;
|
||||
|
||||
DEFINE_DERIVED_ATTRIBUTE(XCAFDoc_AnimationTool, TDataStd_GenericEmpty)
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user