Skip to content

Commit 95e2a68

Browse files
committed
LiveScene: Added setOp to avoid recreating LiveScene ( and throwing cache away )
1 parent 05fce6d commit 95e2a68

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

include/IECoreNuke/LiveScene.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,9 @@ class IECORENUKE_API LiveScene : public IECoreScene::SceneInterface
111111
static double timeToFrame( const double& time );
112112
static double frameToTime( const int& frame );
113113

114+
void setOp( DD::Image::GeoOp* op );
115+
const DD::Image::GeoOp *getOp() const;
116+
114117
private:
115118

116119
DD::Image::GeoOp *op() const;

src/IECoreNuke/LiveScene.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,13 @@ LiveScene::~LiveScene()
9494
{
9595
}
9696

97-
GeoOp *LiveScene::op() const
97+
void LiveScene::setOp( DD::Image::GeoOp* op )
98+
{
99+
m_op = op;
100+
m_objectPathMap.clear();
101+
}
102+
103+
const GeoOp *LiveScene::getOp() const
98104
{
99105
return m_op;
100106
}

0 commit comments

Comments
 (0)