Skip to content

Commit

Permalink
InstancerCapsule Work In Progress
Browse files Browse the repository at this point in the history
  • Loading branch information
danieldresser-ie committed Sep 1, 2023
1 parent 80374d5 commit 8003b22
Show file tree
Hide file tree
Showing 6 changed files with 655 additions and 147 deletions.
2 changes: 1 addition & 1 deletion include/GafferScene/Capsule.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ class GAFFERSCENE_API Capsule : public IECoreScenePreview::Procedural
const ScenePlug::ScenePath &root() const;
const Gaffer::Context *context() const;

private :
protected :

void throwIfNoScene() const;

Expand Down
23 changes: 23 additions & 0 deletions include/GafferScene/Instancer.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@

#include "GafferScene/Export.h"
#include "GafferScene/BranchCreator.h"
#include "GafferScene/Capsule.h"

namespace GafferScene
{
Expand Down Expand Up @@ -161,6 +162,28 @@ class GAFFERSCENE_API Instancer : public BranchCreator

void affects( const Gaffer::Plug *input, AffectedPlugsContainer &outputs ) const override;

class InstancerCapsule : public Capsule
{

public :

InstancerCapsule();
InstancerCapsule(
const ScenePlug *scene,
const ScenePlug::ScenePath &root,
const Gaffer::Context &context,
const IECore::MurmurHash &hash,
const Imath::Box3f &bound
);
~InstancerCapsule() override;

IE_CORE_DECLAREEXTENSIONOBJECT( GafferScene::Instancer::InstancerCapsule, GafferScene::InstancerCapsuleTypeId, GafferScene::Capsule );

void render( IECoreScenePreview::Renderer *renderer ) const override;
};

IE_CORE_DECLAREPTR( InstancerCapsule )

protected :

void hash( const Gaffer::ValuePlug *output, const Gaffer::Context *context, IECore::MurmurHash &h ) const override;
Expand Down
1 change: 1 addition & 0 deletions include/GafferScene/TypeIds.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ enum TypeId
MeshSplitTypeId = 110632,
FramingConstraintTypeId = 110633,
MeshNormalsTypeId = 110634,
InstancerCapsuleTypeId = 110635,

PreviewPlaceholderTypeId = 110647,
PreviewGeometryTypeId = 110648,
Expand Down
Loading

0 comments on commit 8003b22

Please sign in to comment.