Porytiles
Loading...
Searching...
No Matches
png_importer.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <expected>
4#include <filesystem>
5#include <memory>
6#include <string>
7
9
10namespace porytiles {
11
16 public:
17 virtual ~PngImporter() = default;
18
29 [[nodiscard]] virtual std::expected<std::unique_ptr<Png>, std::string>
30 Read(const std::filesystem::path &path) const = 0;
31};
32
33} // namespace porytiles
Imports a Png from the filesystem.
virtual ~PngImporter()=default
virtual std::expected< std::unique_ptr< Png >, std::string > Read(const std::filesystem::path &path) const =0
Imports a Png at a given path from the filesystem.