Blender  V2.93
BKE_image_save.h
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or
3  * modify it under the terms of the GNU General Public License
4  * as published by the Free Software Foundation; either version 2
5  * of the License, or (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software Foundation,
14  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15  *
16  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
17  * All rights reserved.
18  */
19 #pragma once
20 
21 #include "DNA_scene_types.h"
22 
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30 
31 struct Image;
32 struct Main;
33 struct ReportList;
34 struct Scene;
35 
36 typedef struct ImageSaveOptions {
37  /* Context within which image is saved. */
38  struct Main *bmain;
39  struct Scene *scene;
40 
41  /* Format and absolute file path. */
43  char filepath[1024]; /* 1024 = FILE_MAX */
44 
45  /* Options. */
46  bool relative;
47  bool save_copy;
49  bool do_newpath;
51 
53  struct Main *bmain,
54  struct Scene *scene);
55 bool BKE_image_save(struct ReportList *reports,
56  struct Main *bmain,
57  struct Image *ima,
58  struct ImageUser *iuser,
59  struct ImageSaveOptions *opts);
60 
61 #ifdef __cplusplus
62 }
63 #endif
struct ImageSaveOptions ImageSaveOptions
void BKE_image_save_options_init(struct ImageSaveOptions *opts, struct Main *bmain, struct Scene *scene)
Definition: image_save.c:46
bool BKE_image_save(struct ReportList *reports, struct Main *bmain, struct Image *ima, struct ImageUser *iuser, struct ImageSaveOptions *opts)
Definition: image_save.c:397
Scene scene
struct ImageFormatData im_format
struct Scene * scene
struct Main * bmain
char filepath[1024]
Definition: BKE_main.h:116