Loading...
Searching...
No Matches
imageRegistry.h
1//
2// Copyright 2016 Pixar
3//
4// Licensed under the terms set forth in the LICENSE.txt file available at
5// https://openusd.org/license.
6//
7#ifndef PXR_IMAGING_HIO_IMAGE_REGISTRY_H
8#define PXR_IMAGING_HIO_IMAGE_REGISTRY_H
9
10#include "pxr/pxr.h"
11#include "pxr/imaging/hio/api.h"
13
14#include <memory>
15#include <string>
16
17PXR_NAMESPACE_OPEN_SCOPE
18
19using HioImageSharedPtr = std::shared_ptr<class HioImage>;
20
21class HioRankedTypeMap;
22
27class HioImageRegistry : public TfSingleton<HioImageRegistry>
28{
29public:
30 HIO_API
31 static HioImageRegistry& GetInstance();
32
33 HIO_API
34 bool IsSupportedImageFile(std::string const & filename);
35
36private:
37 friend class TfSingleton<HioImageRegistry>;
39
40 friend class HioImage;
41
42 HioImageSharedPtr _ConstructImage(std::string const & filename);
43
44private:
45 std::unique_ptr<HioRankedTypeMap> const _typeMap;
46};
47
48PXR_NAMESPACE_CLOSE_SCOPE
49
50#endif // PXR_IMAGING_HIO_IMAGE_REGISTRY_H
A base class for reading and writing texture image data.
Definition: image.h:38
Manages plugin registration and loading for HioImage subclasses.
Definition: imageRegistry.h:28
Manage a single instance of an object (see.
Definition: singleton.h:105
Manage a single instance of an object.