diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-11-22 03:56:32 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-11-22 03:56:32 +0400 |
commit | da25b50ccb6a2a2c7d91ec588fe5c1b0e150ae4e (patch) | |
tree | 8abc36b362e479a6ba6aca8a8de417fd1c9d4d47 /source/blender/editors/render/render_shading.c | |
parent | 30fd1ab523393216a66a7debb7e42ec39e40a242 (diff) |
image save operator now shares settings and UI with render & image out node.
details:
- setting format options from python isnt possible anymore since this isnt exposed via op->properties, python should use image.save() function instead.
- image save UI now hides 'Relative' option when copy is selected since it has no effect.
- default image depth is set to 8 or more if the image has no float buffer, otherwise its set to 32 or less.
other fixes:
- image new was adding an image with a filepath set to "untitled", if this file happened to exist in the current directory a save on the generated image would overwrite it, now initialize to empty path.
- BKE_ftype_to_imtype was returning an invalid value if ftype==0.
Diffstat (limited to 'source/blender/editors/render/render_shading.c')
-rw-r--r-- | source/blender/editors/render/render_shading.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/render/render_shading.c b/source/blender/editors/render/render_shading.c index cf14432754f..f4731eda5bb 100644 --- a/source/blender/editors/render/render_shading.c +++ b/source/blender/editors/render/render_shading.c @@ -658,7 +658,7 @@ void TEXTURE_OT_slot_move(wmOperatorType *ot) /********************** environment map operators *********************/ -static int save_envmap(wmOperator *op, Scene *scene, EnvMap *env, char *path, int imtype) +static int save_envmap(wmOperator *op, Scene *scene, EnvMap *env, char *path, const char imtype) { float layout[12]; if ( RNA_struct_find_property(op->ptr, "layout") ) @@ -680,7 +680,7 @@ static int envmap_save_exec(bContext *C, wmOperator *op) Tex *tex= CTX_data_pointer_get_type(C, "texture", &RNA_Texture).data; Scene *scene = CTX_data_scene(C); //int imtype = RNA_enum_get(op->ptr, "file_type"); - int imtype = scene->r.im_format.imtype; + char imtype = scene->r.im_format.imtype; char path[FILE_MAX]; RNA_string_get(op->ptr, "filepath", path); |