aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/Asset.h
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-14 11:26:12 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-14 11:26:12 +0100
commit01c09a196c3f3e5cefaa4119a95a1cdeb7b9c263 (patch)
tree5667369a85bd06b683c67de42bf0311c2647912b /src/crepe/Asset.h
parent6e13510f3c6d4155707f748d237bb1fa05243450 (diff)
parent8600b8a29351aae26ec7b22f84aeeef92d8cb421 (diff)
merge `loek/cleanup` into `loek/audio`
Diffstat (limited to 'src/crepe/Asset.h')
-rw-r--r--src/crepe/Asset.h18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/crepe/Asset.h b/src/crepe/Asset.h
index d4e4ba1..cb413f4 100644
--- a/src/crepe/Asset.h
+++ b/src/crepe/Asset.h
@@ -20,13 +20,21 @@ public:
Asset(const std::string & src);
public:
- //! Get an input stream to the contents of this resource
- const std::istream & read();
- //! Get the canonical path to this resource
- const char * canonical() const;
+ /**
+ * \brief Get an input stream to the contents of this asset
+ * \return Input stream with file contents
+ */
+ std::istream & get_stream();
+ /**
+ * \brief Get the canonical path to this asset
+ * \return Canonical path to this asset
+ */
+ const std::string & get_canonical() const;
private:
- std::string src;
+ //! Canonical path to asset
+ const std::string src;
+ //! File handle (stream)
std::ifstream file;
};