aboutsummaryrefslogtreecommitdiff
path: root/scale.h
diff options
context:
space:
mode:
authorneonloop2021-08-04 15:09:12 +0000
committerneonloop2021-08-04 15:09:12 +0000
commit99632f66e74fc57c463072be312d634aeb67bc61 (patch)
treee4ccaf52b93d04c69865d82556e2ce4cd3a6c599 /scale.h
downloadpicoarch-99632f66e74fc57c463072be312d634aeb67bc61.tar.gz
picoarch-99632f66e74fc57c463072be312d634aeb67bc61.tar.bz2
picoarch-99632f66e74fc57c463072be312d634aeb67bc61.zip
Initial commit
Diffstat (limited to 'scale.h')
-rw-r--r--scale.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/scale.h b/scale.h
new file mode 100644
index 0000000..c415124
--- /dev/null
+++ b/scale.h
@@ -0,0 +1,24 @@
+#ifndef __SCALE_H__
+#define __SCALE_H__
+
+#define SCREEN_WIDTH 320
+#define SCREEN_HEIGHT 240
+#define SCREEN_BPP 2
+#define SCREEN_PITCH (SCREEN_BPP * SCREEN_WIDTH)
+
+enum scale_size {
+ SCALE_SIZE_NONE,
+ SCALE_SIZE_ASPECT,
+ SCALE_SIZE_FULL,
+};
+
+enum scale_filter {
+ SCALE_FILTER_NEAREST,
+ SCALE_FILTER_SHARP,
+ SCALE_FILTER_SMOOTH,
+};
+
+void scale_update_scaler(void);
+void scale(unsigned w, unsigned h, size_t pitch, const void *src, void *dst);
+
+#endif