summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMario Daniel Ruiz Saavedra <desiderantes93@gmail.com>2020-12-17 19:22:46 +0000
committerRico Tzschichholz <ricotz@ubuntu.com>2020-12-29 15:32:51 +0100
commit53fc8cf0a831ed7ddc8fcfe3b84cd3af76d87b97 (patch)
tree56a6cb4b165e6ba8e015996b2640f206dde8ecf6
parentb551c21d1c4130dcccc5e6777240173b5d765d5c (diff)
downloadvala-53fc8cf0a831ed7ddc8fcfe3b84cd3af76d87b97.tar.gz
SDL2_image: Add save functions
Add save functions for JPG and PNG formats.
-rw-r--r--vapi/SDL2_image.vapi12
1 files changed, 12 insertions, 0 deletions
diff --git a/vapi/SDL2_image.vapi b/vapi/SDL2_image.vapi
index 7bb65dc58..ff1495a59 100644
--- a/vapi/SDL2_image.vapi
+++ b/vapi/SDL2_image.vapi
@@ -123,6 +123,18 @@ namespace SDLImage {
[CCode (cname = "IMG_ReadXPMFromArray")]
public static SDL.Video.Surface? read_xpm (string[] xpmdata);
+ [CCode (cname = "IMG_SavePNG")]
+ public static int save_as_png (SDL.Video.Surface surface, string file);
+
+ [CCode (cname = "IMG_SavePNG_RW")]
+ public static int save_as_png_rw (SDL.Video.Surface surface, SDL.RWops dst, bool freedst);
+
+ [CCode (cname = "IMG_SaveJPG")]
+ public static int save_as_jpg (SDL.Video.Surface surface, string file, int quality);
+
+ [CCode (cname = "IMG_SaveJPG_RW")]
+ public static int save_as_jpg_rw (SDL.Video.Surface surface, SDL.RWops dst, bool freedst, int quality);
+
//!Info
[CCode (cname = "IMG_isCUR")]