52 int factor_accum = 0.0f;
55 for (
int i = 0; i < tc->data_len; i++, td++) {
59 const float *center = is_local_center ? td->center : tc->center_local;
69 factor_accum += td->
factor;
72 if (factor_accum != 0.0f) {
73 radius /= factor_accum;
79 for (
int i = 0; i < tc->data_len; i++, td++) {
80 const float *center = is_local_center ? td->center : tc->center_local;
96 data->radius = radius;
122 const bool is_local_center,
123 const bool is_data_space)
126 const float *center = is_local_center ? td->center : tc->
center_local;
136 const float tratio = ratio * td->
factor;
137 mul_v3_fl(vec, radius * (1.0f - tratio) + to_sphere_info->
radius * tratio);
162 &data->to_sphere_info,
163 data->is_local_center,
164 data->is_data_space);
188 CLAMP(ratio, 0.0f, 1.0f);
213 for (i = 0; i < tc->data_len; i++, td++) {
225 data.to_sphere_info = *to_sphere_info;
226 data.is_local_center = is_local_center;
227 data.is_data_space = is_data_space;
void mul_m3_v3(const float M[3][3], float r[3])
MINLINE void sub_v3_v3(float r[3], const float a[3])
MINLINE void mul_v3_fl(float r[3], float f)
MINLINE void copy_v3_v3(float r[3], const float a[3])
MINLINE void copy_v3_fl(float r[3], float f)
MINLINE void add_v3_v3(float r[3], const float a[3])
MINLINE float normalize_v3(float n[3])
MINLINE float len_v3(const float a[3]) ATTR_WARN_UNUSED_RESULT
#define SNPRINTF(dst, format,...)
void BLI_task_parallel_range(int start, int stop, void *userdata, TaskParallelRangeFunc func, const TaskParallelSettings *settings)
BLI_INLINE void BLI_parallel_range_settings_defaults(TaskParallelSettings *settings)
void ED_area_status_text(ScrArea *area, const char *str)
Read Guarded memory(de)allocation.
draw_view in_light_buf[] float
void *(* MEM_callocN)(size_t len, const char *str)
const TransDataContainer * tc
ToSphereInfo to_sphere_info
float values_modal_offset[4]
TransCustomDataContainer custom