Commit: aa1e9f2e532c5cdb5eebac8e4cb491ee0cbfa252 Author: Sebastián Barschkis Date: Tue Jun 18 16:36:24 2019 +0200 Branches: fluid-mantaflow https://developer.blender.org/rBaa1e9f2e532c5cdb5eebac8e4cb491ee0cbfa252
Mantaflow: Removed old smoke code completely rip =================================================================== D intern/smoke/CMakeLists.txt D intern/smoke/extern/smoke_API.h D intern/smoke/intern/EIGENVALUE_HELPER.cpp D intern/smoke/intern/EIGENVALUE_HELPER.h D intern/smoke/intern/FFT_NOISE.h D intern/smoke/intern/FLUID_3D.cpp D intern/smoke/intern/FLUID_3D.h D intern/smoke/intern/FLUID_3D_SOLVERS.cpp D intern/smoke/intern/FLUID_3D_STATIC.cpp D intern/smoke/intern/IMAGE.h D intern/smoke/intern/INTERPOLATE.h D intern/smoke/intern/LICENSE.txt D intern/smoke/intern/LU_HELPER.cpp D intern/smoke/intern/LU_HELPER.h D intern/smoke/intern/MERSENNETWISTER.h D intern/smoke/intern/Makefile.FFT D intern/smoke/intern/Makefile.cygwin D intern/smoke/intern/Makefile.linux D intern/smoke/intern/Makefile.mac D intern/smoke/intern/OBSTACLE.h D intern/smoke/intern/SPHERE.cpp D intern/smoke/intern/SPHERE.h D intern/smoke/intern/VEC3.h D intern/smoke/intern/WAVELET_NOISE.h D intern/smoke/intern/WTURBULENCE.cpp D intern/smoke/intern/WTURBULENCE.h D intern/smoke/intern/smoke_API.cpp D intern/smoke/intern/tnt/jama_eig.h D intern/smoke/intern/tnt/jama_lu.h D intern/smoke/intern/tnt/tnt.h D intern/smoke/intern/tnt/tnt_array1d.h D intern/smoke/intern/tnt/tnt_array1d_utils.h D intern/smoke/intern/tnt/tnt_array2d.h D intern/smoke/intern/tnt/tnt_array2d_utils.h D intern/smoke/intern/tnt/tnt_array3d.h D intern/smoke/intern/tnt/tnt_array3d_utils.h D intern/smoke/intern/tnt/tnt_cmat.h D intern/smoke/intern/tnt/tnt_fortran_array1d.h D intern/smoke/intern/tnt/tnt_fortran_array1d_utils.h D intern/smoke/intern/tnt/tnt_fortran_array2d.h D intern/smoke/intern/tnt/tnt_fortran_array2d_utils.h D intern/smoke/intern/tnt/tnt_fortran_array3d.h D intern/smoke/intern/tnt/tnt_fortran_array3d_utils.h D intern/smoke/intern/tnt/tnt_i_refvec.h D intern/smoke/intern/tnt/tnt_math_utils.h D intern/smoke/intern/tnt/tnt_sparse_matrix_csr.h D intern/smoke/intern/tnt/tnt_stopwatch.h D intern/smoke/intern/tnt/tnt_subscript.h D intern/smoke/intern/tnt/tnt_vec.h D intern/smoke/intern/tnt/tnt_version.h M source/blender/editors/space_view3d/CMakeLists.txt M source/blender/gpu/CMakeLists.txt M source/blender/makesrna/intern/CMakeLists.txt M source/blender/render/CMakeLists.txt M source/tools =================================================================== diff --git a/intern/smoke/CMakeLists.txt b/intern/smoke/CMakeLists.txt deleted file mode 100644 index f59eebb86a8..00000000000 --- a/intern/smoke/CMakeLists.txt +++ /dev/null @@ -1,100 +0,0 @@ -# ***** BEGIN GPL LICENSE BLOCK ***** -# -# 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. -# ***** END GPL LICENSE BLOCK ***** - -set(INC - intern - ../memutil -) - -set(INC_SYS - ${BULLET_INCLUDE_DIRS} - ${PNG_INCLUDE_DIRS} - ${ZLIB_INCLUDE_DIRS} -) - -set(SRC - intern/EIGENVALUE_HELPER.cpp - intern/FLUID_3D.cpp - intern/FLUID_3D_SOLVERS.cpp - intern/FLUID_3D_STATIC.cpp - intern/LU_HELPER.cpp - intern/SPHERE.cpp - intern/WTURBULENCE.cpp - intern/smoke_API.cpp - - extern/smoke_API.h - intern/EIGENVALUE_HELPER.h - intern/FFT_NOISE.h - intern/FLUID_3D.h - intern/IMAGE.h - intern/INTERPOLATE.h - intern/LU_HELPER.h - intern/MERSENNETWISTER.h - intern/OBSTACLE.h - intern/SPHERE.h - intern/VEC3.h - intern/WAVELET_NOISE.h - intern/WTURBULENCE.h - intern/tnt/jama_eig.h - intern/tnt/jama_lu.h - intern/tnt/tnt.h - intern/tnt/tnt_array1d.h - intern/tnt/tnt_array1d_utils.h - intern/tnt/tnt_array2d.h - intern/tnt/tnt_array2d_utils.h - intern/tnt/tnt_array3d.h - intern/tnt/tnt_array3d_utils.h - intern/tnt/tnt_cmat.h - intern/tnt/tnt_fortran_array1d.h - intern/tnt/tnt_fortran_array1d_utils.h - intern/tnt/tnt_fortran_array2d.h - intern/tnt/tnt_fortran_array2d_utils.h - intern/tnt/tnt_fortran_array3d.h - intern/tnt/tnt_fortran_array3d_utils.h - intern/tnt/tnt_i_refvec.h - intern/tnt/tnt_math_utils.h - intern/tnt/tnt_sparse_matrix_csr.h - intern/tnt/tnt_stopwatch.h - intern/tnt/tnt_subscript.h - intern/tnt/tnt_vec.h - intern/tnt/tnt_version.h -) - -set(LIB -) - -# quiet -Wundef -add_definitions(-DDDF_DEBUG=0) - -if(WITH_OPENMP) - add_definitions(-DPARALLEL=1) -else() - add_definitions(-DPARALLEL=0) -endif() - -if(WITH_FFTW3) - add_definitions(-DWITH_FFTW3) - list(APPEND INC_SYS - ${FFTW3_INCLUDE_DIRS} - ) -endif() - -# (sebbas): intern/smoke deprecated -#blender_add_lib(bf_intern_smoke "${SRC}" "${INC}" "${INC_SYS}" "${LIB}") diff --git a/intern/smoke/extern/smoke_API.h b/intern/smoke/extern/smoke_API.h deleted file mode 100644 index 169f679526c..00000000000 --- a/intern/smoke/extern/smoke_API.h +++ /dev/null @@ -1,111 +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) 2009 by Daniel Genrich - * All rights reserved. - */ - -/** \file - * \ingroup smoke - */ - - -#ifndef SMOKE_API_H_ -#define SMOKE_API_H_ - -#ifdef __cplusplus -extern "C" { -#endif - -struct FLUID_3D; - -// low res -struct FLUID_3D *smoke_init(int *res, float dx, float dtdef, int use_heat, int use_fire, int use_colors); -void smoke_free(struct FLUID_3D *fluid); - -void smoke_initBlenderRNA(struct FLUID_3D *fluid, float *alpha, float *beta, float *dt_factor, float *vorticity, int *border_colli, float *burning_rate, - float *flame_smoke, float *flame_smoke_color, float *flame_vorticity, float *flame_ignition_temp, float *flame_max_temp); -void smoke_step(struct FLUID_3D *fluid, float gravity[3], float dtSubdiv); - -float *smoke_get_density(struct FLUID_3D *fluid); -float *smoke_get_flame(struct FLUID_3D *fluid); -float *smoke_get_fuel(struct FLUID_3D *fluid); -float *smoke_get_react(struct FLUID_3D *fluid); -float *smoke_get_color_r(struct FLUID_3D *fluid); -float *smoke_get_color_g(struct FLUID_3D *fluid); -float *smoke_get_color_b(struct FLUID_3D *fluid); -void smoke_get_rgba(struct FLUID_3D *fluid, float *data, int sequential); -void smoke_get_rgba_from_density(struct FLUID_3D *fluid, float color[3], float *data, int sequential); -float *smoke_get_heat(struct FLUID_3D *fluid); -float *smoke_get_velocity_x(struct FLUID_3D *fluid); -float *smoke_get_velocity_y(struct FLUID_3D *fluid); -float *smoke_get_velocity_z(struct FLUID_3D *fluid); - -/* Moving obstacle velocity provided by blender */ -void smoke_get_ob_velocity(struct FLUID_3D *fluid, float **x, float **y, float **z); - -float *smoke_get_force_x(struct FLUID_3D *fluid); -float *smoke_get_force_y(struct FLUID_3D *fluid); -float *smoke_get_force_z(struct FLUID_3D *fluid); - -unsigned char *smoke_get_obstacle(struct FLUID_3D *fluid); - -size_t smoke_get_index(int x, int max_x, int y, int max_y, int z); -size_t smoke_get_index2d(int x, int max_x, int y); - -void smoke_dissolve(struct FLUID_3D *fluid, int speed, int log); - -// wavelet turbulence functions -struct WTURBULENCE *smoke_turbulence_init(int *res, int amplify, int noisetype, const char *noisefile_path, int use_fire, int use_colors); -void smoke_turbulence_free(struct WTURBULENCE *wt); -void smoke_turbulence_step(struct WTURBULENCE *wt, struct FLUID_3D *fluid); - -float *smoke_turbulence_get_density(struct WTURBULENCE *wt); -float *smoke_turbulence_get_color_r(struct WTURBULENCE *wt); -float *smoke_turbulence_get_color_g(struct WTURBULENCE *wt); -float *smoke_turbulence_get_color_b(struct WTURBULENCE *wt); -void smoke_turbulence_get_rgba(struct WTURBULENCE *wt, float *data, int sequential); -void smoke_turbulence_get_rgba_from_density(struct WTURBULENCE *wt, float color[3], float *data, int sequential); -float *smoke_turbulence_get_flame(struct WTURBULENCE *wt); -float *smoke_turbulence_get_fuel(struct WTURBULENCE *wt); -float *smoke_turbulence_get_react(struct WTURBULENCE *wt); -void smoke_turbulence_get_res(struct WTURBULENCE *wt, int *res); -int smoke_turbulence_get_cells(struct WTURBULENCE *wt); -void smoke_turbulence_set_noise(struct WTURBULENCE *wt, int type, const char *noisefile_path); -void smoke_initWaveletBlenderRNA(struct WTURBULENCE *wt, float *strength); -void smoke_dissolve_wavelet(struct WTURBULENCE *wt, int speed, int log); - -/* export */ -void smoke_export(struct FLUID_3D *fluid, float *dt, float *dx, float **dens, float **react, float **flame, float **fuel, float **heat, float **heatold, - float **vx, float **vy, float **vz, float **r, float **g, float **b, unsigned char **obstacles); -void smoke_turbulence_export(struct WTURBULENCE *wt, float **dens, float **react, float **flame, float **fuel, - float **r, float **g, float **b, float **tcu, float **tcv, float **tcw); - -/* data fields */ -int smoke_has_heat(struct FLUID_3D *fluid); -int smoke_has_fuel(struct FLUID_3D *fluid); -int smoke_has_colors(struct FLUID_3D *fluid); -int smoke_turbulence_has_fuel(struct WTURBULENCE *wt); -int smoke_turbulence_has_colors(struct WTURBULENCE *wt); - -void smoke_ensure_heat(struct FLUID_3D *fluid); -void smoke_ensure_fire(struct FLUID_3D *fluid, struct WTURBULENCE *wt); -void smoke_ensure_colors(struct FLUID_3D *fluid, struct WTURBULENCE *wt, float init_r, float init_g, float init_b); - -#ifdef __cplusplus -} -#endif - -#endif /* SMOKE_API_H_ */ diff --git a/intern/smoke/intern/EIGENVALUE_HELPER.cpp b/intern/smoke/intern/EIGENVALUE_HELPER.cpp deleted file mode 100644 index fbfd6d3bd22..00000000000 --- a/intern/smoke/intern/EIGENVALUE_HELPER.cpp +++ /dev/null @@ -1,888 +0,0 @@ -/** \file - * \ingroup smoke - */ - -#include "EIGENVALUE_HELPER.h" - - -void Eigentred2(sEigenvalue& eval) { - - // This is derived from the Algol procedures tred2 by - // Bowdler, Martin, Reinsch, and Wilkinson, Handbook for - // Auto. Comp., Vol.ii-Linear Algebra, and the corresponding - // Fortran subroutine in EISPACK. - - int n=eval.n; - - for (int j = 0; j < n; j++) { - eval.d[j] = eval.V[n-1][j]; - } - - // Householder reduction to tridiagonal form. - - for (int i = n-1; i > 0; i--) { - - // Scale to avoid under/overflow. - - float scale = 0.0; - float h = 0.0; - for (int k = 0; k < i; k++) { - scale = scale + fabs(eval.d[k]); - } - if (scale == 0.0f) { - eval.e[i] = eval.d[i-1]; - for (int j = 0; j < i; j++) { - eval.d[j] = eval.V[i-1][j]; - eval.V[i][j] = 0.0; - eval.V[j][i] = 0.0; - } - } else { - - // Generate Householder vector. - - for (int k = 0; k < i; k++) { - eval.d[k] /= scale; - h += eval.d[k] * eval.d[k]; - } - float f = eval.d[i-1]; - float g = sqrt(h); - if (f > 0) { - g = -g; - } - eval.e[i] = scale * g; - h = h - f * g; - eval.d[i-1] = f - g; - for (int j = 0; j < i; j++) { - eval.e[j] = 0.0; - } - - // Apply similarity transformation to remaining columns. - - for (int j = 0; j < i; j++) { - f = eval.d[j]; - eval.V[j][i] = f; - g = eval.e[j] + eval.V[j][j] * f; - for (int k = j+1; k <= i-1; @@ Diff output truncated at 10240 characters. @@ _______________________________________________ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs