Skip to content

Commit

Permalink
Correctly export TfStacked.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jamie Kenyon committed Aug 18, 2016
1 parent a976d1a commit cd7567a
Show file tree
Hide file tree
Showing 9 changed files with 146 additions and 171 deletions.
286 changes: 144 additions & 142 deletions pxr/base/lib/tf/stacked.h

Large diffs are not rendered by default.

3 changes: 1 addition & 2 deletions pxr/usd/lib/sdf/cleanupEnabler.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@
/// }
/// \endcode
///
class SdfCleanupEnabler :
public TfStacked<SdfCleanupEnabler, /* thread safe */ false>
TF_DECLARE_STACKED_CLASS(SdfCleanupEnabler, false, SDF_API)
{
public:

Expand Down
4 changes: 1 addition & 3 deletions pxr/usd/lib/usd/stageCacheContext.h
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ enum UsdStageCacheContextBlockType
/// UsdStageCacheContext objects that exist in one thread's stack do not
/// influence calls to UsdStage::Open() from a different thread.
///
class UsdStageCacheContext : public TfStacked<UsdStageCacheContext, true>
TF_DECLARE_STACKED_CLASS(UsdStageCacheContext, true, USD_API)
{
public:
/// \brief Bind a cache for calls to UsdStage::Open() to read from and write
Expand Down Expand Up @@ -154,6 +154,4 @@ class UsdStageCacheContext : public TfStacked<UsdStageCacheContext, true>
UsdStageCacheContextBlockType _blockType;
};

// USD_API_TEMPLATE_CLASS(TfStacked<UsdStageCacheContext>);

#endif // USD_STAGECACHECONTEXT_H
4 changes: 0 additions & 4 deletions pxr/usd/lib/usd/wrapStageCacheContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,6 @@ using std::vector;

using namespace boost::python;

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

namespace {

// Expose C++ RAII class as python context manager.
Expand Down
4 changes: 0 additions & 4 deletions third_party/katana/lib/usdKatana/cache.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@
#include <regex.h>
#endif

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

TF_INSTANTIATE_SINGLETON(UsdKatanaCache);

SdfLayerRefPtr&
Expand Down
4 changes: 0 additions & 4 deletions third_party/maya/lib/usdMaya/proxyShape.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,6 @@

#include <mutex>

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

// Hydra performs its own high-performance frustum culling, so
// we don't want to rely on Maya to do it on the CPU. AS such, the best
// performance comes from telling Maya to pretend that every object has no
Expand Down
4 changes: 0 additions & 4 deletions third_party/maya/lib/usdMaya/referenceAssembly.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,6 @@
#include <string>
#include <vector>

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

TF_DEFINE_ENV_SETTING(PIXMAYA_USE_USD_REF_ASSEMBLIES, true,
"Uses USD scene assemblies for set dressing");

Expand Down
4 changes: 0 additions & 4 deletions third_party/maya/lib/usdMaya/translatorModelAssembly.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,6 @@
#include <string>
#include <vector>

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

TF_DEFINE_PRIVATE_TOKENS(_tokens,
((FilePathPlugName, "filePath"))
((PrimPathPlugName, "primPath"))
Expand Down
4 changes: 0 additions & 4 deletions third_party/maya/lib/usdMaya/usdReadJob.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,6 @@
#include <string>
#include <vector>

// XXX: NO!
#include "pxr/base/tf/instantiateStacked.h"
TF_INSTANTIATE_STACKED(UsdStageCacheContext);

// for now, we hard code this to use displayColor. But maybe the more
// appropriate thing to do is just to leave shadingMode a lone and pass
// "displayColor" in from the UsdMayaRepresentationFull
Expand Down

0 comments on commit cd7567a

Please sign in to comment.