diff options
author | Ton Roosendaal <ton@blender.org> | 2018-04-19 18:34:44 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-04-19 18:35:25 +0300 |
commit | 51b796ff1528c52cc8b4079fab1003671652a4d9 (patch) | |
tree | 0dfc2d2dabe5e77959264f5b6667897569290a41 /source/blender/makesrna/intern/rna_texture_api.c | |
parent | 785e8a636a293941a4295e669cb5aeecfafae039 (diff) |
Remove Blender Internal and legacy viewport from Blender 2.8.
Brecht authored this commit, but he gave me the honours to actually
do it. Here it goes; Blender Internal. Bye bye, you did great!
* Point density, voxel data, ocean, environment map textures were removed,
as these only worked within BI rendering. Note that the ocean modifier
and the Cycles point density shader node continue to work.
* Dynamic paint using material shading was removed, as this only worked
with BI. If we ever wanted to support this again probably it should go
through the baking API.
* GPU shader export through the Python API was removed. This only worked
for the old BI GLSL shaders, which no longer exists. Doing something
similar for Eevee would be significantly more complicated because it
uses a lot of multiplass rendering and logic outside the shader, it's
probably impractical.
* Collada material import / export code is mostly gone, as it only worked
for BI materials. We need to add Cycles / Eevee material support at some
point.
* The mesh noise operator was removed since it only worked with BI
material texture slots. A displacement modifier can be used instead.
* The delete texture paint slot operator was removed since it only worked
for BI material texture slots. Could be added back with node support.
* Not all legacy viewport features are supported in the new viewport, but
their code was removed. If we need to bring anything back we can look at
older git revisions.
* There is some legacy viewport code that I could not remove yet, and some
that I probably missed.
* Shader node execution code was left mostly intact, even though it is not
used anywhere now. We may eventually use this to replace the texture
nodes with Cycles / Eevee shader nodes.
* The Cycles Bake panel now includes settings for baking multires normal
and displacement maps. The underlying code needs to be merged properly,
and we plan to add back support for multires AO baking and add support
to Cycles baking for features like vertex color, displacement, and other
missing baking features.
* This commit removes DNA and the Python API for BI material, lamp, world
and scene settings. This breaks a lot of addons.
* There is more DNA that can be removed or renamed, where Cycles or Eevee
are reusing some old BI properties but the names are not really correct
anymore.
* Texture slots for materials, lamps and world were removed. They remain
for brushes, particles and freestyle linestyles.
* 'BLENDER_RENDER' remains in the COMPAT_ENGINES of UI panels. Cycles and
other renderers use this to find all panels to show, minus a few panels
that they have their own replacement for.
Diffstat (limited to 'source/blender/makesrna/intern/rna_texture_api.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_texture_api.c | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/source/blender/makesrna/intern/rna_texture_api.c b/source/blender/makesrna/intern/rna_texture_api.c index a8fcf0ca3b6..1d513a494d7 100644 --- a/source/blender/makesrna/intern/rna_texture_api.c +++ b/source/blender/makesrna/intern/rna_texture_api.c @@ -45,30 +45,6 @@ #include "RE_pipeline.h" #include "RE_shader_ext.h" -static void save_envmap(struct EnvMap *env, bContext *C, ReportList *reports, const char *filepath, - struct Scene *scene, float layout[12]) -{ - if (scene == NULL) { - scene = CTX_data_scene(C); - } - - RE_WriteEnvmapResult(reports, scene, env, filepath, scene->r.im_format.imtype, layout); -} - -static void clear_envmap(struct EnvMap *env, bContext *C) -{ - Main *bmain = CTX_data_main(C); - Tex *tex; - - BKE_texture_envmap_free_data(env); - - for (tex = bmain->tex.first; tex; tex = tex->id.next) - if (tex->env == env) { - WM_event_add_notifier(C, NC_TEXTURE | NA_EDITED, tex); - break; - } -} - static void texture_evaluate(struct Tex *tex, float value[3], float r_color[4]) { TexResult texres = {0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0, NULL}; @@ -102,31 +78,4 @@ void RNA_api_texture(StructRNA *srna) } -void RNA_api_environment_map(StructRNA *srna) -{ - FunctionRNA *func; - PropertyRNA *parm; - - static const float default_layout[] = {0, 0, 1, 0, 2, 0, 0, 1, 1, 1, 2, 1}; - - func = RNA_def_function(srna, "clear", "clear_envmap"); - RNA_def_function_ui_description(func, "Discard the environment map and free it from memory"); - RNA_def_function_flag(func, FUNC_USE_CONTEXT); - - - func = RNA_def_function(srna, "save", "save_envmap"); - RNA_def_function_ui_description(func, "Save the environment map to disc using the scene render settings"); - RNA_def_function_flag(func, FUNC_USE_CONTEXT | FUNC_USE_REPORTS); - - parm = RNA_def_string_file_name(func, "filepath", NULL, FILE_MAX, "File path", "Location of the output file"); - RNA_def_parameter_flags(parm, 0, PARM_REQUIRED); - - RNA_def_pointer(func, "scene", "Scene", "", "Overrides the scene from which image parameters are taken"); - - RNA_def_float_array(func, "layout", 12, default_layout, 0.0f, 1000.0f, "File layout", - "Flat array describing the X,Y position of each cube face in the " - "output image, where 1 is the size of a face - order is [+Z -Z +Y -X -Y +X] " - "(use -1 to skip a face)", 0.0f, 1000.0f); -} - #endif |