1#ifndef YAZE_APP_EDITOR_GRAPHICS_PIXEL_CLIPBOARD_H
2#define YAZE_APP_EDITOR_GRAPHICS_PIXEL_CLIPBOARD_H
9#include "absl/status/statusor.h"
19 const std::vector<uint8_t>& indices,
int width,
int height,
41 const std::vector<uint8_t>& png_bytes,
const SheetColors& colors,
42 int max_width = 128,
int max_height = 32);
Editors are the view controllers for the application.
absl::StatusOr< ClipboardPaste > MapClipboardPng(const std::vector< uint8_t > &png_bytes, const SheetColors &colors, int max_width, int max_height)
std::array< std::array< uint8_t, 3 >, 8 > SheetColors
The 8 colors a 3bpp sheet shows (index 0 is transparent in game).
absl::StatusOr< std::vector< uint8_t > > EncodeClipboardPng(const std::vector< uint8_t > &indices, int width, int height, const SheetColors &colors)
std::string DescribeClipboardPaste(const ClipboardPaste &paste)
"16x16: 200 kept" / "16x8: 90 exact, 38 remapped, 4 above color 7".
A clipboard PNG mapped onto a sheet's colors.
std::vector< uint8_t > indices