LeviLamina
Loading...
Searching...
No Matches
ImageResourceLoader.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/image/ImageFormat.h"
7#include "mc/deps/core/math/AlphaUsage.h"
8#include "mc/external/render_dragon/texture_streaming/texture_cache/TextureCache.h"
9
10// auto generated forward declare list
11// clang-format off
13namespace cg { class ImageResource; }
14namespace dragon::texturestreaming { struct DragonTextureCacheContext; }
15// clang-format on
16
17namespace mce {
18
19class ImageResourceLoader {
20public:
21 // ImageResourceLoader inner types define
22 enum class LoadError : int {
23 TextureConversionError = 0,
24 };
25
26public:
27 // member variables
28 // NOLINTBEGIN
31 // NOLINTEND
32
33public:
34 // prevent constructor by default
35 ImageResourceLoader& operator=(ImageResourceLoader const&);
36 ImageResourceLoader(ImageResourceLoader const&);
37 ImageResourceLoader();
38
39public:
40 // member functions
41 // NOLINTBEGIN
42#ifdef LL_PLAT_C
43 MCNAPI ::nonstd::expected<::std::shared_ptr<::cg::ImageResource>, ::std::error_condition>
44 loadImageResourceFromMemory(
45 ::ResourceLocation const& resourceLocation,
46 ::std::string const& fileContents,
47 bool tryStreamed,
48 ::mce::AlphaUsage alphaUsage
49 );
50
51 MCNAPI ::nonstd::expected<::std::shared_ptr<::cg::ImageResource>, ::std::error_condition> loadImageWithoutExtension(
52 ::ResourceLocation const& resourceLocation,
53 bool tryStreamed,
54 ::mce::AlphaUsage alphaUsage,
55 ::std::optional<::mce::ImageFormat> desiredImageFormat,
56 bool splitAsArray
57 );
58
59 MCNAPI void setTextureCache(
60 ::std::shared_ptr<
62 textureCache
63 );
64#endif
65 // NOLINTEND
66};
67
68} // namespace mce
Definition ResourceLocation.h:15
Definition ImageResource.h:15
Definition TextureCache.h:8
Definition DragonTextureCacheContext.h:7
Definition Alias.h:14