Loading...
Searching...
No Matches
extComputationPrimvarPruningSceneIndex.h
1
2//
3// Copyright 2022 Pixar
4//
5// Licensed under the Apache License, Version 2.0 (the "Apache License")
6// with the following modification; you may not use this file except in
7// compliance with the Apache License and the following modification to it:
8// Section 6. Trademarks. is deleted and replaced with:
9//
10// 6. Trademarks. This License does not grant permission to use the trade
11// names, trademarks, service marks, or product names of the Licensor
12// and its affiliates, except as required to comply with Section 4(c) of
13// the License and to reproduce the content of the NOTICE file.
14//
15// You may obtain a copy of the Apache License at
16//
17// http://www.apache.org/licenses/LICEN SE-2.0
18//
19// Unless required by applicable law or agreed to in writing, software
20// distributed under the Apache License with the above modification is
21// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
22// KIND, either express or implied. See the Apache License for the specific
23// language governing permissions and limitations under the Apache License.
24//
25// XXX change directive
26#ifndef PXR_IMAGING_HDSI_EXT_COMPUTATION_PRIMVAR_PRUNING_SCENE_INDEX_H
27#define PXR_IMAGING_HDSI_EXT_COMPUTATION_PRIMVAR_PRUNING_SCENE_INDEX_H
28
29#include "pxr/imaging/hdsi/api.h"
30#include "pxr/imaging/hd/filteringSceneIndex.h"
31
32PXR_NAMESPACE_OPEN_SCOPE
33
35
54{
55public:
56 HDSI_API
57 static HdSiExtComputationPrimvarPruningSceneIndexRefPtr
58 New(const HdSceneIndexBaseRefPtr &inputSceneIndex);
59
60 HDSI_API
61 HdSceneIndexPrim GetPrim(const SdfPath &primPath) const override final;
62
63 HDSI_API
64 SdfPathVector GetChildPrimPaths(const SdfPath &primPath) const override final;
65
66protected:
67 HDSI_API
68 void _PrimsAdded(
69 const HdSceneIndexBase &sender,
70 const HdSceneIndexObserver::AddedPrimEntries &entries) override final;
71
72 HDSI_API
73 void _PrimsRemoved(
74 const HdSceneIndexBase &sender,
75 const HdSceneIndexObserver::RemovedPrimEntries &entries) override final;
76
77 HDSI_API
78 void _PrimsDirtied(
79 const HdSceneIndexBase &sender,
80 const HdSceneIndexObserver::DirtiedPrimEntries &entries) override final;
81
82 HDSI_API
84 const HdSceneIndexBaseRefPtr &inputSceneIndex);
85
86};
87
88PXR_NAMESPACE_CLOSE_SCOPE
89
90#endif //PXR_IMAGING_HDSI_EXT_COMPUTATION_PRIMVAR_PRUNING_SCENE_INDEX_H
Abstract interface to scene data.
Definition: sceneIndex.h:65
Hydra ExtComputations provide a simple computation framework allowing primvars to be computed using C...
HDSI_API HdSceneIndexPrim GetPrim(const SdfPath &primPath) const override final
Returns a pair of (prim type, datasource) for the object at primPath.
HDSI_API SdfPathVector GetChildPrimPaths(const SdfPath &primPath) const override final
Returns the paths of all scene index prims located immediately below primPath.
An abstract base class for a filtering scene index that observes a single input scene index.
A path value used to locate objects in layers or scenegraphs.
Definition: path.h:290
#define TF_DECLARE_WEAK_AND_REF_PTRS(type)
Define standard weak, ref, and vector pointer types.
Definition: declarePtrs.h:89
Small struct representing a 'prim' in the Hydra scene index.
Definition: sceneIndex.h:52