Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Carlisle <carlisle.b3d@gmail.com>2020-11-06 18:36:51 +0300
committerAaron Carlisle <carlisle.b3d@gmail.com>2020-11-06 18:37:40 +0300
commit580ff2cb937daf43699908afe1190baea8d117aa (patch)
treeb96880786126cebf91474f10f75cc9b68b61baa0 /source/blender/render/intern/include
parent90ac9770a4a9370f10932724487f8f58763fbbac (diff)
Cleanup: Render Module: combine intern/ source & include
Diffstat (limited to 'source/blender/render/intern/include')
-rw-r--r--source/blender/render/intern/include/initrender.h38
-rw-r--r--source/blender/render/intern/include/render_result.h156
-rw-r--r--source/blender/render/intern/include/render_types.h168
-rw-r--r--source/blender/render/intern/include/renderpipeline.h44
-rw-r--r--source/blender/render/intern/include/texture.h109
-rw-r--r--source/blender/render/intern/include/zbuf.h48
6 files changed, 0 insertions, 563 deletions
diff --git a/source/blender/render/intern/include/initrender.h b/source/blender/render/intern/include/initrender.h
deleted file mode 100644
index f5ac352752f..00000000000
--- a/source/blender/render/intern/include/initrender.h
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Functions */
-
-void RE_parts_init(Render *re);
-void RE_parts_free(Render *re);
-void RE_parts_clamp(Render *re);
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/source/blender/render/intern/include/render_result.h b/source/blender/render/intern/include/render_result.h
deleted file mode 100644
index 5c487223e94..00000000000
--- a/source/blender/render/intern/include/render_result.h
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2007 Blender Foundation.
- * All rights reserved.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-#define PASS_VECTOR_MAX 10000.0f
-
-#define RR_USE_MEM 0
-#define RR_USE_EXR 1
-
-#define RR_ALL_LAYERS NULL
-#define RR_ALL_VIEWS NULL
-
-struct ColorManagedDisplaySettings;
-struct ColorManagedViewSettings;
-struct ImBuf;
-struct ListBase;
-struct Render;
-struct RenderData;
-struct RenderEngine;
-struct RenderLayer;
-struct RenderResult;
-struct Scene;
-struct rcti;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* New */
-
-struct RenderResult *render_result_new(struct Render *re,
- struct rcti *partrct,
- int crop,
- int savebuffers,
- const char *layername,
- const char *viewname);
-
-struct RenderResult *render_result_new_from_exr(
- void *exrhandle, const char *colorspace, bool predivide, int rectx, int recty);
-
-void render_result_view_new(struct RenderResult *rr, const char *viewname);
-void render_result_views_new(struct RenderResult *rr, const struct RenderData *rd);
-
-/* Merge */
-
-void render_result_merge(struct RenderResult *rr, struct RenderResult *rrpart);
-
-/* Add Passes */
-
-void render_result_clone_passes(struct Render *re, struct RenderResult *rr, const char *viewname);
-
-/* Free */
-
-void render_result_free(struct RenderResult *rr);
-void render_result_free_list(struct ListBase *lb, struct RenderResult *rr);
-
-/* Single Layer Render */
-
-void render_result_single_layer_begin(struct Render *re);
-void render_result_single_layer_end(struct Render *re);
-
-/* EXR Tile File Render */
-
-void render_result_save_empty_result_tiles(struct Render *re);
-void render_result_exr_file_begin(struct Render *re, struct RenderEngine *engine);
-void render_result_exr_file_end(struct Render *re, struct RenderEngine *engine);
-
-/* render pass wrapper for gpencil */
-struct RenderPass *render_layer_add_pass(struct RenderResult *rr,
- struct RenderLayer *rl,
- int channels,
- const char *name,
- const char *viewname,
- const char *chan_id);
-
-void render_result_exr_file_merge(struct RenderResult *rr,
- struct RenderResult *rrpart,
- const char *viewname);
-
-void render_result_exr_file_path(struct Scene *scene,
- const char *layname,
- int sample,
- char *filepath);
-int render_result_exr_file_read_path(struct RenderResult *rr,
- struct RenderLayer *rl_single,
- const char *filepath);
-
-/* EXR cache */
-
-void render_result_exr_file_cache_write(struct Render *re);
-bool render_result_exr_file_cache_read(struct Render *re);
-
-/* Combined Pixel Rect */
-
-struct ImBuf *render_result_rect_to_ibuf(struct RenderResult *rr,
- const struct RenderData *rd,
- const int view_id);
-
-void render_result_rect_fill_zero(struct RenderResult *rr, const int view_id);
-void render_result_rect_get_pixels(struct RenderResult *rr,
- unsigned int *rect,
- int rectx,
- int recty,
- const struct ColorManagedViewSettings *view_settings,
- const struct ColorManagedDisplaySettings *display_settings,
- const int view_id);
-
-void render_result_views_shallowcopy(struct RenderResult *dst, struct RenderResult *src);
-void render_result_views_shallowdelete(struct RenderResult *rr);
-bool render_result_has_views(struct RenderResult *rr);
-
-#define FOREACH_VIEW_LAYER_TO_RENDER_BEGIN(re_, iter_) \
- { \
- int nr_; \
- ViewLayer *iter_; \
- for (nr_ = 0, iter_ = (re_)->view_layers.first; iter_ != NULL; iter_ = iter_->next, nr_++) { \
- if (!G.background && (re_)->r.scemode & R_SINGLE_LAYER) { \
- if (nr_ != re->active_view_layer) { \
- continue; \
- } \
- } \
- else { \
- if ((iter_->flag & VIEW_LAYER_RENDER) == 0) { \
- continue; \
- } \
- }
-
-#define FOREACH_VIEW_LAYER_TO_RENDER_END \
- } \
- } \
- ((void)0)
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/source/blender/render/intern/include/render_types.h b/source/blender/render/intern/include/render_types.h
deleted file mode 100644
index 6be5fb4792c..00000000000
--- a/source/blender/render/intern/include/render_types.h
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-/* ------------------------------------------------------------------------- */
-/* exposed internal in render module only! */
-/* ------------------------------------------------------------------------- */
-
-#include "DNA_object_types.h"
-#include "DNA_scene_types.h"
-
-#include "BLI_threads.h"
-
-#include "BKE_main.h"
-
-#include "RE_pipeline.h"
-
-struct GHash;
-struct Main;
-struct Object;
-struct RenderEngine;
-struct ReportList;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* this is handed over to threaded hiding/passes/shading engine */
-typedef struct RenderPart {
- struct RenderPart *next, *prev;
-
- RenderResult *result; /* result of part rendering */
- ListBase fullresult; /* optional full sample buffers */
-
- rcti disprect; /* part coordinates within total picture */
- int rectx, recty; /* the size */
- int nr; /* nr is partnr */
- short status;
-} RenderPart;
-
-enum {
- /* PART_STATUS_NONE = 0, */ /* UNUSED */
- PART_STATUS_IN_PROGRESS = 1,
- PART_STATUS_RENDERED = 2,
- PART_STATUS_MERGED = 3,
-};
-
-/* controls state of render, everything that's read-only during render stage */
-struct Render {
- struct Render *next, *prev;
- char name[RE_MAXNAME];
- int slot;
-
- /* state settings */
- short flag, ok, result_ok;
-
- /* result of rendering */
- RenderResult *result;
- /* if render with single-layer option, other rendered layers are stored here */
- RenderResult *pushedresult;
- /* a list of RenderResults, for fullsample */
- ListBase fullresult;
- /* read/write mutex, all internal code that writes to re->result must use a
- * write lock, all external code must use a read lock. internal code is assumed
- * to not conflict with writes, so no lock used for that */
- ThreadRWMutex resultmutex;
-
- /** Window size, display rect, viewplane.
- * \note Buffer width and height with percentage applied
- * without border & crop. convert to long before multiplying together to avoid overflow. */
- int winx, winy;
- rcti disprect; /* part within winx winy */
- rctf viewplane; /* mapped on winx winy */
-
- /* final picture width and height (within disprect) */
- int rectx, recty;
-
- /* real maximum size of parts after correction for minimum
- * partx*xparts can be larger than rectx, in that case last part is smaller */
- int partx, party;
-
- /* Camera transform, only used by Freestyle. */
- float winmat[4][4];
-
- /* clippping */
- float clip_start;
- float clip_end;
-
- /* main, scene, and its full copy of renderdata and world */
- struct Main *main;
- Scene *scene;
- RenderData r;
- ListBase view_layers;
- int active_view_layer;
- struct Object *camera_override;
-
- ThreadRWMutex partsmutex;
- struct GHash *parts;
-
- /* render engine */
- struct RenderEngine *engine;
-
- /* NOTE: This is a minimal dependency graph and evaluated scene which is enough to access view
- * layer visibility and use for post-precessing (compositor and sequencer). */
- Depsgraph *pipeline_depsgraph;
- Scene *pipeline_scene_eval;
-
- /* callbacks */
- void (*display_init)(void *handle, RenderResult *rr);
- void *dih;
- void (*display_clear)(void *handle, RenderResult *rr);
- void *dch;
- void (*display_update)(void *handle, RenderResult *rr, volatile rcti *rect);
- void *duh;
- void (*current_scene_update)(void *handle, struct Scene *scene);
- void *suh;
-
- void (*stats_draw)(void *handle, RenderStats *ri);
- void *sdh;
- void (*progress)(void *handle, float i);
- void *prh;
-
- void (*draw_lock)(void *handle, int i);
- void *dlh;
- int (*test_break)(void *handle);
- void *tbh;
-
- RenderStats i;
-
- struct ReportList *reports;
-
- void **movie_ctx_arr;
- char viewname[MAX_NAME];
-
- /* TODO replace by a whole draw manager. */
- void *gl_context;
- void *gpu_context;
-};
-
-/* **************** defines ********************* */
-
-/* R.flag */
-#define R_ANIMATION 1
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/source/blender/render/intern/include/renderpipeline.h b/source/blender/render/intern/include/renderpipeline.h
deleted file mode 100644
index 062df59bfd3..00000000000
--- a/source/blender/render/intern/include/renderpipeline.h
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2006 Blender Foundation.
- * All rights reserved.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-struct ListBase;
-struct Render;
-struct RenderData;
-struct RenderLayer;
-struct RenderResult;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct RenderLayer *render_get_active_layer(struct Render *re, struct RenderResult *rr);
-void render_update_anim_renderdata(struct Render *re,
- struct RenderData *rd,
- struct ListBase *render_layers);
-void render_copy_renderdata(struct RenderData *to, struct RenderData *from);
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/source/blender/render/intern/include/texture.h b/source/blender/render/intern/include/texture.h
deleted file mode 100644
index 44ad508fe33..00000000000
--- a/source/blender/render/intern/include/texture.h
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define BRICONT \
- texres->tin = (texres->tin - 0.5f) * tex->contrast + tex->bright - 0.5f; \
- if (!(tex->flag & TEX_NO_CLAMP)) { \
- if (texres->tin < 0.0f) { \
- texres->tin = 0.0f; \
- } \
- else if (texres->tin > 1.0f) { \
- texres->tin = 1.0f; \
- } \
- } \
- ((void)0)
-
-#define BRICONTRGB \
- texres->tr = tex->rfac * ((texres->tr - 0.5f) * tex->contrast + tex->bright - 0.5f); \
- texres->tg = tex->gfac * ((texres->tg - 0.5f) * tex->contrast + tex->bright - 0.5f); \
- texres->tb = tex->bfac * ((texres->tb - 0.5f) * tex->contrast + tex->bright - 0.5f); \
- if (!(tex->flag & TEX_NO_CLAMP)) { \
- if (texres->tr < 0.0f) { \
- texres->tr = 0.0f; \
- } \
- if (texres->tg < 0.0f) { \
- texres->tg = 0.0f; \
- } \
- if (texres->tb < 0.0f) { \
- texres->tb = 0.0f; \
- } \
- } \
- if (tex->saturation != 1.0f) { \
- float _hsv[3]; \
- rgb_to_hsv(texres->tr, texres->tg, texres->tb, _hsv, _hsv + 1, _hsv + 2); \
- _hsv[1] *= tex->saturation; \
- hsv_to_rgb(_hsv[0], _hsv[1], _hsv[2], &texres->tr, &texres->tg, &texres->tb); \
- if ((tex->saturation > 1.0f) && !(tex->flag & TEX_NO_CLAMP)) { \
- if (texres->tr < 0.0f) { \
- texres->tr = 0.0f; \
- } \
- if (texres->tg < 0.0f) { \
- texres->tg = 0.0f; \
- } \
- if (texres->tb < 0.0f) { \
- texres->tb = 0.0f; \
- } \
- } \
- } \
- ((void)0)
-
-struct ImBuf;
-struct Image;
-struct ImagePool;
-struct Tex;
-struct TexResult;
-
-/* imagetexture.h */
-
-int imagewraposa(struct Tex *tex,
- struct Image *ima,
- struct ImBuf *ibuf,
- const float texvec[3],
- const float dxt[2],
- const float dyt[2],
- struct TexResult *texres,
- struct ImagePool *pool,
- const bool skip_load_image);
-int imagewrap(struct Tex *tex,
- struct Image *ima,
- const float texvec[3],
- struct TexResult *texres,
- struct ImagePool *pool,
- const bool skip_load_image);
-void image_sample(struct Image *ima,
- float fx,
- float fy,
- float dx,
- float dy,
- float result[4],
- struct ImagePool *pool);
-
-#ifdef __cplusplus
-}
-#endif
diff --git a/source/blender/render/intern/include/zbuf.h b/source/blender/render/intern/include/zbuf.h
deleted file mode 100644
index 41fa15c594f..00000000000
--- a/source/blender/render/intern/include/zbuf.h
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- */
-
-/** \file
- * \ingroup render
- */
-
-#pragma once
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* span fill in method, is also used to localize data for zbuffering */
-typedef struct ZSpan {
- int rectx, recty; /* range for clipping */
-
- int miny1, maxy1, miny2, maxy2; /* actual filled in range */
- const float *minp1, *maxp1, *minp2, *maxp2; /* vertex pointers detect min/max range in */
- float *span1, *span2;
-} ZSpan;
-
-void zbuf_alloc_span(struct ZSpan *zspan, int rectx, int recty);
-void zbuf_free_span(struct ZSpan *zspan);
-
-void zspan_scanconvert(struct ZSpan *zspan,
- void *handle,
- float *v1,
- float *v2,
- float *v3,
- void (*func)(void *, int, int, float, float));
-
-#ifdef __cplusplus
-}
-#endif