|
Blender V4.3
|
#include "MEM_guardedalloc.h"#include <cmath>#include <cstdio>#include "BLI_blenlib.h"#include "BLI_kdtree.h"#include "BLI_math_color.h"#include "BLI_math_geom.h"#include "BLI_math_matrix.h"#include "BLI_math_vector.h"#include "BLI_string_utils.hh"#include "BLI_task.h"#include "BLI_threads.h"#include "BLI_utildefines.h"#include "BLT_translation.hh"#include "DNA_anim_types.h"#include "DNA_armature_types.h"#include "DNA_collection_types.h"#include "DNA_constraint_types.h"#include "DNA_dynamicpaint_types.h"#include "DNA_material_types.h"#include "DNA_mesh_types.h"#include "DNA_meshdata_types.h"#include "DNA_modifier_types.h"#include "DNA_object_force_types.h"#include "DNA_object_types.h"#include "DNA_scene_types.h"#include "DNA_texture_types.h"#include "BKE_armature.hh"#include "BKE_bvhutils.hh"#include "BKE_collection.hh"#include "BKE_collision.h"#include "BKE_colorband.hh"#include "BKE_constraint.h"#include "BKE_customdata.hh"#include "BKE_deform.hh"#include "BKE_dynamicpaint.h"#include "BKE_effect.h"#include "BKE_image.hh"#include "BKE_image_format.hh"#include "BKE_lib_id.hh"#include "BKE_main.hh"#include "BKE_material.h"#include "BKE_mesh.hh"#include "BKE_mesh_mapping.hh"#include "BKE_mesh_runtime.hh"#include "BKE_modifier.hh"#include "BKE_object.hh"#include "BKE_particle.h"#include "BKE_pointcache.h"#include "BKE_scene.hh"#include "DEG_depsgraph.hh"#include "DEG_depsgraph_query.hh"#include "IMB_imbuf.hh"#include "IMB_imbuf_types.hh"#include "RE_texture.h"#include "atomic_ops.h"#include "CLG_log.h"Go to the source code of this file.
Classes | |
| struct | Bounds2D |
| struct | Bounds3D |
| struct | DynamicPaintVolumeGrid |
| struct | Vec3f |
| struct | BakeAdjPoint |
| struct | PaintBakeNormal |
| struct | PaintBakeData |
| struct | PaintUVPoint |
| struct | ImgSeqFormatData |
| struct | PaintAdjData |
| struct | DynamicPaintSetInitColorData |
| struct | DynamicPaintModifierApplyData |
| struct | DynamicPaintCreateUVSurfaceData |
| struct | DynamicPaintFindIslandBorderData |
| struct | DynamicPaintOutputSurfaceImageData |
| struct | DynamicPaintBrushVelocityData |
| struct | DynamicPaintPaintData |
| struct | DynamicPaintEffectData |
| struct | DynamicPaintDissolveDryData |
| struct | DynamicPaintGenerateBakeData |
Macros | |
| #define | SUBFRAME_RECURSION 5 |
| #define | BRUSH_USES_VELOCITY (1 << 0) |
| #define | HIT_VOLUME 1 |
| #define | HIT_PROXIMITY 2 |
| #define | NOT_FOUND -1 |
| #define | ON_MESH_EDGE -2 |
| #define | OUT_OF_TEXTURE -3 |
| #define | EFF_MOVEMENT_PER_FRAME 0.05f |
| #define | WAVE_TIME_FAC (1.0f / 24.0f) |
| #define | CANVAS_REL_SIZE 5.0f |
| #define | MIN_WETNESS 0.001f |
| #define | MAX_WETNESS 5.0f |
| #define | ADJ_ON_MESH_EDGE (1 << 0) |
| #define | ADJ_BORDER_PIXEL (1 << 1) |
Variables | |
| static CLG_LogRef | LOG = {"bke.dynamicpaint"} |
| static const float | gaussianFactors [5] |
| static const float | gaussianTotal = 3.309425f |
| static int | neighX [8] = {1, 1, 0, -1, -1, -1, 0, 1} |
| static int | neighY [8] = {0, 1, 1, 1, 0, -1, -1, -1} |
| static int | neighStraightX [8] = {1, 0, -1, 0, 1, -1, -1, 1} |
| static int | neighStraightY [8] = {0, 1, 0, -1, 1, 1, -1, -1} |
Image Sequence / UV Image Surface Calls | |
| #define | JITTER_SAMPLES |
| static void | dynamic_paint_create_uv_surface_direct_cb (void *__restrict userdata, const int ty, const TaskParallelTLS *__restrict) |
| static void | dynamic_paint_create_uv_surface_neighbor_cb (void *__restrict userdata, const int ty, const TaskParallelTLS *__restrict) |
| static float | dist_squared_to_corner_tris_uv_edges (const blender::Span< int3 > corner_tris, const float(*mloopuv)[2], int tri_index, const float point[2]) |
| static void | dynamic_paint_find_island_border (const DynamicPaintCreateUVSurfaceData *data, DynamicPaintFindIslandBorderData *bdata, int tri_index, const float pixel[2], int in_edge, int depth) |
| static int | dynamic_paint_find_neighbor_pixel (const DynamicPaintCreateUVSurfaceData *data, const MeshElemMap *vert_to_tri_map, const int w, const int h, const int px, const int py, const int n_index) |
| static bool | dynamicPaint_pointHasNeighbor (PaintAdjData *ed, int index, int neighbor) |
| static bool | dynamicPaint_symmetrizeAdjData (PaintAdjData *ed, int active_points) |
| int | dynamicPaint_createUVSurface (Scene *scene, DynamicPaintSurface *surface, float *progress, bool *do_update) |
| static void | dynamic_paint_output_surface_image_paint_cb (void *__restrict userdata, const int index, const TaskParallelTLS *__restrict) |
| static void | dynamic_paint_output_surface_image_displace_cb (void *__restrict userdata, const int index, const TaskParallelTLS *__restrict) |
| static void | dynamic_paint_output_surface_image_wave_cb (void *__restrict userdata, const int index, const TaskParallelTLS *__restrict) |
| static void | dynamic_paint_output_surface_image_wetmap_cb (void *__restrict userdata, const int index, const TaskParallelTLS *__restrict) |
| void | dynamicPaint_outputSurfaceImage (DynamicPaintSurface *surface, const char *filepath, short output_layer) |
| #define ADJ_BORDER_PIXEL (1 << 1) |
Definition at line 238 of file dynamicpaint.cc.
Referenced by dynamic_paint_border_cb(), dynamic_paint_effect_drip_cb(), dynamic_paint_effect_shrink_cb(), dynamic_paint_effect_spread_cb(), dynamicPaint_createUVSurface(), dynamicPaint_doSmudge(), and dynamicPaint_symmetrizeAdjData().
| #define ADJ_ON_MESH_EDGE (1 << 0) |
Definition at line 237 of file dynamicpaint.cc.
Referenced by dynamic_paint_wave_step_cb(), dynamicPaint_createUVSurface(), and dynamicPaint_initAdjacencyData().
| #define BRUSH_USES_VELOCITY (1 << 0) |
Definition at line 108 of file dynamicpaint.cc.
Referenced by dynamicPaint_generateBakeData(), and surface_getBrushFlags().
| #define CANVAS_REL_SIZE 5.0f |
Definition at line 120 of file dynamicpaint.cc.
Referenced by dynamicPaint_doEffectStep(), dynamicPaint_doWaveStep(), and dynamicPaint_prepareEffectStep().
| #define EFF_MOVEMENT_PER_FRAME 0.05f |
Definition at line 117 of file dynamicpaint.cc.
Referenced by dynamicPaint_doEffectStep(), and dynamicPaint_prepareEffectStep().
| #define HIT_PROXIMITY 2 |
Definition at line 111 of file dynamicpaint.cc.
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
| #define HIT_VOLUME 1 |
Definition at line 110 of file dynamicpaint.cc.
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
| #define JITTER_SAMPLES |
Definition at line 2202 of file dynamicpaint.cc.
Referenced by dynamic_paint_create_uv_surface_direct_cb(), and dynamic_paint_create_uv_surface_neighbor_cb().
| #define MAX_WETNESS 5.0f |
Definition at line 123 of file dynamicpaint.cc.
Referenced by dynamic_paint_effect_drip_cb().
| #define MIN_WETNESS 0.001f |
Definition at line 122 of file dynamicpaint.cc.
Referenced by dynamic_paint_effect_spread_cb(), dynamic_paint_surface_pre_step_cb(), dynamicPaint_mixPaintColors(), and value_dissolve().
| #define NOT_FOUND -1 |
Definition at line 113 of file dynamicpaint.cc.
Referenced by dynamic_paint_find_island_border(), dynamic_paint_find_neighbor_pixel(), and blender::io::obj::OBJMesh::get_face_deform_group_index().
| #define ON_MESH_EDGE -2 |
Definition at line 114 of file dynamicpaint.cc.
Referenced by dynamic_paint_find_island_border(), and dynamicPaint_createUVSurface().
| #define OUT_OF_TEXTURE -3 |
Definition at line 115 of file dynamicpaint.cc.
Referenced by dynamic_paint_find_island_border(), dynamic_paint_find_neighbor_pixel(), and dynamicPaint_createUVSurface().
| #define SUBFRAME_RECURSION 5 |
Definition at line 106 of file dynamicpaint.cc.
Referenced by dynamicPaint_brushMeshCalculateVelocity(), dynamicPaint_brushObjectCalculateVelocity(), and dynamicPaint_doStep().
| #define WAVE_TIME_FAC (1.0f / 24.0f) |
Definition at line 119 of file dynamicpaint.cc.
Referenced by dynamicPaint_doWaveStep().
|
static |
Definition at line 477 of file dynamicpaint.cc.
References copy_v3_v3().
Referenced by dynamic_paint_apply_surface_vpaint_blend_cb(), dynamic_paint_output_surface_image_paint_cb(), dynamic_paint_surface_pre_step_cb(), and dynamicPaint_mixPaintColors().
Definition at line 610 of file dynamicpaint.cc.
References b, copy_v3_v3(), and minmax_v3v3_v3().
Referenced by dynamicPaint_generateBakeData(), dynamicPaint_paintMesh(), dynamicPaint_paintParticles(), grid_bound_insert_cb_ex(), grid_bound_insert_reduce(), and surfaceGenerateGrid().
Definition at line 596 of file dynamicpaint.cc.
References b.
Referenced by dynamicPaint_paintParticles().
Definition at line 568 of file dynamicpaint.cc.
References Bounds3D::max, Bounds3D::min, and Bounds3D::valid.
Referenced by meshBrush_boundsIntersect().
Definition at line 582 of file dynamicpaint.cc.
References Bounds3D::max, Bounds3D::min, and Bounds3D::valid.
Referenced by dynamicPaint_paintParticles(), and meshBrush_boundsIntersect().
|
static |
Definition at line 2086 of file dynamicpaint.cc.
References BKE_id_free(), BKE_mesh_copy_for_eval(), DynamicPaintRuntime::canvas_mesh, dynamicPaint_Modifier_runtime_ensure(), and DynamicPaintCanvasSettings::pmd.
Referenced by dynamicPaint_frameUpdate().
|
static |
Definition at line 2416 of file dynamicpaint.cc.
References BLI_assert, dist_squared_to_line_segment_v2(), and FLT_MAX.
Referenced by dynamic_paint_find_island_border().
|
static |
Definition at line 1813 of file dynamicpaint.cc.
References DynamicPaintSurface::data, madd_v3_v3fl(), and PaintSurfaceData::type_data.
Referenced by dynamicPaint_applySurfaceDisplace().
|
static |
Definition at line 1852 of file dynamicpaint.cc.
References blendColors(), and float.
Referenced by dynamicPaint_Modifier_apply().
|
static |
Definition at line 1867 of file dynamicpaint.cc.
References MLoopCol::a, MLoopCol::b, float, MLoopCol::g, MLoopCol::r, rgba_float_to_uchar(), and unit_float_to_uchar_clamp.
Referenced by dynamicPaint_Modifier_apply().
|
static |
Definition at line 1902 of file dynamicpaint.cc.
References PaintWavePoint::height, and madd_v3_v3fl().
Referenced by dynamicPaint_Modifier_apply().
|
static |
Definition at line 5569 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, BLI_assert, PaintAdjData::border, PaintPoint::color, PaintPoint::e_color, PaintAdjData::flags, madd_v3_v3fl(), mul_v3_v3fl(), PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, PaintSurfaceData::type_data, and PaintPoint::wetness.
Referenced by dynamicPaint_doBorderStep().
|
static |
Definition at line 3769 of file dynamicpaint.cc.
References copy_v3_v3(), float, mul_m4_v3(), mul_v3_fl(), sub_v3_v3v3(), and v.
Referenced by dynamicPaint_brushMeshCalculateVelocity().
|
static |
Definition at line 2221 of file dynamicpaint.cc.
References barycentric_weights_v2(), float, blender::Span< T >::index_range(), isect_point_tri_v2(), JITTER_SAMPLES, Bounds2D::max, Bounds2D::min, min, MOD_DPAINT_ANTIALIAS, PaintUVPoint::neighbor_pixel, PaintUVPoint::pixel_index, sample, PaintUVPoint::tri_index, v, PaintUVPoint::v1, PaintUVPoint::v2, PaintUVPoint::v3, and w().
Referenced by dynamicPaint_createUVSurface().
|
static |
Definition at line 2318 of file dynamicpaint.cc.
References atomic_add_and_fetch_uint32(), barycentric_weights_v2(), float, JITTER_SAMPLES, MOD_DPAINT_ANTIALIAS, PaintUVPoint::neighbor_pixel, neighStraightX, neighStraightY, PaintUVPoint::tri_index, v, PaintUVPoint::v1, PaintUVPoint::v2, PaintUVPoint::v3, and w().
Referenced by dynamicPaint_createUVSurface().
|
static |
Definition at line 5348 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, atomic_fetch_and_and_uint8(), atomic_fetch_and_or_uint8(), PaintSurfaceData::bData, BLI_assert, PaintBakeData::bNeighs, CLAMP, CLAMP_MAX, BakeAdjPoint::dist, PaintPoint::e_color, PaintAdjData::flags, MAX_WETNESS, min_ff(), mixColors(), PaintAdjData::n_target, ret, surface_determineForceTargetPoints(), PaintSurfaceData::type_data, and PaintPoint::wetness.
Referenced by dynamicPaint_doEffectStep().
|
static |
Definition at line 5290 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, PaintSurfaceData::bData, PaintBakeData::bNeighs, CLAMP_MIN, PaintPoint::color, BakeAdjPoint::dist, PaintPoint::e_color, PaintAdjData::flags, max_ff(), PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, PaintSurfaceData::type_data, and PaintPoint::wetness.
Referenced by dynamicPaint_doEffectStep().
|
static |
Processes active effect step.
Definition at line 5231 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, PaintSurfaceData::bData, PaintBakeData::bNeighs, CLAMP, BakeAdjPoint::dist, PaintPoint::e_color, PaintAdjData::flags, min_ff(), min_fff(), MIN_WETNESS, mixColors(), PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, PaintSurfaceData::type_data, and PaintPoint::wetness.
Referenced by dynamicPaint_doEffectStep().
|
static |
Definition at line 2532 of file dynamicpaint.cc.
References DynamicPaintFindIslandBorderData::best_index, DynamicPaintFindIslandBorderData::best_weight, CLAMP, closest_to_line_v2(), copy_v2_v2(), dist_squared_to_corner_tris_uv_edges(), dist_squared_to_line_segment_v2(), dynamic_paint_find_island_border(), ELEM, equals_v2v2(), float, floorf, DynamicPaintFindIslandBorderData::h, MeshElemMap::indices, int, line_point_side_v2(), madd_v2_v2v2fl(), PaintUVPoint::neighbor_pixel, NOT_FOUND, ON_MESH_EDGE, OUT_OF_TEXTURE, DynamicPaintFindIslandBorderData::px, DynamicPaintFindIslandBorderData::py, square_f(), sub_v2_v2v2(), PaintUVPoint::tri_index, DynamicPaintFindIslandBorderData::vert_to_tri_map, DynamicPaintFindIslandBorderData::w, and w().
Referenced by dynamic_paint_find_island_border(), and dynamic_paint_find_neighbor_pixel().
|
static |
Definition at line 2460 of file dynamicpaint.cc.
References dynamic_paint_find_island_border(), float, PaintUVPoint::neighbor_pixel, neighX, neighY, NOT_FOUND, OUT_OF_TEXTURE, PaintUVPoint::tri_index, DynamicPaintFindIslandBorderData::vert_to_tri_map, w(), x, and y.
Referenced by dynamicPaint_createUVSurface().
|
static |
Definition at line 5964 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, ImgSeqFormatData::barycentricWeights, PaintSurfaceData::bData, PaintBakeData::bNormal, PaintBakeData::clear, copy_v3_v3(), ELEM, PaintSurfaceData::format_data, interp_v3_v3v3v3(), PaintBakeNormal::invNorm, len_v3(), madd_v3_v3fl(), MOD_DPAINT_ANTIALIAS, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_WAVE, mul_mat3_m4_v3(), mul_v3_fl(), mul_v3_v3v3(), PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, negate_v3_v3(), PaintBakeNormal::normal_scale, normalize_v3(), PaintBakeData::realCoord, PaintBakeData::s_num, PaintBakeData::s_pos, Object::scale, sub_v3_v3v3(), ImgSeqFormatData::uv_p, Vec3f::v, PaintUVPoint::v1, PaintUVPoint::v2, PaintUVPoint::v3, and PaintBakeData::velocity.
Referenced by dynamicPaint_generateBakeData().
|
static |
Definition at line 3244 of file dynamicpaint.cc.
References CLAMP, copy_v3_fl(), ImBufFloatBuffer::data, ImBuf::float_buffer, MOD_DPAINT_DISP_DISPLACE, and pos.
Referenced by dynamicPaint_outputSurfaceImage().
|
static |
Definition at line 3217 of file dynamicpaint.cc.
References blendColors(), ImBufFloatBuffer::data, ImBuf::float_buffer, MOD_DPAINT_MULALPHA, mul_v3_fl(), and pos.
Referenced by dynamicPaint_outputSurfaceImage().
|
static |
Definition at line 3271 of file dynamicpaint.cc.
References CLAMP, copy_v3_fl(), ImBufFloatBuffer::data, ImBuf::float_buffer, PaintWavePoint::height, and pos.
Referenced by dynamicPaint_outputSurfaceImage().
|
static |
Definition at line 3297 of file dynamicpaint.cc.
References copy_v3_fl(), ImBufFloatBuffer::data, ImBuf::float_buffer, and pos.
Referenced by dynamicPaint_outputSurfaceImage().
|
static |
Definition at line 3957 of file dynamicpaint.cc.
References add_v3_fl(), DynamicPaintBrushSettings::b, PaintSurfaceData::bData, BKE_colorband_evaluate(), BLI_bvhtree_find_nearest(), BLI_bvhtree_ray_cast(), PaintBakeData::bNormal, PaintBakeData::brush_velocity, BVH_RAYCAST_DIST_MAX, CLAMP, DynamicPaintBrushSettings::collision, copy_v3_v3(), dot(), dot_v3v3(), dynamicPaint_updatePointData(), ELEM, DynamicPaintBrushSettings::flags, float, DynamicPaintBrushSettings::g, gaussianFactors, gaussianTotal, PaintBakeData::grid, HIT_PROXIMITY, HIT_VOLUME, interp_v3_v3v3v3(), interp_weights_tri_v3(), PaintBakeNormal::invNorm, madd_v3_v3v3fl(), mesh_tris_nearest_point_dp(), mesh_tris_spherecast_dp(), MOD_DPAINT_COL_DIST, MOD_DPAINT_COL_VOLDIST, MOD_DPAINT_COL_VOLUME, MOD_DPAINT_DO_SMUDGE, MOD_DPAINT_INVERSE_PROX, MOD_DPAINT_NEGATE_VOLUME, MOD_DPAINT_PRFALL_CONSTANT, MOD_DPAINT_PRFALL_RAMP, MOD_DPAINT_PROX_PROJECT, MOD_DPAINT_RAMP_ALPHA, MOD_DPAINT_RAY_BRUSH_AVG, MOD_DPAINT_RAY_CANVAS, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_USES_VELOCITY, negate_v3(), PaintBakeNormal::normal_scale, normal_tri_v3(), normalize_v3(), DynamicPaintBrushSettings::paint_ramp, DynamicPaintBrushSettings::proximity_falloff, DynamicPaintBrushSettings::r, DynamicPaintBrushSettings::ray_dir, PaintBakeData::realCoord, PaintBakeData::s_num, PaintBakeData::s_pos, sqrtf, sub_v3_v3v3(), BVHTreeFromMesh::tree, v, Vec3f::v, v2, and PaintBakeData::velocity.
Referenced by dynamicPaint_paintMesh().
|
static |
Definition at line 4415 of file dynamicpaint.cc.
References PaintSurfaceData::bData, PaintBakeData::bNormal, PaintBakeData::brush_velocity, CLAMP_MIN, copy_v3_v3(), dynamicPaint_updatePointData(), ELEM, DynamicPaintBrushSettings::flags, PaintBakeData::grid, max_ff(), MEM_freeN(), MOD_DPAINT_DO_SMUDGE, MOD_DPAINT_PART_RAD, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_USES_VELOCITY, mul_v3_v3fl(), PaintBakeNormal::normal_scale, normalize_v3(), ParticleSystem::part, DynamicPaintBrushSettings::particle_smooth, ParticleSystem::particles, DynamicPaintBrushSettings::r, PaintBakeData::realCoord, PaintBakeData::s_pos, ParticleData::size, smooth(), sqrtf, ParticleData::state, str, sub_v3_v3(), ParticleSettings::timetweak, tree, Vec3f::v, ParticleKey::vel, and PaintBakeData::velocity.
Referenced by dynamicPaint_paintParticles().
|
static |
Definition at line 4705 of file dynamicpaint.cc.
References DynamicPaintBrushSettings::b, PaintSurfaceData::bData, BKE_colorband_evaluate(), PaintBakeData::bNormal, PaintBakeData::brush_velocity, CLAMP, copy_v3_v3(), dynamicPaint_updatePointData(), ELEM, DynamicPaintBrushSettings::flags, DynamicPaintBrushSettings::g, len_v3(), len_v3v3(), max_ff(), MOD_DPAINT_DO_SMUDGE, MOD_DPAINT_PRFALL_RAMP, MOD_DPAINT_PRFALL_SMOOTH, MOD_DPAINT_RAMP_ALPHA, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_USES_VELOCITY, mul_v3_v3fl(), PaintBakeNormal::normal_scale, DynamicPaintBrushSettings::paint_ramp, DynamicPaintBrushSettings::proximity_falloff, DynamicPaintBrushSettings::r, PaintBakeData::realCoord, PaintBakeData::s_pos, sqrtf, sub_v3_v3v3(), Vec3f::v, and PaintBakeData::velocity.
Referenced by dynamicPaint_paintSinglePoint().
|
static |
Definition at line 4849 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, PaintSurfaceData::bData, PaintBakeData::bNeighs, BakeAdjPoint::dist, PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, normalize_v3(), PaintBakeData::realCoord, PaintBakeData::s_pos, sub_v3_v3v3(), and Vec3f::v.
Referenced by dynamicPaint_prepareAdjacencyData().
|
static |
Definition at line 5106 of file dynamicpaint.cc.
References PaintSurfaceData::bData, BKE_effectors_apply(), copy_v3_v3(), madd_v3_v3fl(), normalize_v3_v3(), pd_point_from_loc(), PHYS_GLOBAL_GRAVITY, PaintBakeData::prev_velocity, PaintBakeData::realCoord, PaintBakeData::s_pos, sub_v3_v3(), Vec3f::v, EffectedPoint::vel_to_sec, and PaintBakeData::velocity.
Referenced by dynamicPaint_prepareEffectStep().
|
static |
Definition at line 1543 of file dynamicpaint.cc.
References ImgSeqFormatData::barycentricWeights, PaintPoint::color, copy_v2_v2(), copy_v3_v3(), float, PaintSurfaceData::format_data, interp_v3_v3v3v3(), MOD_DPAINT_ANTIALIAS, multitex_ext_safe(), tex, TexResult::tin, TexResult::trgba, PaintUVPoint::tri_index, PaintSurfaceData::type_data, ImgSeqFormatData::uv_p, and Vec3f::v.
Referenced by dynamicPaint_setInitialColor().
|
static |
Definition at line 1509 of file dynamicpaint.cc.
References PaintPoint::color, copy_v3_v3(), float, multitex_ext_safe(), tex, TexResult::tin, TexResult::trgba, and PaintSurfaceData::type_data.
Referenced by dynamicPaint_setInitialColor().
|
static |
Definition at line 1581 of file dynamicpaint.cc.
References ImgSeqFormatData::barycentricWeights, copy_v4_v4(), PaintSurfaceData::format_data, interp_v4_v4v4v4(), MOD_DPAINT_ANTIALIAS, rgba_uchar_to_float(), PaintUVPoint::tri_index, PaintSurfaceData::type_data, UNPACK3, ImgSeqFormatData::uv_p, and Vec3f::v.
Referenced by dynamicPaint_setInitialColor().
|
static |
Definition at line 5815 of file dynamicpaint.cc.
References ELEM, MOD_DPAINT_DISSOLVE, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WEIGHT, and MOD_DPAINT_USE_DRYING.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 5828 of file dynamicpaint.cc.
References blendColors(), CLAMP, CLAMP_MIN, PaintPoint::color, copy_v4_v4(), DPAINT_PAINT_DRY, DPAINT_PAINT_WET, PaintPoint::e_color, ELEM, MIN_WETNESS, MOD_DPAINT_DISSOLVE, MOD_DPAINT_DISSOLVE_LOG, MOD_DPAINT_DRY_LOG, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WEIGHT, MOD_DPAINT_USE_DRYING, PaintPoint::state, PaintSurfaceData::type_data, value_dissolve(), and PaintPoint::wetness.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 5648 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, ADJ_ON_MESH_EDGE, PaintSurfaceData::bData, PaintBakeData::bNeighs, PaintWavePoint::brush_isect, CLAMP_MIN, BakeAdjPoint::dist, DPAINT_WAVE_NONE, PaintAdjData::flags, PaintWavePoint::height, MOD_DPAINT_WAVE_OPEN_BORDERS, PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, PaintWavePoint::state, PaintSurfaceData::type_data, and PaintWavePoint::velocity.
Referenced by dynamicPaint_doWaveStep().
|
static |
Definition at line 1340 of file dynamicpaint.cc.
References MEM_callocN, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_SURFACE_T_WEIGHT, N_, setError(), PaintSurfaceData::total_points, and PaintSurfaceData::type_data.
Referenced by dynamicPaint_createUVSurface(), and dynamicPaint_resetSurface().
|
static |
Apply displacing vertex surface to the evaluated-mesh.
Definition at line 1829 of file dynamicpaint.cc.
References BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), dynamic_paint_apply_surface_displace_cb(), MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_DISPLACE, DynamicPaintModifierApplyData::surface, and PaintSurfaceData::total_points.
Referenced by dynamicPaint_calculateFrame(), and dynamicPaint_Modifier_apply().
|
static |
Definition at line 290 of file dynamicpaint.cc.
References DynamicPaintRuntime::brush_mesh, DynamicPaintModifierData::modifier, DynamicPaintBrushSettings::pmd, and ModifierData::runtime.
Referenced by dynamicPaint_brushMeshCalculateVelocity(), dynamicPaint_paintMesh(), and dynamicPaint_paintSinglePoint().
|
static |
Definition at line 3798 of file dynamicpaint.cc.
References BKE_id_free(), BKE_mesh_copy_for_eval(), BKE_object_modifier_update_subframe(), BKE_scene_ctime_get(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), DynamicPaintBrushVelocityData::brush_vel, copy_m4_m4(), depsgraph, dynamic_paint_brush_velocity_compute_cb(), dynamicPaint_brush_mesh_get(), eModifierType_DynamicPaint, float, MEM_mallocN, SUBFRAME_RECURSION, and Mesh::verts_num.
Referenced by dynamicPaint_paintMesh().
|
static |
Definition at line 3883 of file dynamicpaint.cc.
References BKE_object_modifier_update_subframe(), BKE_scene_ctime_get(), copy_m4_m4(), depsgraph, eModifierType_DynamicPaint, mul_m4_v3(), mul_v3_fl(), sub_v3_v3v3(), SUBFRAME_RECURSION, and Vec3f::v.
Referenced by dynamicPaint_paintSinglePoint().
| void dynamicPaint_cacheUpdateFrames | ( | struct DynamicPaintSurface * | surface | ) |
Update cache frame range.
Definition at line 2078 of file dynamicpaint.cc.
| int dynamicPaint_calculateFrame | ( | struct DynamicPaintSurface * | surface, |
| struct Depsgraph * | depsgraph, | ||
| struct Scene * | scene, | ||
| struct Object * | cObject, | ||
| int | frame ) |
Calculate a single frame and included sub-frames for surface.
Definition at line 6403 of file dynamicpaint.cc.
References depsgraph, dynamicPaint_applySurfaceDisplace(), dynamicPaint_canvas_mesh_get(), dynamicPaint_doStep(), dynamicPaint_generateBakeData(), float, and MOD_DPAINT_DISP_INCREMENTAL.
Referenced by dynamicPaint_bakeImageSequence(), and dynamicPaint_frameUpdate().
|
static |
Definition at line 281 of file dynamicpaint.cc.
References DynamicPaintRuntime::canvas_mesh, DynamicPaintModifierData::modifier, DynamicPaintCanvasSettings::pmd, and ModifierData::runtime.
Referenced by dynamicPaint_calculateFrame(), dynamicPaint_createUVSurface(), dynamicPaint_generateBakeData(), dynamicPaint_initAdjacencyData(), dynamicPaint_setInitialColor(), dynamicPaint_surfaceHasMoved(), and dynamicPaint_surfaceNumOfPoints().
|
static |
Definition at line 1788 of file dynamicpaint.cc.
References dynamicPaint_resetSurface(), and dynamicPaint_surfaceNumOfPoints().
Referenced by dynamicPaint_frameUpdate().
| void dynamicPaint_clearSurface | ( | const Scene * | scene, |
| DynamicPaintSurface * | surface ) |
Definition at line 1723 of file dynamicpaint.cc.
References PaintSurfaceData::bData, PaintBakeData::clear, dynamicPaint_setInitialColor(), float, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, PaintSurfaceData::total_points, and PaintSurfaceData::type_data.
| DynamicPaintSurface * dynamicPaint_createNewSurface | ( | struct DynamicPaintCanvasSettings * | canvas, |
| struct Scene * | scene ) |
Creates a new surface and adds it to the list If scene is null, frame range of 1-250 is used A pointer to this surface is returned.
Definition at line 1037 of file dynamicpaint.cc.
References BKE_effector_add_weights(), BKE_modifier_path_init(), BKE_ptcache_add(), BLI_addtail(), BLT_I18NCONTEXT_ID_BRUSH, CTX_DATA_, dynamicPaintSurface_setUniqueName(), dynamicPaintSurface_updateType(), MOD_DPAINT_ACTIVE, MOD_DPAINT_ANTIALIAS, MOD_DPAINT_DISP_DISPLACE, MOD_DPAINT_DISSOLVE_LOG, MOD_DPAINT_DRY_LOG, MOD_DPAINT_IMGFORMAT_PNG, MOD_DPAINT_MULALPHA, MOD_DPAINT_OUT1, MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_USE_DRYING, PTCACHE_DISK_CACHE, and DynamicPaintCanvasSettings::surfaces.
Referenced by dynamicPaint_createType(), dynamicPaint_Modifier_copy(), and surface_slot_add_exec().
| bool dynamicPaint_createType | ( | struct DynamicPaintModifierData * | pmd, |
| int | type, | ||
| struct Scene * | scene ) |
Initialize modifier data.
Definition at line 1114 of file dynamicpaint.cc.
References CBData::a, DynamicPaintBrushSettings::alpha, CBData::b, DynamicPaintBrushSettings::b, BKE_colorband_add(), DynamicPaintModifierData::brush, DynamicPaintModifierData::canvas, DynamicPaintBrushSettings::collision, ColorBand::data, dynamicPaint_createNewSurface(), dynamicPaint_freeBrush(), dynamicPaint_freeCanvas(), DynamicPaintBrushSettings::flags, CBData::g, DynamicPaintBrushSettings::g, DynamicPaintBrushSettings::max_velocity, MOD_DPAINT_ABS_ALPHA, MOD_DPAINT_COL_VOLUME, MOD_DPAINT_PRFALL_SMOOTH, MOD_DPAINT_RAMP_ALPHA, MOD_DPAINT_WAVEB_CHANGE, MOD_DYNAMICPAINT_TYPE_BRUSH, MOD_DYNAMICPAINT_TYPE_CANVAS, DynamicPaintBrushSettings::paint_distance, DynamicPaintBrushSettings::paint_ramp, DynamicPaintBrushSettings::particle_radius, DynamicPaintBrushSettings::particle_smooth, DynamicPaintBrushSettings::pmd, DynamicPaintCanvasSettings::pmd, CBData::pos, DynamicPaintBrushSettings::proximity_falloff, DynamicPaintBrushSettings::psys, CBData::r, DynamicPaintBrushSettings::r, DynamicPaintBrushSettings::smudge_strength, ColorBand::tot, DynamicPaintBrushSettings::vel_ramp, DynamicPaintBrushSettings::wave_clamp, DynamicPaintBrushSettings::wave_factor, DynamicPaintBrushSettings::wave_type, and DynamicPaintBrushSettings::wetness.
Referenced by dynamicPaint_Modifier_copy(), and type_toggle_exec().
| int dynamicPaint_createUVSurface | ( | struct Scene * | scene, |
| struct DynamicPaintSurface * | surface, | ||
| float * | progress, | ||
| bool * | do_update ) |
Image sequence baking.
Definition at line 2822 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, ADJ_ON_MESH_EDGE, ImgSeqFormatData::barycentricWeights, BKE_mesh_vert_corner_tri_map_create(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintAdjData::border, CD_PROP_FLOAT2, CLOG_INFO, PaintPoint::color, copy_v2_v2(), CustomData_get_layer_named(), CustomData_has_layer(), CustomData_validate_layer_name(), blender::Span< T >::data(), dynamic_paint_create_uv_surface_direct_cb(), dynamic_paint_create_uv_surface_neighbor_cb(), dynamic_paint_find_neighbor_pixel(), dynamicPaint_allocateSurfaceType(), dynamicPaint_canvas_mesh_get(), dynamicPaint_freeSurfaceData(), dynamicPaint_initAdjacencyData(), dynamicPaint_pointHasNeighbor(), dynamicPaint_setInitialColor(), dynamicPaint_symmetrizeAdjData(), ELEM, error(), PaintAdjData::flags, float, PaintSurfaceData::format_data, blender::Span< T >::index_range(), int, LOG, MAX_CUSTOMDATA_LAYER_NAME, MEM_callocN, MEM_freeN(), MEM_malloc_arrayN, MEM_mallocN, min, minmax_v2v2_v2(), MOD_DPAINT_ANTIALIAS, MOD_DPAINT_SURFACE_F_IMAGESEQ, N_, PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, PaintUVPoint::neighbor_pixel, next, ON_MESH_EDGE, OUT_OF_TEXTURE, setError(), blender::Span< T >::size(), DynamicPaintCreateUVSurfaceData::surface, PaintAdjData::total_border, PaintSurfaceData::total_points, PaintUVPoint::tri_index, PaintSurfaceData::type_data, ImgSeqFormatData::uv_p, and w().
Referenced by dynamicPaint_bakeImageSequence().
|
static |
Definition at line 5629 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintAdjData::border, dynamic_paint_border_cb(), DynamicPaintEffectData::surface, and PaintAdjData::total_border.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 5476 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), CANVAS_REL_SIZE, dynamic_paint_effect_drip_cb(), dynamic_paint_effect_shrink_cb(), dynamic_paint_effect_spread_cb(), EFF_MOVEMENT_PER_FRAME, getSurfaceDimension(), MEM_callocN, MEM_freeN(), MOD_DPAINT_EFFECT_DO_DRIP, MOD_DPAINT_EFFECT_DO_SHRINK, MOD_DPAINT_EFFECT_DO_SPREAD, steps, DynamicPaintEffectData::surface, PaintSurfaceData::total_points, and PaintSurfaceData::type_data.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 4999 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, PaintSurfaceData::adj_data, PaintBakeData::average_dist, PaintSurfaceData::bData, PaintBakeData::bNeighs, PaintBakeData::brush_velocity, ceil(), CLAMP, CLAMP_MAX, CLAMP_MIN, PaintPoint::color, BakeAdjPoint::dist, PaintPoint::e_color, PaintAdjData::flags, float, int, mixColors(), PaintAdjData::n_target, DynamicPaintBrushSettings::smudge_strength, steps, surface_determineForceTargetPoints(), PaintSurfaceData::total_points, PaintSurfaceData::type_data, and PaintPoint::wetness.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 6224 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, PaintSurfaceData::bData, BKE_collision_objects_create(), BKE_collision_objects_free(), BKE_modifiers_findby_type(), BKE_object_modifier_update_subframe(), BKE_scene_ctime_get(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintBakeData::bNeighs, DynamicPaintModifierData::brush, PaintBakeData::brush_velocity, DynamicPaintBrushSettings::collision, DAG_EVAL_RENDER, DEG_get_mode(), depsgraph, dynamic_paint_surface_needs_dry_dissolve(), dynamic_paint_surface_pre_step_cb(), dynamicPaint_doBorderStep(), dynamicPaint_doEffectStep(), dynamicPaint_doSmudge(), dynamicPaint_doWaveStep(), dynamicPaint_initAdjacencyData(), dynamicPaint_paintMesh(), dynamicPaint_paintParticles(), dynamicPaint_paintSinglePoint(), dynamicPaint_prepareAdjacencyData(), dynamicPaint_prepareEffectStep(), ELEM, eModifierMode_Realtime, eModifierMode_Render, eModifierType_DynamicPaint, DynamicPaintBrushSettings::flags, Object::loc, MEM_callocN, MEM_freeN(), MEM_mallocN, MOD_DPAINT_COL_POINT, MOD_DPAINT_DO_SMUDGE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DYNAMICPAINT_TYPE_BRUSH, ModifierData::mode, N_, ParticleSystem::part, PART_EMITTER, PART_FLUID, PART_FLUID_BUBBLE, PART_FLUID_FLIP, PART_FLUID_FOAM, PART_FLUID_FOAMBUBBLE, PART_FLUID_SPRAY, PART_FLUID_SPRAYBUBBLE, PART_FLUID_SPRAYFOAM, PART_FLUID_SPRAYFOAMBUBBLE, PART_FLUID_TRACER, DynamicPaintBrushSettings::psys, psys_check_enabled(), ret, scene_setSubframe(), setError(), steps, SUBFRAME_RECURSION, DynamicPaintDissolveDryData::surface, PaintSurfaceData::total_points, DynamicPaintModifierData::type, and ParticleSettings::type.
Referenced by dynamicPaint_calculateFrame().
|
static |
Definition at line 5747 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, PaintSurfaceData::bData, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintBakeData::bNeighs, CANVAS_REL_SIZE, ceil(), CLAMP, BakeAdjPoint::dist, double(), dynamic_paint_wave_step_cb(), getSurfaceDimension(), int, MEM_freeN(), MEM_mallocN, PaintAdjData::n_index, PaintAdjData::n_num, pow(), steps, DynamicPaintEffectData::surface, PaintSurfaceData::total_points, PaintAdjData::total_targets, PaintSurfaceData::type_data, and WAVE_TIME_FAC.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 2099 of file dynamicpaint.cc.
References BKE_ptcache_id_from_dynamicpaint(), BKE_ptcache_id_reset(), BKE_ptcache_id_time(), BKE_ptcache_read(), BKE_ptcache_validate(), BKE_ptcache_write(), PTCacheID::cache, DynamicPaintModifierData::canvas, canvas_copyMesh(), CLAMP, depsgraph, dynamicPaint_calculateFrame(), dynamicPaint_checkSurfaceData(), PointCache::endframe, ListBase::first, PointCache::flag, DynamicPaintCanvasSettings::flags, int, MOD_DPAINT_ACTIVE, MOD_DPAINT_BAKING, MOD_DPAINT_DISP_INCREMENTAL, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_T_DISPLACE, PTCACHE_BAKED, PTCACHE_REDO_NEEDED, PTCACHE_RESET_OUTDATED, PointCache::startframe, surface_freeUnusedData(), and DynamicPaintCanvasSettings::surfaces.
Referenced by dynamicPaint_Modifier_do().
|
static |
Definition at line 885 of file dynamicpaint.cc.
References MEM_freeN().
Referenced by dynamicPaint_freeSurfaceData(), and dynamicPaint_initAdjacencyData().
| void dynamicPaint_freeBrush | ( | DynamicPaintModifierData * | pmd | ) |
Definition at line 870 of file dynamicpaint.cc.
References DynamicPaintModifierData::brush, MEM_freeN(), DynamicPaintBrushSettings::paint_ramp, and DynamicPaintBrushSettings::vel_ramp.
Referenced by dynamicPaint_createType(), dynamicPaint_Modifier_free(), and type_toggle_exec().
| void dynamicPaint_freeCanvas | ( | struct DynamicPaintModifierData * | pmd | ) |
Free canvas data.
Definition at line 1007 of file dynamicpaint.cc.
References DynamicPaintModifierData::canvas, dynamicPaint_freeSurface(), ListBase::first, MEM_freeN(), DynamicPaintSurface::next, and DynamicPaintCanvasSettings::surfaces.
Referenced by dynamicPaint_createType(), dynamicPaint_Modifier_free(), and type_toggle_exec().
| void dynamicPaint_freeSurface | ( | const DynamicPaintModifierData * | pmd, |
| DynamicPaintSurface * | surface ) |
Definition at line 992 of file dynamicpaint.cc.
References BKE_ptcache_free_list(), BLI_remlink(), dynamicPaint_freeSurfaceData(), eModifierFlag_SharedCaches, ModifierData::flag, MEM_freeN(), MEM_SAFE_FREE, and DynamicPaintModifierData::modifier.
Referenced by dynamicPaint_freeCanvas(), and dynamicPaint_Modifier_copy().
| void dynamicPaint_freeSurfaceData | ( | DynamicPaintSurface * | surface | ) |
Definition at line 960 of file dynamicpaint.cc.
References ImgSeqFormatData::barycentricWeights, dynamicPaint_freeAdjData(), free_bakeData(), MEM_freeN(), MOD_DPAINT_SURFACE_F_IMAGESEQ, and ImgSeqFormatData::uv_p.
Referenced by dpaint_bake_endjob(), dynamicPaint_createUVSurface(), dynamicPaint_freeSurface(), and dynamicPaint_resetSurface().
|
static |
Definition at line 6074 of file dynamicpaint.cc.
References PaintSurfaceData::bData, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintBakeData::bNormal, boundInsert(), BRUSH_USES_VELOCITY, PaintBakeData::clear, copy_m4_m4(), copy_v3_v3(), depsgraph, dynamic_paint_generate_bake_data_cb(), dynamicPaint_canvas_mesh_get(), dynamicPaint_prepareAdjacencyData(), dynamicPaint_surfaceHasMoved(), MEM_callocN, MEM_freeN(), MEM_mallocN, PaintBakeData::mesh_bounds, MOD_DPAINT_EFFECT_DO_DRIP, mul_m4_v3(), N_, PaintBakeData::prev_obmat, PaintBakeData::prev_positions, PaintBakeData::prev_velocity, PaintBakeData::realCoord, PaintBakeData::s_num, PaintBakeData::s_pos, setError(), DynamicPaintGenerateBakeData::surface, surface_getBrushFlags(), surface_totalSamples(), surfaceGenerateGrid(), PaintSurfaceData::total_points, v, Vec3f::v, Bounds3D::valid, and PaintBakeData::velocity.
Referenced by dynamicPaint_calculateFrame().
|
static |
Definition at line 1381 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, ADJ_ON_MESH_EDGE, PaintAdjData::border, dynamicPaint_canvas_mesh_get(), dynamicPaint_freeAdjData(), PaintAdjData::flags, MEM_callocN, MEM_freeN(), MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_F_VERTEX, N_, PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, setError(), blender::Span< T >::slice(), surface_usesAdjData(), PaintAdjData::total_border, PaintSurfaceData::total_points, and PaintAdjData::total_targets.
Referenced by dynamicPaint_createUVSurface(), dynamicPaint_doStep(), and dynamicPaint_resetSurface().
|
static |
Mix color values to canvas point.
| surface | Canvas surface |
| index | Surface point index |
| paintFlags | paint object flags |
| paintColor,paintAlpha,paintWetness | To be mixed paint values |
| timescale | Value used to adjust time dependent operations when using substeps |
Definition at line 3528 of file dynamicpaint.cc.
References blendColors(), CLAMP, CLAMP_MAX, CLAMP_MIN, PaintPoint::color, copy_v3_v3(), DPAINT_PAINT_NEW, PaintPoint::e_color, max_ff(), MIN_WETNESS, mix, MOD_DPAINT_ABS_ALPHA, MOD_DPAINT_ERASE, PaintPoint::state, and PaintPoint::wetness.
Referenced by dynamicPaint_updatePointData().
|
static |
Definition at line 3596 of file dynamicpaint.cc.
References BLI_assert, PaintWavePoint::brush_isect, DPAINT_WAVE_ISECT_CHANGED, DPAINT_WAVE_OBSTACLE, DPAINT_WAVE_REFLECT_ONLY, PaintWavePoint::height, MOD_DPAINT_WAVEB_CHANGE, MOD_DPAINT_WAVEB_DEPTH, MOD_DPAINT_WAVEB_FORCE, MOD_DPAINT_WAVEB_REFLECT, PaintWavePoint::state, PaintWavePoint::velocity, DynamicPaintBrushSettings::wave_factor, and DynamicPaintBrushSettings::wave_type.
Referenced by dynamicPaint_updatePointData().
|
static |
Apply canvas data to the object evaluated-mesh.
Definition at line 1917 of file dynamicpaint.cc.
References BKE_defvert_ensure_index(), BKE_defvert_find_index(), BKE_id_free(), BKE_mesh_copy_for_eval(), BKE_object_defgroup_name_index(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), DynamicPaintModifierData::brush, DynamicPaintRuntime::brush_mesh, DynamicPaintModifierData::canvas, CD_MDEFORMVERT, CD_PROP_BYTE_COLOR, CD_SET_DEFAULT, CustomData_add_layer(), CustomData_add_layer_named(), CustomData_get_layer_for_write(), CustomData_get_layer_named_for_write(), dynamic_paint_apply_surface_vpaint_blend_cb(), dynamic_paint_apply_surface_vpaint_cb(), dynamic_paint_apply_surface_wave_cb(), dynamicPaint_applySurfaceDisplace(), dynamicPaint_Modifier_runtime_ensure(), dynamicPaint_outputLayerExists(), faces, ListBase::first, DynamicPaintCanvasSettings::flags, float, MEM_callocN, MEM_freeN(), MOD_DPAINT_ACTIVE, MOD_DPAINT_BAKING, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_SURFACE_T_WEIGHT, MOD_DYNAMICPAINT_TYPE_BRUSH, MOD_DYNAMICPAINT_TYPE_CANVAS, result, blender::Span< T >::size(), DynamicPaintModifierApplyData::surface, DynamicPaintCanvasSettings::surfaces, PaintSurfaceData::total_points, DynamicPaintModifierData::type, PaintSurfaceData::type_data, and MDeformWeight::weight.
Referenced by dynamicPaint_Modifier_do().
| void dynamicPaint_Modifier_copy | ( | const DynamicPaintModifierData * | pmd, |
| DynamicPaintModifierData * | tpmd, | ||
| int | flag ) |
Definition at line 1208 of file dynamicpaint.cc.
References DynamicPaintCanvasSettings::active_sur, DynamicPaintBrushSettings::alpha, DynamicPaintBrushSettings::b, BKE_ptcache_free_list(), DynamicPaintModifierData::brush, DynamicPaintSurface::brush_group, DynamicPaintModifierData::canvas, DynamicPaintBrushSettings::collision, DynamicPaintSurface::color_dry_threshold, DynamicPaintSurface::color_spread_speed, copy_v4_v4(), DynamicPaintSurface::depth_clamp, DynamicPaintSurface::disp_factor, DynamicPaintSurface::disp_type, DynamicPaintSurface::diss_speed, DynamicPaintSurface::drip_acc, DynamicPaintSurface::drip_vel, DynamicPaintSurface::dry_speed, dynamicPaint_createNewSurface(), dynamicPaint_createType(), dynamicPaint_freeSurface(), DynamicPaintSurface::effect, DynamicPaintSurface::effect_ui, DynamicPaintSurface::effector_weights, eModifierFlag_SharedCaches, DynamicPaintSurface::end_frame, ListBase::first, flag, ModifierData::flag, DynamicPaintBrushSettings::flags, DynamicPaintSurface::flags, DynamicPaintSurface::format, DynamicPaintBrushSettings::g, DynamicPaintSurface::image_fileformat, DynamicPaintSurface::image_output_path, DynamicPaintSurface::image_resolution, DynamicPaintSurface::influence_scale, DynamicPaintSurface::init_color, DynamicPaintSurface::init_color_type, DynamicPaintSurface::init_layername, DynamicPaintSurface::init_texture, LIB_ID_COPY_SET_COPIED_ON_WRITE, DynamicPaintBrushSettings::max_velocity, MEM_dupallocN, MEM_freeN(), MOD_DYNAMICPAINT_TYPE_BRUSH, MOD_DYNAMICPAINT_TYPE_CANVAS, DynamicPaintModifierData::modifier, DynamicPaintSurface::name, DynamicPaintSurface::output_name, DynamicPaintSurface::output_name2, DynamicPaintBrushSettings::paint_distance, DynamicPaintBrushSettings::paint_ramp, DynamicPaintBrushSettings::particle_radius, DynamicPaintBrushSettings::particle_smooth, DynamicPaintBrushSettings::pmd, DynamicPaintCanvasSettings::pmd, DynamicPaintSurface::pointcache, DynamicPaintBrushSettings::proximity_falloff, DynamicPaintBrushSettings::psys, DynamicPaintSurface::ptcaches, DynamicPaintBrushSettings::r, DynamicPaintSurface::radius_scale, DynamicPaintBrushSettings::ray_dir, DynamicPaintSurface::shrink_speed, DynamicPaintBrushSettings::smudge_strength, DynamicPaintSurface::spread_speed, DynamicPaintSurface::start_frame, STRNCPY, DynamicPaintSurface::substeps, DynamicPaintCanvasSettings::surfaces, DynamicPaintModifierData::type, DynamicPaintSurface::type, DynamicPaintSurface::uvlayer_name, DynamicPaintBrushSettings::vel_ramp, DynamicPaintBrushSettings::wave_clamp, DynamicPaintSurface::wave_damping, DynamicPaintBrushSettings::wave_factor, DynamicPaintSurface::wave_smoothness, DynamicPaintSurface::wave_speed, DynamicPaintSurface::wave_spring, DynamicPaintSurface::wave_timescale, DynamicPaintBrushSettings::wave_type, and DynamicPaintBrushSettings::wetness.
| Mesh * dynamicPaint_Modifier_do | ( | struct DynamicPaintModifierData * | pmd, |
| struct Depsgraph * | depsgraph, | ||
| struct Scene * | scene, | ||
| struct Object * | ob, | ||
| struct Mesh * | mesh ) |
Modifier call. Processes dynamic paint modifier step.
Definition at line 2187 of file dynamicpaint.cc.
References depsgraph, dynamicPaint_frameUpdate(), and dynamicPaint_Modifier_apply().
Referenced by modify_mesh().
| void dynamicPaint_Modifier_free | ( | struct DynamicPaintModifierData * | pmd | ) |
Free whole dynamic-paint modifier.
Definition at line 1025 of file dynamicpaint.cc.
References dynamicPaint_freeBrush(), dynamicPaint_freeCanvas(), dynamicPaint_Modifier_free_runtime(), DynamicPaintModifierData::modifier, and ModifierData::runtime.
Referenced by free_data().
| void dynamicPaint_Modifier_free_runtime | ( | DynamicPaintRuntime * | runtime_data | ) |
Definition at line 259 of file dynamicpaint.cc.
References BKE_id_free(), DynamicPaintRuntime::brush_mesh, DynamicPaintRuntime::canvas_mesh, and MEM_freeN().
Referenced by dynamicPaint_Modifier_free(), and free_runtime_data().
|
static |
Definition at line 273 of file dynamicpaint.cc.
References MEM_callocN, DynamicPaintModifierData::modifier, and ModifierData::runtime.
Referenced by canvas_copyMesh(), and dynamicPaint_Modifier_apply().
| bool dynamicPaint_outputLayerExists | ( | DynamicPaintSurface * | surface, |
| Object * | ob, | ||
| int | output ) |
Definition at line 329 of file dynamicpaint.cc.
References BKE_object_defgroup_name_index(), CD_PROP_BYTE_COLOR, CustomData_get_named_layer_index(), Object::data, MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WEIGHT, and DynamicPaintSurface::output_name.
Referenced by dynamicPaint_Modifier_apply(), and output_toggle_exec().
| void dynamicPaint_outputSurfaceImage | ( | DynamicPaintSurface * | surface, |
| const char * | filepath, | ||
| short | output_layer ) |
Definition at line 3315 of file dynamicpaint.cc.
References BKE_image_path_ext_from_imtype_ensure(), BKE_main_blendfile_path_from_global(), BLI_assert, BLI_file_ensure_parent_dir_exists(), BLI_parallel_range_settings_defaults(), BLI_path_abs(), BLI_task_parallel_range(), dynamic_paint_output_surface_image_displace_cb(), dynamic_paint_output_surface_image_paint_cb(), dynamic_paint_output_surface_image_wave_cb(), dynamic_paint_output_surface_image_wetmap_cb(), FILE_MAX, ImbFormatOptions::flag, ImBuf::foptions, ImBuf::ftype, IB_rectfloat, IMB_allocImBuf(), IMB_freeImBuf(), IMB_FTYPE_OPENEXR, IMB_FTYPE_PNG, IMB_saveiff(), MOD_DPAINT_IMGFORMAT_OPENEXR, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, N_, OPENEXR_COMPRESS, ImbFormatOptions::quality, R_IMF_IMTYPE_OPENEXR, R_IMF_IMTYPE_PNG, setError(), STRNCPY, DynamicPaintOutputSurfaceImageData::surface, PaintSurfaceData::total_points, and PaintSurfaceData::type_data.
Referenced by dynamicPaint_bakeImageSequence().
|
static |
Definition at line 4291 of file dynamicpaint.cc.
References add_v3_v3(), PaintSurfaceData::bData, BKE_bvhtree_from_mesh_get(), BKE_id_free(), BKE_mesh_copy_for_eval(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), boundInsert(), BVHTREE_FROM_CORNER_TRIS, DynamicPaintBrushSettings::collision, copy_v3_v3(), depsgraph, dynamic_paint_paint_mesh_cell_point_cb_ex(), dynamicPaint_brush_mesh_get(), dynamicPaint_brushMeshCalculateVelocity(), DynamicPaintBrushSettings::flags, free_bvhtree_from_mesh(), PaintBakeData::grid, MEM_freeN(), mesh, meshBrush_boundsIntersect(), MOD_DPAINT_COL_VOLUME, MOD_DPAINT_PROX_PROJECT, MOD_DPAINT_USES_VELOCITY, mul_m4_v3(), mul_mat3_m4_v3(), mul_v3_fl(), nor, normalize_v3(), DynamicPaintBrushSettings::paint_distance, scene, DynamicPaintPaintData::surface, and UNLIKELY.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 4592 of file dynamicpaint.cc.
References PaintSurfaceData::bData, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), boundInsert(), boundIntersectPoint(), boundsIntersectDist(), CLOG_WARN, dynamic_paint_paint_particle_cell_point_cb_ex(), DynamicPaintBrushSettings::flags, PaintBakeData::grid, LOG, MOD_DPAINT_PART_RAD, PARS_DEAD, PARS_UNBORN, PARS_UNEXIST, ParticleSystem::part, PART_DIED, PART_UNBORN, DynamicPaintBrushSettings::particle_radius, DynamicPaintBrushSettings::particle_smooth, ParticleSystem::particles, DynamicPaintBrushSettings::psys, smooth(), DynamicPaintPaintData::surface, ParticleSystem::totpart, and tree.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 4799 of file dynamicpaint.cc.
References BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), depsgraph, dynamic_paint_paint_single_point_cb_ex(), dynamicPaint_brush_mesh_get(), dynamicPaint_brushObjectCalculateVelocity(), DynamicPaintBrushSettings::flags, MOD_DPAINT_USES_VELOCITY, DynamicPaintBrushSettings::paint_distance, scene, DynamicPaintPaintData::surface, and PaintSurfaceData::total_points.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 2712 of file dynamicpaint.cc.
References PaintAdjData::n_index, PaintAdjData::n_num, and PaintAdjData::n_target.
Referenced by dynamicPaint_createUVSurface(), and dynamicPaint_symmetrizeAdjData().
|
static |
Definition at line 4874 of file dynamicpaint.cc.
References PaintSurfaceData::adj_data, PaintBakeData::average_dist, PaintSurfaceData::bData, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), PaintBakeData::bNeighs, BakeAdjPoint::dist, double(), dynamic_paint_prepare_adjacency_cb(), MEM_freeN(), MEM_mallocN, PaintAdjData::n_index, PaintAdjData::n_num, surface_usesAdjDistance(), PaintSurfaceData::total_points, and PaintAdjData::total_targets.
Referenced by dynamicPaint_doStep(), and dynamicPaint_generateBakeData().
|
static |
Definition at line 5163 of file dynamicpaint.cc.
References PaintBakeData::average_dist, PaintSurfaceData::bData, BKE_effectors_create(), BKE_effectors_free(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), CANVAS_REL_SIZE, ceilf, CLAMP, depsgraph, double(), dynamic_paint_prepare_effect_cb(), EFF_MOVEMENT_PER_FRAME, getSurfaceDimension(), int, max_fff(), MEM_mallocN, MOD_DPAINT_EFFECT_DO_DRIP, MOD_DPAINT_EFFECT_DO_SHRINK, MOD_DPAINT_EFFECT_DO_SPREAD, scene, steps, DynamicPaintEffectData::surface, and PaintSurfaceData::total_points.
Referenced by dynamicPaint_doStep().
| bool dynamicPaint_resetSurface | ( | const Scene * | scene, |
| DynamicPaintSurface * | surface ) |
Definition at line 1752 of file dynamicpaint.cc.
References dynamicPaint_allocateSurfaceType(), dynamicPaint_freeSurfaceData(), dynamicPaint_initAdjacencyData(), dynamicPaint_setInitialColor(), dynamicPaint_surfaceNumOfPoints(), MOD_DPAINT_SURFACE_F_IMAGESEQ, and MOD_DPAINT_SURFACE_T_PAINT.
Referenced by dynamicPaint_checkSurfaceData().
|
static |
Definition at line 1609 of file dynamicpaint.cc.
References BKE_image_pool_free(), BKE_image_pool_new(), BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), CD_PROP_BYTE_COLOR, CD_PROP_FLOAT2, col, copy_v4_v4(), CustomData_get_layer_named(), CustomData_validate_layer_name(), dynamic_paint_set_init_color_tex_to_imseq_cb(), dynamic_paint_set_init_color_tex_to_vcol_cb(), dynamic_paint_set_init_color_vcol_to_imseq_cb(), dynamicPaint_canvas_mesh_get(), float, blender::Span< T >::index_range(), MAX_CUSTOMDATA_LAYER_NAME, MOD_DPAINT_INITIAL_COLOR, MOD_DPAINT_INITIAL_NONE, MOD_DPAINT_INITIAL_TEXTURE, MOD_DPAINT_INITIAL_VERTEXCOLOR, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_F_VERTEX, MOD_DPAINT_SURFACE_T_PAINT, rgba_uchar_to_float(), blender::Span< T >::size(), DynamicPaintSetInitColorData::surface, tex, PaintSurfaceData::total_points, and PaintSurfaceData::type_data.
Referenced by dynamicPaint_clearSurface(), dynamicPaint_createUVSurface(), and dynamicPaint_resetSurface().
|
static |
Definition at line 5923 of file dynamicpaint.cc.
References PaintSurfaceData::bData, dynamicPaint_canvas_mesh_get(), equals_m4m4(), equals_v3v3(), PaintBakeData::prev_obmat, and PaintBakeData::prev_positions.
Referenced by dynamicPaint_generateBakeData().
|
static |
Definition at line 311 of file dynamicpaint.cc.
References dynamicPaint_canvas_mesh_get(), MOD_DPAINT_SURFACE_F_PTEX, MOD_DPAINT_SURFACE_F_VERTEX, and Mesh::verts_num.
Referenced by dynamicPaint_checkSurfaceData(), and dynamicPaint_resetSurface().
|
static |
Definition at line 2727 of file dynamicpaint.cc.
References ADJ_BORDER_PIXEL, BLI_assert, dynamicPaint_pointHasNeighbor(), PaintAdjData::flags, MEM_callocN, MEM_freeN(), PaintAdjData::n_index, PaintAdjData::n_num, PaintAdjData::n_target, and PaintAdjData::total_targets.
Referenced by dynamicPaint_createUVSurface().
|
static |
Definition at line 3646 of file dynamicpaint.cc.
References DynamicPaintBrushSettings::alpha, PaintSurfaceData::bData, BKE_colorband_evaluate(), PaintBakeData::brush_velocity, CLAMP, CLAMP_MIN, copy_v3_v3(), dynamicPaint_mixPaintColors(), dynamicPaint_mixWaveHeight(), DynamicPaintBrushSettings::flags, DynamicPaintBrushSettings::max_velocity, MOD_DPAINT_DISP_INCREMENTAL, MOD_DPAINT_ERASE, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_SURFACE_T_WEIGHT, MOD_DPAINT_VELOCITY_ALPHA, MOD_DPAINT_VELOCITY_COLOR, MOD_DPAINT_VELOCITY_DEPTH, PaintSurfaceData::type_data, DynamicPaintBrushSettings::vel_ramp, DynamicPaintBrushSettings::wave_clamp, and DynamicPaintBrushSettings::wetness.
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex(), dynamic_paint_paint_particle_cell_point_cb_ex(), and dynamic_paint_paint_single_point_cb_ex().
| void dynamicPaintSurface_setUniqueName | ( | DynamicPaintSurface * | surface, |
| const char * | basename ) |
Definition at line 413 of file dynamicpaint.cc.
References BLI_uniquename_cb(), STRNCPY_UTF8, and surface_duplicateNameExists().
Referenced by dynamicPaint_createNewSurface().
| void dynamicPaintSurface_updateType | ( | struct DynamicPaintSurface * | surface | ) |
Change surface data to defaults on new type.
Definition at line 421 of file dynamicpaint.cc.
References MOD_DPAINT_ANTIALIAS, MOD_DPAINT_SURFACE_F_IMAGESEQ, MOD_DPAINT_SURFACE_T_DISPLACE, MOD_DPAINT_SURFACE_T_PAINT, MOD_DPAINT_SURFACE_T_WAVE, MOD_DPAINT_SURFACE_T_WEIGHT, SNPRINTF, STREQ, and surface_setUniqueOutputName().
Referenced by dynamicPaint_createNewSurface().
|
static |
Definition at line 908 of file dynamicpaint.cc.
References PaintBakeData::bNeighs, PaintBakeData::bNormal, freeGrid(), PaintBakeData::grid, MEM_freeN(), PaintBakeData::prev_positions, PaintBakeData::prev_velocity, PaintBakeData::realCoord, PaintBakeData::s_num, PaintBakeData::s_pos, and PaintBakeData::velocity.
Referenced by dynamicPaint_freeSurfaceData(), and surface_freeUnusedData().
|
static |
Definition at line 628 of file dynamicpaint.cc.
References PaintBakeData::grid, and MEM_freeN().
Referenced by free_bakeData(), and surfaceGenerateGrid().
| DynamicPaintSurface * get_activeSurface | ( | struct DynamicPaintCanvasSettings * | canvas | ) |
Get currently active surface (in user interface).
Definition at line 324 of file dynamicpaint.cc.
References DynamicPaintCanvasSettings::active_sur, BLI_findlink(), and DynamicPaintCanvasSettings::surfaces.
Referenced by dynamicpaint_bake_exec(), and output_toggle_exec().
|
static |
Definition at line 622 of file dynamicpaint.cc.
References PaintSurfaceData::bData, Bounds3D::max, max_fff(), PaintBakeData::mesh_bounds, and Bounds3D::min.
Referenced by dynamicPaint_doEffectStep(), dynamicPaint_doWaveStep(), and dynamicPaint_prepareEffectStep().
|
static |
Definition at line 650 of file dynamicpaint.cc.
References boundInsert(), PaintBakeData::realCoord, PaintBakeData::s_pos, and Vec3f::v.
Referenced by surfaceGenerateGrid().
|
static |
Definition at line 661 of file dynamicpaint.cc.
References boundInsert(), Bounds3D::max, and Bounds3D::min.
Referenced by surfaceGenerateGrid().
|
static |
Definition at line 710 of file dynamicpaint.cc.
References PaintBakeData::dim, PaintBakeData::grid, and z().
Referenced by surfaceGenerateGrid().
|
static |
Definition at line 672 of file dynamicpaint.cc.
References CLAMP, PaintBakeData::dim, floorf, PaintBakeData::grid, int, PaintBakeData::realCoord, PaintBakeData::s_pos, DynamicPaintVolumeGrid::temp_t_index, and Vec3f::v.
Referenced by surfaceGenerateGrid().
|
static |
Definition at line 693 of file dynamicpaint.cc.
References DynamicPaintVolumeGrid::dim, and PaintBakeData::grid.
Referenced by surfaceGenerateGrid().
|
static |
Definition at line 3489 of file dynamicpaint.cc.
References closest_on_tri_to_point_v3(), copy_v3_v3(), blender::Span< T >::data(), and len_squared_v3v3().
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
|
static |
Definition at line 3457 of file dynamicpaint.cc.
References bvhtree_ray_tri_intersection(), and blender::Span< T >::data().
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
|
static |
Definition at line 3742 of file dynamicpaint.cc.
References boundsIntersect(), boundsIntersectDist(), DynamicPaintBrushSettings::collision, ELEM, MOD_DPAINT_COL_DIST, MOD_DPAINT_COL_VOLDIST, and MOD_DPAINT_COL_VOLUME.
Referenced by dynamicPaint_paintMesh().
|
static |
Definition at line 501 of file dynamicpaint.cc.
References copy_v3_v3(), and interp_v3_v3v3().
Referenced by dynamic_paint_effect_drip_cb(), dynamic_paint_effect_spread_cb(), and dynamicPaint_doSmudge().
Definition at line 530 of file dynamicpaint.cc.
Referenced by dynamicPaint_doStep().
|
static |
Definition at line 302 of file dynamicpaint.cc.
References CLOG_STR_ERROR, DynamicPaintCanvasSettings::error, LOG, and STRNCPY.
Referenced by dynamicPaint_allocateSurfaceType(), dynamicPaint_createUVSurface(), dynamicPaint_doStep(), dynamicPaint_generateBakeData(), dynamicPaint_initAdjacencyData(), dynamicPaint_outputSurfaceImage(), and surfaceGenerateGrid().
|
static |
Definition at line 4918 of file dynamicpaint.cc.
References acosf, PaintSurfaceData::adj_data, PaintSurfaceData::bData, PaintBakeData::bNeighs, CLAMP, cross_v3_v3v3(), dot_v3v3(), fabsf, float, M_PI_2, madd_v3_v3v3fl(), mul_v2_fl(), PaintAdjData::n_index, PaintAdjData::n_num, and normalize_v3().
Referenced by dynamic_paint_effect_drip_cb(), and dynamicPaint_doSmudge().
|
static |
Definition at line 399 of file dynamicpaint.cc.
References DynamicPaintSurface::canvas, ListBase::first, STREQ, and DynamicPaintCanvasSettings::surfaces.
Referenced by dynamicPaintSurface_setUniqueName().
|
static |
Definition at line 357 of file dynamicpaint.cc.
References BLI_path_cmp, DynamicPaintSurface::canvas, ListBase::first, DynamicPaintSurface::format, DynamicPaintCanvasSettings::surfaces, and DynamicPaintSurface::type.
Referenced by surface_setUniqueOutputName().
|
static |
Definition at line 946 of file dynamicpaint.cc.
References free_bakeData(), MOD_DPAINT_ACTIVE, and PTCACHE_BAKED.
Referenced by dynamicPaint_frameUpdate().
|
static |
Definition at line 537 of file dynamicpaint.cc.
References BKE_collision_objects_create(), BKE_collision_objects_free(), BKE_modifiers_findby_type(), DynamicPaintModifierData::brush, BRUSH_USES_VELOCITY, depsgraph, eModifierMode_Realtime, eModifierMode_Render, eModifierType_DynamicPaint, DynamicPaintBrushSettings::flags, MOD_DPAINT_USES_VELOCITY, and ModifierData::mode.
Referenced by dynamicPaint_generateBakeData().
|
static |
Definition at line 377 of file dynamicpaint.cc.
References BLI_uniquename_cb(), STRNCPY, and surface_duplicateOutputExists().
Referenced by dynamicPaintSurface_updateType().
|
static |
Definition at line 463 of file dynamicpaint.cc.
References MOD_DPAINT_ANTIALIAS, MOD_DPAINT_SURFACE_F_IMAGESEQ, and MOD_DPAINT_SURFACE_F_VERTEX.
Referenced by dynamicPaint_generateBakeData().
|
static |
Definition at line 1374 of file dynamicpaint.cc.
References MOD_DPAINT_ANTIALIAS, MOD_DPAINT_SURFACE_F_VERTEX, and surface_usesAdjDistance().
Referenced by dynamicPaint_initAdjacencyData().
|
static |
Definition at line 1368 of file dynamicpaint.cc.
References MOD_DPAINT_SURFACE_T_PAINT, and MOD_DPAINT_SURFACE_T_WAVE.
Referenced by dynamicPaint_prepareAdjacencyData(), and surface_usesAdjData().
|
static |
Definition at line 733 of file dynamicpaint.cc.
References PaintSurfaceData::bData, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), boundInsert(), CLAMP, copy_v3_v3(), PaintBakeData::dim, error(), float, floor(), freeGrid(), PaintBakeData::grid, grid_bound_insert_cb_ex(), grid_bound_insert_reduce(), grid_cell_bounds_cb(), grid_cell_points_cb_ex(), grid_cell_points_reduce(), int, max_fff(), MEM_callocN, MEM_freeN(), MEM_SAFE_FREE, N_, pos, pow(), PaintBakeData::realCoord, PaintBakeData::s_pos, setError(), sub_v3_v3v3(), PaintSurfaceData::total_points, and Vec3f::v.
Referenced by dynamicPaint_generateBakeData().
| BLI_INLINE void value_dissolve | ( | float * | r_value, |
| const float | time, | ||
| const float | scale, | ||
| const bool | is_log ) |
Definition at line 126 of file dynamicpaint.cc.
References MIN_WETNESS, and powf.
Referenced by dynamic_paint_surface_pre_step_cb().
|
static |
Definition at line 88 of file dynamicpaint.cc.
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
|
static |
Definition at line 95 of file dynamicpaint.cc.
Referenced by dynamic_paint_paint_mesh_cell_point_cb_ex().
|
static |
Definition at line 85 of file dynamicpaint.cc.
Referenced by dynamicPaint_createUVSurface(), dynamicPaint_paintParticles(), and setError().
|
static |
Definition at line 102 of file dynamicpaint.cc.
Referenced by dynamic_paint_create_uv_surface_neighbor_cb().
|
static |
Definition at line 103 of file dynamicpaint.cc.
Referenced by dynamic_paint_create_uv_surface_neighbor_cb().
|
static |
Definition at line 98 of file dynamicpaint.cc.
Referenced by dynamic_paint_find_neighbor_pixel().
|
static |
Definition at line 99 of file dynamicpaint.cc.
Referenced by dynamic_paint_find_neighbor_pixel().