~Picture();
Result load(const std::string& path) noexcept;
+ Result load(const char* data, uint32_t size) noexcept;
Result viewbox(float* x, float* y, float* w, float* h) const noexcept;
static std::unique_ptr<Picture> gen() noexcept;
public:
~SwCanvas();
- Result target(uint32_t* buffer, uint32_t stride, uint32_t w, uint32_t h) noexcept;
+ enum Colorspace { ABGR8888 = 0, ARGB8888 };
+
+ Result target(uint32_t* buffer, uint32_t stride, uint32_t w, uint32_t h, Colorspace cs) noexcept;
static std::unique_ptr<SwCanvas> gen() noexcept;
*
* @see ...
*/
- static Result init(CanvasEngine engine) noexcept;
+ static Result init(CanvasEngine engine, uint32_t threads) noexcept;
static Result term(CanvasEngine engine) noexcept;
- static Result threads(uint32_t cnt) noexcept;
- static uint32_t threads() noexcept;
_TVG_DISABLE_CTOR(Initializer);
};