forked from bartvdbraak/blender
Cleanup: spelling in comments
This commit is contained in:
parent
452c78757f
commit
c5a13ffcb4
@ -344,7 +344,7 @@ bool PathTraceWorkGPU::enqueue_path_iteration()
|
|||||||
/* Finish shadows before potentially adding more shadow rays. We can only
|
/* Finish shadows before potentially adding more shadow rays. We can only
|
||||||
* store one shadow ray in the integrator state.
|
* store one shadow ray in the integrator state.
|
||||||
*
|
*
|
||||||
* When there is a shadow catcher in the scene finish shadow rays before invoking interesect
|
* When there is a shadow catcher in the scene finish shadow rays before invoking intersect
|
||||||
* closest kernel since so that the shadow paths are writing to the pre-split state. */
|
* closest kernel since so that the shadow paths are writing to the pre-split state. */
|
||||||
if (kernel == DEVICE_KERNEL_INTEGRATOR_SHADE_SURFACE ||
|
if (kernel == DEVICE_KERNEL_INTEGRATOR_SHADE_SURFACE ||
|
||||||
kernel == DEVICE_KERNEL_INTEGRATOR_SHADE_SURFACE_RAYTRACE ||
|
kernel == DEVICE_KERNEL_INTEGRATOR_SHADE_SURFACE_RAYTRACE ||
|
||||||
|
@ -538,7 +538,7 @@ typedef struct SculptSession {
|
|||||||
float cursor_sampled_normal[3];
|
float cursor_sampled_normal[3];
|
||||||
float cursor_view_normal[3];
|
float cursor_view_normal[3];
|
||||||
|
|
||||||
/* For Sculpt trimming gesture tools, initial raycast data from the position of the mouse when
|
/* For Sculpt trimming gesture tools, initial ray-cast data from the position of the mouse when
|
||||||
* the gesture starts (intersection with the surface and if they ray hit the surface or not). */
|
* the gesture starts (intersection with the surface and if they ray hit the surface or not). */
|
||||||
float gesture_initial_location[3];
|
float gesture_initial_location[3];
|
||||||
float gesture_initial_normal[3];
|
float gesture_initial_normal[3];
|
||||||
|
@ -128,8 +128,8 @@ void BKE_pbvh_build_bmesh(PBVH *pbvh,
|
|||||||
void BKE_pbvh_free(PBVH *pbvh);
|
void BKE_pbvh_free(PBVH *pbvh);
|
||||||
|
|
||||||
/* Hierarchical Search in the BVH, two methods:
|
/* Hierarchical Search in the BVH, two methods:
|
||||||
* - for each hit calling a callback
|
* - For each hit calling a callback.
|
||||||
* - gather nodes in an array (easy to multithread) */
|
* - Gather nodes in an array (easy to multi-thread). */
|
||||||
|
|
||||||
void BKE_pbvh_search_callback(PBVH *pbvh,
|
void BKE_pbvh_search_callback(PBVH *pbvh,
|
||||||
BKE_pbvh_SearchCallback scb,
|
BKE_pbvh_SearchCallback scb,
|
||||||
@ -140,7 +140,7 @@ void BKE_pbvh_search_callback(PBVH *pbvh,
|
|||||||
void BKE_pbvh_search_gather(
|
void BKE_pbvh_search_gather(
|
||||||
PBVH *pbvh, BKE_pbvh_SearchCallback scb, void *search_data, PBVHNode ***array, int *tot);
|
PBVH *pbvh, BKE_pbvh_SearchCallback scb, void *search_data, PBVHNode ***array, int *tot);
|
||||||
|
|
||||||
/* Raycast
|
/* Ray-cast
|
||||||
* the hit callback is called for all leaf nodes intersecting the ray;
|
* the hit callback is called for all leaf nodes intersecting the ray;
|
||||||
* it's up to the callback to find the primitive within the leaves that is
|
* it's up to the callback to find the primitive within the leaves that is
|
||||||
* hit first */
|
* hit first */
|
||||||
|
@ -1211,7 +1211,7 @@ void BKE_pose_channel_copy_data(bPoseChannel *pchan, const bPoseChannel *pchan_f
|
|||||||
/* copy bone group */
|
/* copy bone group */
|
||||||
pchan->agrp_index = pchan_from->agrp_index;
|
pchan->agrp_index = pchan_from->agrp_index;
|
||||||
|
|
||||||
/* ik (dof) settings */
|
/* IK (DOF) settings. */
|
||||||
pchan->ikflag = pchan_from->ikflag;
|
pchan->ikflag = pchan_from->ikflag;
|
||||||
copy_v3_v3(pchan->limitmin, pchan_from->limitmin);
|
copy_v3_v3(pchan->limitmin, pchan_from->limitmin);
|
||||||
copy_v3_v3(pchan->limitmax, pchan_from->limitmax);
|
copy_v3_v3(pchan->limitmax, pchan_from->limitmax);
|
||||||
|
@ -2763,7 +2763,7 @@ void BKE_pose_where_is_bone(struct Depsgraph *depsgraph,
|
|||||||
float ctime,
|
float ctime,
|
||||||
bool do_extra)
|
bool do_extra)
|
||||||
{
|
{
|
||||||
/* This gives a chan_mat with actions (ipos) results. */
|
/* This gives a chan_mat with actions (F-curve) results. */
|
||||||
if (do_extra) {
|
if (do_extra) {
|
||||||
BKE_pchan_calc_mat(pchan);
|
BKE_pchan_calc_mat(pchan);
|
||||||
}
|
}
|
||||||
|
@ -251,7 +251,7 @@ static void setup_app_data(bContext *C,
|
|||||||
* replace it with 'curscene' if its needed */
|
* replace it with 'curscene' if its needed */
|
||||||
}
|
}
|
||||||
/* and we enforce curscene to be in current screen */
|
/* and we enforce curscene to be in current screen */
|
||||||
else if (win) { /* can run in bgmode */
|
else if (win) { /* The window may be NULL in background-mode. */
|
||||||
win->scene = curscene;
|
win->scene = curscene;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -112,7 +112,7 @@ static int neighStraightY[8] = {0, 1, 0, -1, 1, 1, -1, -1};
|
|||||||
#define SUBFRAME_RECURSION 5
|
#define SUBFRAME_RECURSION 5
|
||||||
/* surface_getBrushFlags() return vals */
|
/* surface_getBrushFlags() return vals */
|
||||||
#define BRUSH_USES_VELOCITY (1 << 0)
|
#define BRUSH_USES_VELOCITY (1 << 0)
|
||||||
/* brush mesh raycast status */
|
/* Brush mesh ray-cast status. */
|
||||||
#define HIT_VOLUME 1
|
#define HIT_VOLUME 1
|
||||||
#define HIT_PROXIMITY 2
|
#define HIT_PROXIMITY 2
|
||||||
/* dynamicPaint_findNeighborPixel() return codes */
|
/* dynamicPaint_findNeighborPixel() return codes */
|
||||||
@ -3436,7 +3436,7 @@ void dynamicPaint_outputSurfaceImage(DynamicPaintSurface *surface,
|
|||||||
|
|
||||||
/***************************** Ray / Nearest Point Utils ******************************/
|
/***************************** Ray / Nearest Point Utils ******************************/
|
||||||
|
|
||||||
/* A modified callback to bvh tree raycast.
|
/* A modified callback to bvh tree ray-cast.
|
||||||
* The tree must have been built using bvhtree_from_mesh_looptri.
|
* The tree must have been built using bvhtree_from_mesh_looptri.
|
||||||
* userdata must be a BVHMeshCallbackUserdata built from the same mesh as the tree.
|
* userdata must be a BVHMeshCallbackUserdata built from the same mesh as the tree.
|
||||||
*
|
*
|
||||||
@ -4107,7 +4107,7 @@ static void dynamic_paint_paint_mesh_cell_point_cb_ex(
|
|||||||
hit.index = -1;
|
hit.index = -1;
|
||||||
hit.dist = brush_radius;
|
hit.dist = brush_radius;
|
||||||
|
|
||||||
/* Do a face normal directional raycast, and use that distance */
|
/* Do a face normal directional ray-cast, and use that distance. */
|
||||||
BLI_bvhtree_ray_cast(
|
BLI_bvhtree_ray_cast(
|
||||||
treeData->tree, ray_start, proj_ray, 0.0f, &hit, mesh_tris_spherecast_dp, treeData);
|
treeData->tree, ray_start, proj_ray, 0.0f, &hit, mesh_tris_spherecast_dp, treeData);
|
||||||
if (hit.index != -1) {
|
if (hit.index != -1) {
|
||||||
@ -4597,7 +4597,7 @@ static bool dynamicPaint_paintParticles(DynamicPaintSurface *surface,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Build a kd-tree to optimize distance search
|
* Build a KD-tree to optimize distance search
|
||||||
*/
|
*/
|
||||||
tree = BLI_kdtree_3d_new(psys->totpart);
|
tree = BLI_kdtree_3d_new(psys->totpart);
|
||||||
|
|
||||||
|
@ -1379,7 +1379,7 @@ static int pbvh_flush_bb(PBVH *pbvh, PBVHNode *node, int flag)
|
|||||||
{
|
{
|
||||||
int update = 0;
|
int update = 0;
|
||||||
|
|
||||||
/* difficult to multithread well, we just do single threaded recursive */
|
/* Difficult to multi-thread well, we just do single threaded recursive. */
|
||||||
if (node->flag & PBVH_Leaf) {
|
if (node->flag & PBVH_Leaf) {
|
||||||
if (flag & PBVH_UpdateBB) {
|
if (flag & PBVH_UpdateBB) {
|
||||||
update |= (node->flag & PBVH_UpdateBB);
|
update |= (node->flag & PBVH_UpdateBB);
|
||||||
@ -1977,7 +1977,7 @@ bool BKE_pbvh_node_vert_update_check_any(PBVH *pbvh, PBVHNode *node)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/********************************* Raycast ***********************************/
|
/********************************* Ray-cast ***********************************/
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
struct IsectRayAABB_Precalc ray;
|
struct IsectRayAABB_Precalc ray;
|
||||||
|
@ -644,7 +644,7 @@ static void shrinkwrap_calc_normal_projection(ShrinkwrapCalcData *calc)
|
|||||||
/* Options about projection direction */
|
/* Options about projection direction */
|
||||||
float proj_axis[3] = {0.0f, 0.0f, 0.0f};
|
float proj_axis[3] = {0.0f, 0.0f, 0.0f};
|
||||||
|
|
||||||
/* Raycast and tree stuff */
|
/* Ray-cast and tree stuff. */
|
||||||
|
|
||||||
/** \note 'hit.dist' is kept in the targets space, this is only used
|
/** \note 'hit.dist' is kept in the targets space, this is only used
|
||||||
* for finding the best hit, to get the real dist,
|
* for finding the best hit, to get the real dist,
|
||||||
|
@ -480,7 +480,7 @@ Text *BKE_text_load_ex(Main *bmain, const char *file, const char *relpath, const
|
|||||||
BLI_stat_t st;
|
BLI_stat_t st;
|
||||||
|
|
||||||
BLI_strncpy(filepath_abs, file, FILE_MAX);
|
BLI_strncpy(filepath_abs, file, FILE_MAX);
|
||||||
if (relpath) { /* can be NULL (bg mode) */
|
if (relpath) { /* Can be NULL (background mode). */
|
||||||
BLI_path_abs(filepath_abs, relpath);
|
BLI_path_abs(filepath_abs, relpath);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,9 +59,9 @@ typedef struct FileReader {
|
|||||||
/* Functions for opening the various types of FileReader.
|
/* Functions for opening the various types of FileReader.
|
||||||
* They either succeed and return a valid FileReader, or fail and return NULL.
|
* They either succeed and return a valid FileReader, or fail and return NULL.
|
||||||
*
|
*
|
||||||
* If a FileReader is created, it has to be cleaned up and freed by calling
|
* If a FileReader is created, it has to be cleaned up and freed by calling its close()
|
||||||
* its close() function unless another FileReader has taken ownership - for example,
|
* function unless another FileReader has taken ownership - for example, `Zstd` & `Gzip`
|
||||||
* Zstd and Gzip take over the base FileReader and will clean it up when their clean() is called.
|
* take over the base FileReader and will clean it up when their clean() is called.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Create FileReader from raw file descriptor. */
|
/* Create FileReader from raw file descriptor. */
|
||||||
@ -71,9 +71,9 @@ FileReader *BLI_filereader_new_mmap(int filedes) ATTR_WARN_UNUSED_RESULT;
|
|||||||
/* Create FileReader from a region of memory. */
|
/* Create FileReader from a region of memory. */
|
||||||
FileReader *BLI_filereader_new_memory(const void *data, size_t len) ATTR_WARN_UNUSED_RESULT
|
FileReader *BLI_filereader_new_memory(const void *data, size_t len) ATTR_WARN_UNUSED_RESULT
|
||||||
ATTR_NONNULL();
|
ATTR_NONNULL();
|
||||||
/* Create FileReader from applying Zstd decompression on an underlying file. */
|
/* Create FileReader from applying `Zstd` decompression on an underlying file. */
|
||||||
FileReader *BLI_filereader_new_zstd(FileReader *base) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL();
|
FileReader *BLI_filereader_new_zstd(FileReader *base) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL();
|
||||||
/* Create FileReader from applying Gzip decompression on an underlying file. */
|
/* Create FileReader from applying `Gzip` decompression on an underlying file. */
|
||||||
FileReader *BLI_filereader_new_gzip(FileReader *base) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL();
|
FileReader *BLI_filereader_new_gzip(FileReader *base) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL();
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@ -438,9 +438,9 @@ bool isect_tri_tri_v2(const float p1[2],
|
|||||||
const float q2[2],
|
const float q2[2],
|
||||||
const float r2[2]);
|
const float r2[2]);
|
||||||
|
|
||||||
/* water-tight raycast (requires pre-calculation) */
|
/* water-tight ray-cast (requires pre-calculation). */
|
||||||
struct IsectRayPrecalc {
|
struct IsectRayPrecalc {
|
||||||
/* Maximal dimension kz, and orthogonal dimensions. */
|
/* Maximal dimension `kz`, and orthogonal dimensions. */
|
||||||
int kx, ky, kz;
|
int kx, ky, kz;
|
||||||
|
|
||||||
/* Shear constants. */
|
/* Shear constants. */
|
||||||
|
@ -89,7 +89,7 @@ size_t BLI_file_zstd_from_mem_at_pos(
|
|||||||
total_written += output.pos;
|
total_written += output.pos;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Finalize the Zstd frame. */
|
/* Finalize the `Zstd` frame. */
|
||||||
size_t ret = 1;
|
size_t ret = 1;
|
||||||
while (ret != 0) {
|
while (ret != 0) {
|
||||||
ZSTD_outBuffer output = {out_buf, out_len, 0};
|
ZSTD_outBuffer output = {out_buf, out_len, 0};
|
||||||
|
@ -1162,7 +1162,7 @@ static int filter_plane_side(const double3 &p,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* interesect_tri_tri and helper functions.
|
* #intersect_tri_tri and helper functions.
|
||||||
* This code uses the algorithm of Guigue and Devillers, as described
|
* This code uses the algorithm of Guigue and Devillers, as described
|
||||||
* in "Faster Triangle-Triangle Intersection Tests".
|
* in "Faster Triangle-Triangle Intersection Tests".
|
||||||
* Adapted from code by Eric Haines:
|
* Adapted from code by Eric Haines:
|
||||||
|
@ -1230,13 +1230,13 @@ static FileData *blo_filedata_from_file_descriptor(const char *filepath,
|
|||||||
else if (BLI_file_magic_is_gzip(header)) {
|
else if (BLI_file_magic_is_gzip(header)) {
|
||||||
file = BLI_filereader_new_gzip(rawfile);
|
file = BLI_filereader_new_gzip(rawfile);
|
||||||
if (file != NULL) {
|
if (file != NULL) {
|
||||||
rawfile = NULL; /* The Gzip FileReader takes ownership of `rawfile`. */
|
rawfile = NULL; /* The `Gzip` #FileReader takes ownership of `rawfile`. */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (BLI_file_magic_is_zstd(header)) {
|
else if (BLI_file_magic_is_zstd(header)) {
|
||||||
file = BLI_filereader_new_zstd(rawfile);
|
file = BLI_filereader_new_zstd(rawfile);
|
||||||
if (file != NULL) {
|
if (file != NULL) {
|
||||||
rawfile = NULL; /* The Zstd FileReader takes ownership of `rawfile`. */
|
rawfile = NULL; /* The `Zstd` #FileReader takes ownership of `rawfile`. */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1770,7 +1770,7 @@ void blo_do_versions_300(FileData *fd, Library *UNUSED(lib), Main *bmain)
|
|||||||
{
|
{
|
||||||
/* Keep this block, even when empty. */
|
/* Keep this block, even when empty. */
|
||||||
|
|
||||||
/* Update the idnames for renamed geo and function nodes */
|
/* Update the `idnames` for renamed geometry and function nodes. */
|
||||||
LISTBASE_FOREACH (bNodeTree *, ntree, &bmain->nodetrees) {
|
LISTBASE_FOREACH (bNodeTree *, ntree, &bmain->nodetrees) {
|
||||||
if (ntree->type != NTREE_GEOMETRY) {
|
if (ntree->type != NTREE_GEOMETRY) {
|
||||||
continue;
|
continue;
|
||||||
|
@ -488,7 +488,7 @@ void EEVEE_draw_effects(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
|
|||||||
EEVEE_depth_of_field_draw(vedata);
|
EEVEE_depth_of_field_draw(vedata);
|
||||||
|
|
||||||
/* NOTE: Lookdev drawing happens before TAA but after
|
/* NOTE: Lookdev drawing happens before TAA but after
|
||||||
* motion blur and dof to avoid distortions.
|
* motion blur and DOF to avoid distortions.
|
||||||
* Velocity resolve use a hack to exclude lookdev
|
* Velocity resolve use a hack to exclude lookdev
|
||||||
* spheres from creating shimmering re-projection vectors. */
|
* spheres from creating shimmering re-projection vectors. */
|
||||||
EEVEE_lookdev_draw(vedata);
|
EEVEE_lookdev_draw(vedata);
|
||||||
@ -500,7 +500,7 @@ void EEVEE_draw_effects(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
|
|||||||
* the swapping of the buffers. */
|
* the swapping of the buffers. */
|
||||||
EEVEE_renderpasses_output_accumulate(sldata, vedata, true);
|
EEVEE_renderpasses_output_accumulate(sldata, vedata, true);
|
||||||
|
|
||||||
/* Save the final texture and framebuffer for final transformation or read. */
|
/* Save the final texture and frame-buffer for final transformation or read. */
|
||||||
effects->final_tx = effects->source_buffer;
|
effects->final_tx = effects->source_buffer;
|
||||||
effects->final_fb = (effects->target_buffer != fbl->main_color_fb) ? fbl->main_fb :
|
effects->final_fb = (effects->target_buffer != fbl->main_color_fb) ? fbl->main_fb :
|
||||||
fbl->effect_fb;
|
fbl->effect_fb;
|
||||||
|
@ -645,7 +645,7 @@ void ED_screen_refresh(wmWindowManager *wm, wmWindow *win)
|
|||||||
{
|
{
|
||||||
bScreen *screen = WM_window_get_active_screen(win);
|
bScreen *screen = WM_window_get_active_screen(win);
|
||||||
|
|
||||||
/* exception for bg mode, we only need the screen context */
|
/* Exception for background mode, we only need the screen context. */
|
||||||
if (!G.background) {
|
if (!G.background) {
|
||||||
/* header size depends on DPI, let's verify */
|
/* header size depends on DPI, let's verify */
|
||||||
WM_window_set_dpi(win);
|
WM_window_set_dpi(win);
|
||||||
|
@ -311,7 +311,7 @@ static int sculpt_set_pivot_position_exec(bContext *C, wmOperator *op)
|
|||||||
else if (mode == SCULPT_PIVOT_POSITION_ACTIVE_VERTEX) {
|
else if (mode == SCULPT_PIVOT_POSITION_ACTIVE_VERTEX) {
|
||||||
copy_v3_v3(ss->pivot_pos, SCULPT_active_vertex_co_get(ss));
|
copy_v3_v3(ss->pivot_pos, SCULPT_active_vertex_co_get(ss));
|
||||||
}
|
}
|
||||||
/* Pivot to raycast surface. */
|
/* Pivot to ray-cast surface. */
|
||||||
else if (mode == SCULPT_PIVOT_POSITION_CURSOR_SURFACE) {
|
else if (mode == SCULPT_PIVOT_POSITION_CURSOR_SURFACE) {
|
||||||
float stroke_location[3];
|
float stroke_location[3];
|
||||||
float mouse[2];
|
float mouse[2];
|
||||||
|
@ -709,7 +709,7 @@ static int txtfmt_pov_find_bool(const char *string)
|
|||||||
/* Keep aligned args for readability. */
|
/* Keep aligned args for readability. */
|
||||||
/* clang-format off */
|
/* clang-format off */
|
||||||
|
|
||||||
/* Built-in Constants */
|
/* Built-in Constants. */
|
||||||
if (STR_LITERAL_STARTSWITH(string, "unofficial", len)) { i = len;
|
if (STR_LITERAL_STARTSWITH(string, "unofficial", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "false", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "false", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "no", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "no", len)) { i = len;
|
||||||
@ -719,7 +719,7 @@ static int txtfmt_pov_find_bool(const char *string)
|
|||||||
} else if (STR_LITERAL_STARTSWITH(string, "on", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "on", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "pi", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "pi", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "tau", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "tau", len)) { i = len;
|
||||||
/* Encodings */
|
/* Encodings. */
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "sint16be", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "sint16be", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "sint16le", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "sint16le", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "sint32be", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "sint32be", len)) { i = len;
|
||||||
@ -732,7 +732,7 @@ static int txtfmt_pov_find_bool(const char *string)
|
|||||||
} else if (STR_LITERAL_STARTSWITH(string, "uint8", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "uint8", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "ascii", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "ascii", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "utf8", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "utf8", len)) { i = len;
|
||||||
/* Filetypes */
|
/* File-types. */
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "tiff", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "tiff", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "df3", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "df3", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "exr", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "exr", len)) { i = len;
|
||||||
|
@ -279,7 +279,7 @@ static int txtfmt_ini_find_reserved(const char *string)
|
|||||||
} else if (STR_LITERAL_STARTSWITH(string, "Dither", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "Dither", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "Flags", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "Flags", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "Font", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "Font", len)) { i = len;
|
||||||
/* Filetypes */
|
/* File-types. */
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "df3", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "df3", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "exr", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "exr", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "gif", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "gif", len)) { i = len;
|
||||||
@ -292,7 +292,7 @@ static int txtfmt_ini_find_reserved(const char *string)
|
|||||||
} else if (STR_LITERAL_STARTSWITH(string, "sys", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "sys", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "tga", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "tga", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "tiff", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "tiff", len)) { i = len;
|
||||||
/* Encodings */
|
/* Encodings. */
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "ascii", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "ascii", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "utf8", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "utf8", len)) { i = len;
|
||||||
} else if (STR_LITERAL_STARTSWITH(string, "uint8", len)) { i = len;
|
} else if (STR_LITERAL_STARTSWITH(string, "uint8", len)) { i = len;
|
||||||
|
@ -1325,7 +1325,7 @@ bool peelObjectsTransform(TransInfo *t,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* in this case has only one hit. treat as raycast */
|
/* In this case has only one hit. treat as ray-cast. */
|
||||||
if (hit_max == NULL) {
|
if (hit_max == NULL) {
|
||||||
hit_max = hit_min;
|
hit_max = hit_min;
|
||||||
}
|
}
|
||||||
|
@ -472,8 +472,7 @@ bool handleNumInput(bContext *C, NumInput *n, const wmEvent *event)
|
|||||||
return true;
|
return true;
|
||||||
case EVT_PADPERIOD:
|
case EVT_PADPERIOD:
|
||||||
case EVT_PERIODKEY:
|
case EVT_PERIODKEY:
|
||||||
/* Force numdot, some OSs/countries generate a comma char in this case,
|
/* Force number-pad "." since some OS's/countries generate a comma char, see: T37992 */
|
||||||
* sic... (T37992) */
|
|
||||||
ascii[0] = '.';
|
ascii[0] = '.';
|
||||||
utf8_buf = ascii;
|
utf8_buf = ascii;
|
||||||
break;
|
break;
|
||||||
|
@ -939,7 +939,7 @@ typedef enum eTrackToAxis_Modes {
|
|||||||
|
|
||||||
/* Shrinkwrap flags */
|
/* Shrinkwrap flags */
|
||||||
typedef enum eShrinkwrap_Flags {
|
typedef enum eShrinkwrap_Flags {
|
||||||
/* Also raycast in the opposite direction. */
|
/* Also ray-cast in the opposite direction. */
|
||||||
CON_SHRINKWRAP_PROJECT_OPPOSITE = (1 << 0),
|
CON_SHRINKWRAP_PROJECT_OPPOSITE = (1 << 0),
|
||||||
/* Invert the cull mode when projecting opposite. */
|
/* Invert the cull mode when projecting opposite. */
|
||||||
CON_SHRINKWRAP_PROJECT_INVERT_CULL = (1 << 1),
|
CON_SHRINKWRAP_PROJECT_INVERT_CULL = (1 << 1),
|
||||||
|
@ -28,7 +28,7 @@ extern "C" {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Keep for 'Camera' versioning. */
|
/* Keep for 'Camera' versioning. */
|
||||||
/** Properties for dof effect. */
|
/** Properties for DOF effect. */
|
||||||
typedef struct GPUDOFSettings {
|
typedef struct GPUDOFSettings {
|
||||||
/** Focal distance for depth of field. */
|
/** Focal distance for depth of field. */
|
||||||
float focus_distance;
|
float focus_distance;
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#include "DNA_ID.h"
|
#include "DNA_ID.h"
|
||||||
#include "DNA_color_types.h" /* color management */
|
#include "DNA_color_types.h" /* color management */
|
||||||
#include "DNA_customdata_types.h" /* Scene's runtime cddata masks. */
|
#include "DNA_customdata_types.h" /* Scene's runtime custom-data masks. */
|
||||||
#include "DNA_layer_types.h"
|
#include "DNA_layer_types.h"
|
||||||
#include "DNA_listBase.h"
|
#include "DNA_listBase.h"
|
||||||
#include "DNA_vec_types.h"
|
#include "DNA_vec_types.h"
|
||||||
|
@ -772,7 +772,7 @@ typedef struct FileSelectParams {
|
|||||||
const ID *rename_id;
|
const ID *rename_id;
|
||||||
void *_pad3;
|
void *_pad3;
|
||||||
|
|
||||||
/** List of filetypes to filter (FILE_MAXFILE). */
|
/** List of file-types to filter (#FILE_MAXFILE). */
|
||||||
char filter_glob[256];
|
char filter_glob[256];
|
||||||
|
|
||||||
/** Text items name must match to be shown. */
|
/** Text items name must match to be shown. */
|
||||||
|
@ -1800,7 +1800,7 @@ static void sdna_expand_names(SDNA *sdna)
|
|||||||
|
|
||||||
int names_expand_index = 0;
|
int names_expand_index = 0;
|
||||||
for (int struct_nr = 0; struct_nr < sdna->structs_len; struct_nr++) {
|
for (int struct_nr = 0; struct_nr < sdna->structs_len; struct_nr++) {
|
||||||
/* We can't edit this memory 'sdna->structs' points to (readonly datatoc file). */
|
/* We can't edit this memory 'sdna->structs' points to (read-only `datatoc` file). */
|
||||||
const SDNA_Struct *struct_old = sdna->structs[struct_nr];
|
const SDNA_Struct *struct_old = sdna->structs[struct_nr];
|
||||||
|
|
||||||
const int array_size = sizeof(short) * 2 + sizeof(SDNA_StructMember) * struct_old->members_len;
|
const int array_size = sizeof(short) * 2 + sizeof(SDNA_StructMember) * struct_old->members_len;
|
||||||
|
@ -495,7 +495,7 @@ class NearestTransferFunction : public fn::MultiFunction {
|
|||||||
Array<int> mesh_indices;
|
Array<int> mesh_indices;
|
||||||
Array<float> mesh_distances;
|
Array<float> mesh_distances;
|
||||||
|
|
||||||
/* If there is a pointcloud, find the closest points. */
|
/* If there is a point-cloud, find the closest points. */
|
||||||
if (use_points_) {
|
if (use_points_) {
|
||||||
point_indices.reinitialize(tot_samples);
|
point_indices.reinitialize(tot_samples);
|
||||||
if (use_mesh_) {
|
if (use_mesh_) {
|
||||||
@ -594,7 +594,7 @@ static const GeometryComponent *find_best_match_component(const GeometrySet &geo
|
|||||||
|
|
||||||
/* If there is no component of the same type, choose the other component based on a consistent
|
/* If there is no component of the same type, choose the other component based on a consistent
|
||||||
* order, rather than some more complicated heuristic. This is the same order visible in the
|
* order, rather than some more complicated heuristic. This is the same order visible in the
|
||||||
* spreadsheet and used in the raycast node. */
|
* spreadsheet and used in the ray-cast node. */
|
||||||
static const Array<GeometryComponentType> supported_types = {
|
static const Array<GeometryComponentType> supported_types = {
|
||||||
GEO_COMPONENT_TYPE_MESH, GEO_COMPONENT_TYPE_POINT_CLOUD, GEO_COMPONENT_TYPE_CURVE};
|
GEO_COMPONENT_TYPE_MESH, GEO_COMPONENT_TYPE_POINT_CLOUD, GEO_COMPONENT_TYPE_CURVE};
|
||||||
for (const GeometryComponentType src_type : supported_types) {
|
for (const GeometryComponentType src_type : supported_types) {
|
||||||
@ -607,8 +607,8 @@ static const GeometryComponent *find_best_match_component(const GeometrySet &geo
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use a FieldInput because it's necessary to know the field context in order to choose the
|
* Use a #FieldInput because it's necessary to know the field context in order to choose the
|
||||||
* corresponding component type from the input geometry, and only a FieldInput receives the
|
* corresponding component type from the input geometry, and only a #FieldInput receives the
|
||||||
* evaluation context to provide its data.
|
* evaluation context to provide its data.
|
||||||
*
|
*
|
||||||
* The index-based transfer theoretically does not need realized data when there is only one
|
* The index-based transfer theoretically does not need realized data when there is only one
|
||||||
|
@ -3837,7 +3837,7 @@ void WM_event_fileselect_event(wmWindowManager *wm, void *ophandle, int eventval
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Operator is supposed to have a filled "path" property. */
|
/* Operator is supposed to have a filled "path" property. */
|
||||||
/* Optional property: filetype (XXX enum?) */
|
/* Optional property: file-type (XXX enum?) */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The idea here is to keep a handler alive on window queue, owning the operator.
|
* The idea here is to keep a handler alive on window queue, owning the operator.
|
||||||
|
@ -526,7 +526,7 @@ static int wm_read_exotic(const char *name)
|
|||||||
/* check for compressed .blend */
|
/* check for compressed .blend */
|
||||||
FileReader *compressed_file = NULL;
|
FileReader *compressed_file = NULL;
|
||||||
if (BLI_file_magic_is_gzip(header)) {
|
if (BLI_file_magic_is_gzip(header)) {
|
||||||
/* In earlier versions of Blender (before 3.0), compressed files used Gzip instead of Zstd.
|
/* In earlier versions of Blender (before 3.0), compressed files used `Gzip` instead of `Zstd`.
|
||||||
* While these files will no longer be written, there still needs to be reading support. */
|
* While these files will no longer be written, there still needs to be reading support. */
|
||||||
compressed_file = BLI_filereader_new_gzip(rawfile);
|
compressed_file = BLI_filereader_new_gzip(rawfile);
|
||||||
}
|
}
|
||||||
|
@ -258,7 +258,9 @@ void main_signal_setup_background(void)
|
|||||||
BLI_assert(G.background);
|
BLI_assert(G.background);
|
||||||
|
|
||||||
# if !defined(WITH_HEADLESS)
|
# if !defined(WITH_HEADLESS)
|
||||||
signal(SIGINT, sig_handle_blender_esc); /* ctrl c out bg render */
|
/* Support pressing `Ctrl-C` to close Blender in background-mode.
|
||||||
|
* Useful to be able to cancel a render operation. */
|
||||||
|
signal(SIGINT, sig_handle_blender_esc);
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user