Cleanup: Replace "UV's" with "UVs"
An apostrophe should not be used because it is not a mark of plural, even for initialisms. This involves mostly comments, but a few UI messages are affected as well. Differential Revision: https://developer.blender.org/D16749
This commit is contained in:
parent
5bc71f22a2
commit
30c90f0ad0
|
@ -13,16 +13,16 @@ Blender stores 4 main arrays to define mesh geometry.
|
|||
- :class:`Mesh.polygons`: (reference a range of loops)
|
||||
|
||||
|
||||
Each polygon reference a slice in the loop array, this way, polygons do not store vertices or corner data such as UV's directly,
|
||||
Each polygon references a slice in the loop array, this way, polygons do not store vertices or corner data such as UVs directly,
|
||||
only a reference to loops that the polygon uses.
|
||||
|
||||
:class:`Mesh.loops`, :class:`Mesh.uv_layers` :class:`Mesh.vertex_colors` are all aligned so the same polygon loop
|
||||
indices can be used to find the UV's and vertex colors as with as the vertices.
|
||||
indices can be used to find the UVs and vertex colors as with as the vertices.
|
||||
|
||||
To compare mesh API options see: :ref:`NGons and Tessellation Faces <info_gotcha_mesh_faces>`
|
||||
|
||||
|
||||
This example script prints the vertices and UV's for each polygon, assumes the active object is a mesh with UVs.
|
||||
This example script prints the vertices and UVs for each polygon, assumes the active object is a mesh with UVs.
|
||||
"""
|
||||
|
||||
import bpy
|
||||
|
|
|
@ -127,7 +127,7 @@ def object_data_add(context, obdata, operator=None, name=None):
|
|||
layer.update() # apply location
|
||||
# layer.objects.active = obj_new
|
||||
|
||||
# Match up UV layers, this is needed so adding an object with UV's
|
||||
# Match up UV layers, this is needed so adding an object with UVs
|
||||
# doesn't create new layers when there happens to be a naming mismatch.
|
||||
uv_new = obdata.uv_layers.active
|
||||
if uv_new is not None:
|
||||
|
|
|
@ -71,7 +71,7 @@ def add_uvs(mesh, minor_seg, major_seg):
|
|||
u_step = 1.0 / major_seg
|
||||
v_step = 1.0 / minor_seg
|
||||
|
||||
# Round UV's, needed when segments aren't divisible by 4.
|
||||
# Round UVs, needed when segments aren't divisible by 4.
|
||||
u_init = 0.5 + fmod(0.5, u_step)
|
||||
v_init = 0.5 + fmod(0.5, v_step)
|
||||
|
||||
|
|
|
@ -84,7 +84,7 @@ class prettyface:
|
|||
# ngon, note:
|
||||
# for ngons to calculate the width/height we need to do the
|
||||
# whole projection, unlike other faces
|
||||
# we store normalized UV's in the faces coords to avoid
|
||||
# we store normalized UVs in the faces coords to avoid
|
||||
# calculating the projection and rotating it twice.
|
||||
|
||||
no = data.normal
|
||||
|
@ -110,7 +110,7 @@ class prettyface:
|
|||
self.height = yspan
|
||||
|
||||
# ngons work different, we store projected result
|
||||
# in UV's to avoid having to re-project later.
|
||||
# in UVs to avoid having to re-project later.
|
||||
for i, co in enumerate(cos_2d):
|
||||
self.uv[i][:] = ((co.x - xmin) / xspan,
|
||||
(co.y - ymin) / yspan)
|
||||
|
@ -570,7 +570,7 @@ from bpy.props import BoolProperty, FloatProperty, IntProperty
|
|||
|
||||
|
||||
class LightMapPack(Operator):
|
||||
"""Pack each faces UV's into the UV bounds"""
|
||||
"""Pack each face's UVs into the UV bounds"""
|
||||
bl_idname = "uv.lightmap_pack"
|
||||
bl_label = "Lightmap Pack"
|
||||
|
||||
|
|
|
@ -807,9 +807,9 @@ struct Mesh *BKE_mesh_merge_verts(struct Mesh *mesh,
|
|||
int merge_mode);
|
||||
|
||||
/**
|
||||
* Account for custom-data such as UV's becoming detached because of imprecision
|
||||
* Account for custom-data such as UVs becoming detached because of imprecision
|
||||
* in custom-data interpolation.
|
||||
* Without running this operation subdivision surface can cause UV's to be disconnected,
|
||||
* Without running this operation subdivision surface can cause UVs to be disconnected,
|
||||
* see: T81065.
|
||||
*/
|
||||
void BKE_mesh_merge_customdata_for_apply_modifier(struct Mesh *me);
|
||||
|
|
|
@ -59,7 +59,7 @@ struct UVPrimitivePaintInput {
|
|||
/** Corresponding index into PaintGeometryPrimitives */
|
||||
int64_t geometry_primitive_index;
|
||||
/**
|
||||
* Delta barycentric coordinates between 2 neighboring UV's in the U direction.
|
||||
* Delta barycentric coordinates between 2 neighboring UVs in the U direction.
|
||||
*
|
||||
* Only the first two coordinates are stored. The third should be recalculated
|
||||
*/
|
||||
|
|
|
@ -510,7 +510,7 @@ static bool is_uv_bool_sublayer(CustomDataLayer const *l)
|
|||
is_sublayer_name(UV_PINNED_NAME, name);
|
||||
}
|
||||
|
||||
/** Thresh is threshold for comparing vertices, UV's, vertex colors, weights, etc. */
|
||||
/** Thresh is threshold for comparing vertices, UVs, vertex colors, weights, etc. */
|
||||
static int customdata_compare(
|
||||
CustomData *c1, CustomData *c2, const int total_length, Mesh *m1, Mesh *m2, const float thresh)
|
||||
{
|
||||
|
|
|
@ -524,7 +524,7 @@ static void convert_mfaces_to_mpolys(ID *id,
|
|||
}
|
||||
|
||||
/* NOTE: we don't convert NGons at all, these are not even real ngons,
|
||||
* they have their own UV's, colors etc - its more an editing feature. */
|
||||
* they have their own UVs, colors etc - it's more an editing feature. */
|
||||
|
||||
BLI_edgehash_free(eh, nullptr);
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
* \ingroup bke
|
||||
*
|
||||
* Functions for accessing mesh connectivity data.
|
||||
* eg: polys connected to verts, UV's connected to verts.
|
||||
* eg: polys connected to verts, UVs connected to verts.
|
||||
*/
|
||||
|
||||
#include "MEM_guardedalloc.h"
|
||||
|
|
|
@ -38,11 +38,11 @@ static int compare_v2_classify(const float uv_a[2], const float uv_b[2])
|
|||
* values as the absolute value doesn't account for float precision at difference scales.
|
||||
* - For subdivision-surface ULP of 3 is sufficient,
|
||||
* although this value is extremely small.
|
||||
* - For bevel the ULP of 12 is sufficient to merge UV's that appear to be connected
|
||||
* - For bevel the ULP of 12 is sufficient to merge UVs that appear to be connected
|
||||
* with bevel on Suzanne beveled 15% with 6 segments.
|
||||
*
|
||||
* These values could be tweaked but should be kept on the small side to prevent
|
||||
* unintentional joining of intentionally dis-connected UV's.
|
||||
* unintentional joining of intentionally disconnected UVs.
|
||||
*
|
||||
* Before v2.91 the threshold was either (`1e-4` or `0.05 / image_size` for selection picking).
|
||||
* So picking used a threshold of `1e-4` for a 500x500 image and `1e-5` for a 5000x5000 image.
|
||||
|
@ -63,7 +63,7 @@ static void merge_uvs_for_vertex(const Span<int> loops_for_vert, Span<float2 *>
|
|||
if (loops_for_vert.size() <= 1) {
|
||||
return;
|
||||
}
|
||||
/* Manipulate a copy of the loop indices, de-duplicating UV's per layer. */
|
||||
/* Manipulate a copy of the loop indices, de-duplicating UVs per layer. */
|
||||
Vector<int, 32> loops_merge;
|
||||
loops_merge.reserve(loops_for_vert.size());
|
||||
for (float2 *mloopuv : mloopuv_layers) {
|
||||
|
|
|
@ -40,7 +40,7 @@ void BLI_uvproject_from_view(float target[2],
|
|||
float winy);
|
||||
|
||||
/**
|
||||
* Apply orthographic UV's.
|
||||
* Apply orthographic UVs.
|
||||
*/
|
||||
void BLI_uvproject_from_view_ortho(float target[2], float source[3], const float rotmat[4][4]);
|
||||
|
||||
|
|
|
@ -1791,7 +1791,7 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
|
|||
/* MTexPoly now removed. */
|
||||
if (DNA_struct_find(fd->filesdna, "MTexPoly")) {
|
||||
for (Mesh *me = bmain->meshes.first; me; me = me->id.next) {
|
||||
/* If we have UV's, so this file will have MTexPoly layers too! */
|
||||
/* If we have UVs, so this file will have MTexPoly layers too! */
|
||||
if (CustomData_has_layer(&me->ldata, CD_MLOOPUV) ||
|
||||
CustomData_has_layer(&me->ldata, CD_PROP_FLOAT2)) {
|
||||
CustomData_update_typemap(&me->pdata);
|
||||
|
|
|
@ -349,7 +349,7 @@ static void blo_update_defaults_scene(Main *bmain, Scene *scene)
|
|||
ts->sculpt->paint.symmetry_flags |= PAINT_SYMMETRY_FEATHER;
|
||||
}
|
||||
|
||||
/* Correct default startup UV's. */
|
||||
/* Correct default startup UVs. */
|
||||
Mesh *me = static_cast<Mesh *>(BLI_findstring(&bmain->meshes, "Cube", offsetof(ID, name) + 2));
|
||||
if (me && (me->totloop == 24) && CustomData_has_layer(&me->ldata, CD_PROP_FLOAT2)) {
|
||||
const float uv_values[24][2] = {
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
* BMesh stores topology in four main element structures:
|
||||
*
|
||||
* - Faces - BMFace
|
||||
* - Loops - BMLoop, (stores per-face-vertex data, UV's, vertex-colors, etc)
|
||||
* - Loops - BMLoop, (stores per-face-vertex data, UVs, vertex-colors, etc)
|
||||
* - Edges - BMEdge
|
||||
* - Verts - BMVert
|
||||
* \subsection bm_header_flags Header Flags
|
||||
|
|
|
@ -1045,7 +1045,7 @@ void BM_elem_float_data_set(CustomData *cd, void *element, int type, const float
|
|||
/* -------------------------------------------------------------------- */
|
||||
/** \name Loop interpolation functions: BM_vert_loop_groups_data_layer_***
|
||||
*
|
||||
* Handling loop custom-data such as UV's, while keeping contiguous fans is rather tedious.
|
||||
* Handling loop custom-data such as UVs, while keeping contiguous fans is rather tedious.
|
||||
* Especially when a verts loops can have multiple CustomData layers,
|
||||
* and each layer can have multiple (different) contiguous fans.
|
||||
* Said differently, a single vertices loops may span multiple UV islands.
|
||||
|
|
|
@ -447,7 +447,7 @@ static BMOpDefine bmo_pointmerge_def = {
|
|||
};
|
||||
|
||||
/*
|
||||
* Collapse Connected UV's.
|
||||
* Collapse Connected UVs.
|
||||
*
|
||||
* Collapses connected UV vertices.
|
||||
*/
|
||||
|
@ -1453,7 +1453,7 @@ static BMOpDefine bmo_spin_def = {
|
|||
/*
|
||||
* UV Rotation.
|
||||
*
|
||||
* Cycle the loop UV's
|
||||
* Cycle the loop UVs
|
||||
*/
|
||||
static BMOpDefine bmo_rotate_uvs_def = {
|
||||
"rotate_uvs",
|
||||
|
@ -1470,7 +1470,7 @@ static BMOpDefine bmo_rotate_uvs_def = {
|
|||
/*
|
||||
* UV Reverse.
|
||||
*
|
||||
* Reverse the UV's
|
||||
* Reverse the UVs
|
||||
*/
|
||||
static BMOpDefine bmo_reverse_uvs_def = {
|
||||
"reverse_uvs",
|
||||
|
|
|
@ -162,7 +162,7 @@ void BM_mesh_esubdivide(BMesh *bm,
|
|||
int seed);
|
||||
|
||||
/**
|
||||
* Fills first available UV-map with grid-like UV's for all faces with `oflag` set.
|
||||
* Fills first available UV-map with grid-like UVs for all faces with `oflag` set.
|
||||
*
|
||||
* \param bm: The BMesh to operate on
|
||||
* \param x_segments: The x-resolution of the grid
|
||||
|
|
|
@ -1546,7 +1546,7 @@ static void *bmw_UVEdgeWalker_step(BMWalker *walker)
|
|||
}
|
||||
|
||||
/* Go over loops around `l->v` and `l->next->v` and see which ones share `l` and `l->next`
|
||||
* UV's coordinates. in addition, push on `l->next` if necessary. */
|
||||
* UV coordinates. in addition, push on `l->next` if necessary. */
|
||||
for (i = 0; i < 2; i++) {
|
||||
BMIter liter;
|
||||
BMLoop *l_pivot, *l_radial;
|
||||
|
|
|
@ -97,7 +97,7 @@ static void bm_interp_face_free(InterpFace *iface, BMesh *bm)
|
|||
|
||||
#ifdef USE_LOOP_CUSTOMDATA_MERGE
|
||||
/**
|
||||
* This function merges loop customdata (UV's)
|
||||
* This function merges loop customdata (UVs)
|
||||
* where interpolating the values across the face causes values to diverge.
|
||||
*/
|
||||
static void bm_loop_customdata_merge(BMesh *bm,
|
||||
|
@ -177,7 +177,7 @@ static void bm_loop_customdata_merge(BMesh *bm,
|
|||
BM_ELEM_CD_GET_VOID_P(l_a_outer, offset),
|
||||
BM_ELEM_CD_GET_VOID_P(l_b_outer, offset)) == true)
|
||||
|
||||
/* Epsilon for comparing UV's is too big, gives noticeable problems. */
|
||||
/* Epsilon for comparing UVs is too big, gives noticeable problems. */
|
||||
# if 0
|
||||
&&
|
||||
/* check if the data ends up diverged */
|
||||
|
@ -1183,7 +1183,7 @@ void bmo_inset_region_exec(BMesh *bm, BMOperator *op)
|
|||
f = BM_face_create_verts(bm, varr, j, es->l->f, BM_CREATE_NOP, true);
|
||||
BMO_face_flag_enable(bm, f, ELE_NEW);
|
||||
|
||||
/* Copy for loop data, otherwise UV's and vcols are no good.
|
||||
/* Copy for loop data, otherwise UVs and vcols are no good.
|
||||
* tiny speedup here we could be more clever and copy from known adjacent data
|
||||
* also - we could attempt to interpolate the loop data,
|
||||
* this would be much slower but more useful too. */
|
||||
|
|
|
@ -97,7 +97,7 @@ typedef struct EdgeHalf {
|
|||
bool is_bev;
|
||||
/** Is e->v2 the vertex at this end? */
|
||||
bool is_rev;
|
||||
/** Is e a seam for custom loop-data (e.g., UV's). */
|
||||
/** Is e a seam for custom loop-data (e.g., UVs). */
|
||||
bool is_seam;
|
||||
/** Used during the custom profile orientation pass. */
|
||||
bool visited_rpo;
|
||||
|
@ -5463,7 +5463,7 @@ static void bevel_build_rings(BevelParams *bp, BMesh *bm, BevVert *bv, BoundVert
|
|||
BMVert *bmv4 = mesh_vert(vm, i, j + 1, k)->v;
|
||||
BMVert *bmvs[4] = {bmv1, bmv2, bmv3, bmv4};
|
||||
BLI_assert(bmv1 && bmv2 && bmv3 && bmv4);
|
||||
/* For each created quad, the UV's etc. will be interpolated
|
||||
/* For each created quad, the UVs etc. will be interpolated
|
||||
* in potentially a different face for each corner and may need
|
||||
* to snap to a particular edge before interpolating.
|
||||
* The fr and se arrays will be filled with the interpolation faces
|
||||
|
|
|
@ -278,7 +278,7 @@ static bool apply_mesh_output_to_bmesh(BMesh *bm, IMesh &m_out, bool keep_hidden
|
|||
BM_elem_select_copy(bm, bmf, orig_face);
|
||||
}
|
||||
BM_elem_flag_enable(bmf, KEEP_FLAG);
|
||||
/* Now do interpolation of loop data (e.g., UV's) using the example face. */
|
||||
/* Now do interpolation of loop data (e.g., UVs) using the example face. */
|
||||
if (orig_face != nullptr) {
|
||||
BMIter liter;
|
||||
BMLoop *l = static_cast<BMLoop *>(BM_iter_new(&liter, bm, BM_LOOPS_OF_FACE, bmf));
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
* Supported:
|
||||
* - Concave faces.
|
||||
* - Non-planar faces.
|
||||
* - Custom-data (UV's etc).
|
||||
* - Custom-data (UVs etc).
|
||||
*
|
||||
* Unsupported:
|
||||
* - Intersecting between different meshes.
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
* (path isn't ordered).
|
||||
*
|
||||
* \note This uses the same behavior as bmesh_path_region.c
|
||||
* however walking UV's causes enough differences that it's
|
||||
* however walking UVs causes enough differences that it's
|
||||
* impractical to share the code.
|
||||
*/
|
||||
|
||||
|
@ -233,7 +233,7 @@ static LinkNode *mesh_calc_path_region_elem(BMesh *bm,
|
|||
continue;
|
||||
}
|
||||
|
||||
/* Flush the depth to connected loops (only needed for UV's). */
|
||||
/* Flush the depth to connected loops (only needed for UVs). */
|
||||
if (depths[side][BM_elem_index_get(l_iter)] == -1) {
|
||||
depths[side][BM_elem_index_get(l_iter)] = depths[side][l_a_index];
|
||||
}
|
||||
|
|
|
@ -102,7 +102,7 @@ void OVERLAY_edit_uv_init(OVERLAY_Data *vedata)
|
|||
const bool show_overlays = !pd->hide_overlays;
|
||||
|
||||
Image *image = sima->image;
|
||||
/* By design no image is an image type. This so editor shows UV's by default. */
|
||||
/* By design no image is an image type. This so editor shows UVs by default. */
|
||||
const bool is_image_type = (image == nullptr) || ELEM(image->type,
|
||||
IMA_TYPE_IMAGE,
|
||||
IMA_TYPE_MULTILAYER,
|
||||
|
|
|
@ -315,7 +315,7 @@ static DRW_MeshCDMask mesh_cd_calc_used_gpu_layers(const Object *object,
|
|||
layer = CustomData_get_named_layer(cd_ldata, CD_PROP_FLOAT2, name);
|
||||
type = CD_MTFACE;
|
||||
|
||||
#if 0 /* Tangents are always from UV's - this will never happen. */
|
||||
#if 0 /* Tangents are always from UVs - this will never happen. */
|
||||
if (layer == -1) {
|
||||
layer = CustomData_get_named_layer(cd_ldata, CD_TANGENT, name);
|
||||
type = CD_TANGENT;
|
||||
|
|
|
@ -2183,7 +2183,7 @@ void DRW_draw_render_loop_2d_ex(struct Depsgraph *depsgraph,
|
|||
DRW_viewport_colormanagement_set(viewport);
|
||||
|
||||
/* TODO(jbakker): Only populate when editor needs to draw object.
|
||||
* for the image editor this is when showing UV's. */
|
||||
* for the image editor this is when showing UVs. */
|
||||
const bool do_populate_loop = (DST.draw_ctx.space_data->spacetype == SPACE_IMAGE);
|
||||
const bool do_annotations = drw_draw_show_annotation();
|
||||
const bool do_draw_gizmos = (DST.draw_ctx.space_data->spacetype != SPACE_IMAGE);
|
||||
|
|
|
@ -61,7 +61,7 @@ static void edituv_get_edituv_stretch_angle(float auv[2][2],
|
|||
const float av[2][3],
|
||||
UVStretchAngle *r_stretch)
|
||||
{
|
||||
/* Send UV's to the shader and let it compute the aspect corrected angle. */
|
||||
/* Send UVs to the shader and let it compute the aspect corrected angle. */
|
||||
r_stretch->uv_angles[0] = v2_to_short_angle(auv[0]);
|
||||
r_stretch->uv_angles[1] = v2_to_short_angle(auv[1]);
|
||||
/* Compute 3D angle here. */
|
||||
|
|
|
@ -153,7 +153,7 @@ struct UvElement **BM_uv_element_map_ensure_head_table(struct UvElementMap *elem
|
|||
int *BM_uv_element_map_ensure_unique_index(struct UvElementMap *element_map);
|
||||
|
||||
/**
|
||||
* Can we edit UV's for this mesh?
|
||||
* Can we edit UVs for this mesh?
|
||||
*/
|
||||
bool EDBM_uv_check(struct BMEditMesh *em);
|
||||
/**
|
||||
|
|
|
@ -733,7 +733,7 @@ void MESH_OT_edge_collapse(wmOperatorType *ot)
|
|||
/* identifiers */
|
||||
ot->name = "Collapse Edges & Faces";
|
||||
ot->description =
|
||||
"Collapse isolated edge and face regions, merging data such as UV's and color attributes. "
|
||||
"Collapse isolated edge and face regions, merging data such as UVs and color attributes. "
|
||||
"This can collapse edge-rings as well as regions of connected faces into vertices";
|
||||
ot->idname = "MESH_OT_edge_collapse";
|
||||
|
||||
|
|
|
@ -3572,7 +3572,7 @@ void OBJECT_OT_convert(wmOperatorType *ot)
|
|||
ot->srna,
|
||||
"merge_customdata",
|
||||
true,
|
||||
"Merge UV's",
|
||||
"Merge UVs",
|
||||
"Merge UV coordinates that share a vertex to account for imprecision in some modifiers");
|
||||
|
||||
prop = RNA_def_float_rotation(ot->srna,
|
||||
|
|
|
@ -1777,7 +1777,7 @@ void OBJECT_OT_modifier_apply(wmOperatorType *ot)
|
|||
RNA_def_boolean(ot->srna,
|
||||
"merge_customdata",
|
||||
true,
|
||||
"Merge UV's",
|
||||
"Merge UVs",
|
||||
"For mesh objects, merge UV coordinates that share a vertex to account for "
|
||||
"imprecision in some modifiers");
|
||||
PropertyRNA *prop = RNA_def_boolean(ot->srna,
|
||||
|
|
|
@ -1034,7 +1034,7 @@ static int line_isect_x(const float p1[2], const float p2[2], const float x_leve
|
|||
#ifndef PROJ_DEBUG_NOSEAMBLEED
|
||||
static bool cmp_uv(const float vec2a[2], const float vec2b[2])
|
||||
{
|
||||
/* if the UV's are not between 0.0 and 1.0 */
|
||||
/* if the UVs are not between 0.0 and 1.0 */
|
||||
float xa = fmodf(vec2a[0], 1.0f);
|
||||
float ya = fmodf(vec2a[1], 1.0f);
|
||||
|
||||
|
@ -1295,8 +1295,8 @@ static float compute_seam_normal(VertSeam *seam, VertSeam *adj, float r_no[2])
|
|||
return angle_rel;
|
||||
}
|
||||
|
||||
/* Calculate outset UV's, this is not the same as simply scaling the UVs,
|
||||
* since the outset coords are a margin that keep an even distance from the original UV's,
|
||||
/* Calculate outset UVs, this is not the same as simply scaling the UVs,
|
||||
* since the outset coords are a margin that keep an even distance from the original UVs,
|
||||
* note that the image aspect is taken into account */
|
||||
static void uv_image_outset(const ProjPaintState *ps,
|
||||
float (*orig_uv)[2],
|
||||
|
@ -2433,7 +2433,7 @@ static bool IsectPT2Df_limit(
|
|||
|
||||
/**
|
||||
* Clip the face by a bucket and set the uv-space bucket_bounds_uv
|
||||
* so we have the clipped UV's to do pixel intersection tests with
|
||||
* so we have the clipped UVs to do pixel intersection tests with
|
||||
*/
|
||||
static int float_z_sort_flip(const void *p1, const void *p2)
|
||||
{
|
||||
|
@ -3241,7 +3241,7 @@ static void project_paint_face_init(const ProjPaintState *ps,
|
|||
float seam_subsection[4][2];
|
||||
float fac1, fac2;
|
||||
|
||||
/* Pixel-space UV's. */
|
||||
/* Pixel-space UVs. */
|
||||
float lt_puv[3][2];
|
||||
|
||||
lt_puv[0][0] = lt_uv_pxoffset[0][0] * ibuf->x;
|
||||
|
@ -4344,7 +4344,7 @@ static void project_paint_prepare_all_faces(ProjPaintState *ps,
|
|||
if (slot->ima == ps->stencil_ima) {
|
||||
/* Delay continuing the loop until after loop_uvs and bleed faces are initialized.
|
||||
* While this shouldn't be used, face-winding reads all polys.
|
||||
* It's less trouble to set all faces to valid UV's,
|
||||
* It's less trouble to set all faces to valid UVs,
|
||||
* avoiding nullptr checks all over. */
|
||||
skip_tri = true;
|
||||
tpage = nullptr;
|
||||
|
|
|
@ -82,7 +82,7 @@ typedef struct UVInitialStroke {
|
|||
/* Initial Selection,for grab brushes for instance */
|
||||
UVInitialStrokeElement *initialSelection;
|
||||
|
||||
/* Total initially selected UV's. */
|
||||
/* Total initially selected UVs. */
|
||||
int totalInitialSelected;
|
||||
|
||||
/* initial mouse coordinates */
|
||||
|
@ -91,9 +91,9 @@ typedef struct UVInitialStroke {
|
|||
|
||||
/* custom data for uv smoothing brush */
|
||||
typedef struct UvSculptData {
|
||||
/* Contains the first of each set of coincident UV's.
|
||||
/* Contains the first of each set of coincident UVs.
|
||||
* These will be used to perform smoothing on and propagate the changes
|
||||
* to their coincident UV's */
|
||||
* to their coincident UVs */
|
||||
UvAdjacencyElement *uv;
|
||||
|
||||
/* Total number of unique UVs. */
|
||||
|
@ -111,7 +111,7 @@ typedef struct UvSculptData {
|
|||
/* timer to be used for airbrush-type brush */
|
||||
wmTimer *timer;
|
||||
|
||||
/* to determine quickly adjacent UV's */
|
||||
/* to determine quickly adjacent UVs */
|
||||
UvElementMap *elementMap;
|
||||
|
||||
/* uvsmooth Paint for fast reference */
|
||||
|
@ -709,7 +709,7 @@ static UvSculptData *uv_sculpt_stroke_init(bContext *C, wmOperator *op, const wm
|
|||
island_index = element->island;
|
||||
}
|
||||
|
||||
/* Count 'unique' UV's */
|
||||
/* Count 'unique' UVs */
|
||||
int unique_uvs = data->elementMap->total_unique_uvs;
|
||||
if (do_island_optimization) {
|
||||
unique_uvs = data->elementMap->island_total_unique_uvs[island_index];
|
||||
|
@ -785,8 +785,8 @@ static UvSculptData *uv_sculpt_stroke_init(bContext *C, wmOperator *op, const wm
|
|||
offset1 = uniqueUv[itmp1];
|
||||
offset2 = uniqueUv[itmp2];
|
||||
|
||||
/* Using an order policy, sort UV's according to address space.
|
||||
* This avoids having two different UvEdges with the same UV's on different positions. */
|
||||
/* Using an order policy, sort UVs according to address space.
|
||||
* This avoids having two different UvEdges with the same UVs on different positions. */
|
||||
if (offset1 < offset2) {
|
||||
edges[counter].uv1 = offset1;
|
||||
edges[counter].uv2 = offset2;
|
||||
|
@ -832,7 +832,7 @@ static UvSculptData *uv_sculpt_stroke_init(bContext *C, wmOperator *op, const wm
|
|||
BLI_ghash_free(edgeHash, NULL, NULL);
|
||||
MEM_SAFE_FREE(edges);
|
||||
|
||||
/* transfer boundary edge property to UV's */
|
||||
/* transfer boundary edge property to UVs */
|
||||
for (int i = 0; i < data->totalUvEdges; i++) {
|
||||
if (!data->uvedges[i].is_interior) {
|
||||
data->uv[data->uvedges[i].uv1].is_boundary = true;
|
||||
|
|
|
@ -833,7 +833,7 @@ static void init_TransDataContainers(TransInfo *t,
|
|||
|
||||
if (object_mode & OB_MODE_EDIT) {
|
||||
tc->obedit = objects[i];
|
||||
/* Check needed for UV's */
|
||||
/* Check needed for UVs */
|
||||
if ((t->flag & T_2D_EDIT) == 0) {
|
||||
tc->use_local_mat = true;
|
||||
}
|
||||
|
|
|
@ -34,7 +34,7 @@ typedef struct UvNearestHit {
|
|||
*/
|
||||
float dist_sq;
|
||||
|
||||
/** Scale the UV's to account for aspect ratio from the image view. */
|
||||
/** Scale the UVs to account for aspect ratio from the image view. */
|
||||
float scale[2];
|
||||
} UvNearestHit;
|
||||
|
||||
|
|
|
@ -1333,7 +1333,7 @@ static void UV_OT_snap_selected(wmOperatorType *ot)
|
|||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Pin UV's Operator
|
||||
/** \name Pin UVs Operator
|
||||
* \{ */
|
||||
|
||||
static int uv_pin_exec(bContext *C, wmOperator *op)
|
||||
|
@ -2097,7 +2097,7 @@ void ED_operatormacros_uvedit(void)
|
|||
|
||||
ot = WM_operatortype_append_macro("UV_OT_rip_move",
|
||||
"UV Rip Move",
|
||||
"Unstitch UV's and move the result",
|
||||
"Unstitch UVs and move the result",
|
||||
OPTYPE_UNDO | OPTYPE_REGISTER);
|
||||
WM_operatortype_macro_define(ot, "UV_OT_rip");
|
||||
otmacro = WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate");
|
||||
|
|
|
@ -55,7 +55,7 @@ typedef struct ULData {
|
|||
/** When the specified UV edge is selected. */
|
||||
uint is_select_edge : 1;
|
||||
/**
|
||||
* When only this UV is selected and none of the other UV's
|
||||
* When only this UV is selected and none of the other UVs
|
||||
* around the connected fan are attached to an edge.
|
||||
*
|
||||
* In this case there is no need to detect contiguous loops,
|
||||
|
@ -106,7 +106,7 @@ static BMLoop *bm_loop_find_other_radial_loop_with_visible_face(BMLoop *l_src,
|
|||
do {
|
||||
if (BM_elem_flag_test(l_iter->f, BM_ELEM_TAG) && UL(l_iter)->is_select_edge &&
|
||||
BM_loop_uv_share_edge_check(l_src, l_iter, cd_loop_uv_offset)) {
|
||||
/* Check UV's are contiguous. */
|
||||
/* Check UVs are contiguous. */
|
||||
if (l_other == NULL) {
|
||||
l_other = l_iter;
|
||||
}
|
||||
|
@ -132,7 +132,7 @@ static BMLoop *bm_loop_find_other_fan_loop_with_visible_face(BMLoop *l_src,
|
|||
do {
|
||||
if (BM_elem_flag_test(l_iter->f, BM_ELEM_TAG) &&
|
||||
BM_loop_uv_share_edge_check(l_src, l_iter, cd_loop_uv_offset)) {
|
||||
/* Check UV's are contiguous. */
|
||||
/* Check UVs are contiguous. */
|
||||
if (l_other == NULL) {
|
||||
l_other = l_iter;
|
||||
}
|
||||
|
@ -162,7 +162,7 @@ static BMLoop *bm_loop_find_other_fan_loop_with_visible_face(BMLoop *l_src,
|
|||
}
|
||||
|
||||
/**
|
||||
* A version of #BM_vert_step_fan_loop that checks UV's.
|
||||
* A version of #BM_vert_step_fan_loop that checks UVs.
|
||||
*/
|
||||
static BMLoop *bm_vert_step_fan_loop_uv(BMLoop *l, BMEdge **e_step, const int cd_loop_uv_offset)
|
||||
{
|
||||
|
|
|
@ -754,7 +754,7 @@ static BMLoop *uvedit_loop_find_other_radial_loop_with_visible_face(const Scene
|
|||
do {
|
||||
if (uvedit_face_visible_test(scene, l_iter->f) &&
|
||||
BM_loop_uv_share_edge_check(l_src, l_iter, offsets.uv)) {
|
||||
/* Check UV's are contiguous. */
|
||||
/* Check UVs are contiguous. */
|
||||
if (l_other == NULL) {
|
||||
l_other = l_iter;
|
||||
}
|
||||
|
@ -1107,7 +1107,7 @@ bool ED_uvedit_nearest_uv_multi(const View2D *v2d,
|
|||
*
|
||||
* These functions are quite specialized, useful when sync select is enabled
|
||||
* and we want to pick an active UV vertex/edge from the active element which may
|
||||
* have multiple UV's split out.
|
||||
* have multiple UVs split out.
|
||||
* \{ */
|
||||
|
||||
BMLoop *uv_find_nearest_loop_from_vert(struct Scene *scene,
|
||||
|
@ -1830,7 +1830,7 @@ static void uv_select_linked_multi(Scene *scene,
|
|||
/* Special case, vertex/edge & sync select being enabled.
|
||||
*
|
||||
* Without this, a second linked select will 'grow' each time as each new
|
||||
* selection reaches the boundaries of islands that share vertices but not UV's.
|
||||
* selection reaches the boundaries of islands that share vertices but not UVs.
|
||||
*
|
||||
* Rules applied here:
|
||||
* - This loops face isn't selected.
|
||||
|
@ -3368,7 +3368,7 @@ static void uv_select_flush_from_tag_loop(const Scene *scene, Object *obedit, co
|
|||
|
||||
if ((ts->uv_flag & UV_SYNC_SELECTION) == 0 && ts->uv_sticky == SI_STICKY_VERTEX) {
|
||||
/* Tag all verts as untouched, then touch the ones that have a face center
|
||||
* in the loop and select all UV's that use a touched vert. */
|
||||
* in the loop and select all UVs that use a touched vert. */
|
||||
BM_mesh_elem_hflag_disable_all(em->bm, BM_VERT, BM_ELEM_TAG, false);
|
||||
|
||||
BM_ITER_MESH (efa, &iter, em->bm, BM_FACES_OF_MESH) {
|
||||
|
@ -4160,7 +4160,7 @@ void UV_OT_select_lasso(wmOperatorType *ot)
|
|||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Select Pinned UV's Operator
|
||||
/** \name Select Pinned UVs Operator
|
||||
* \{ */
|
||||
|
||||
static int uv_select_pinned_exec(bContext *C, wmOperator *op)
|
||||
|
|
|
@ -1911,8 +1911,8 @@ static StitchState *stitch_init(bContext *C,
|
|||
all_edges[counter].first = NULL;
|
||||
all_edges[counter].flag = 0;
|
||||
all_edges[counter].element = element;
|
||||
/* Using an order policy, sort UV's according to address space.
|
||||
* This avoids having two different UvEdges with the same UV's on different positions. */
|
||||
/* Using an order policy, sort UVs according to address space.
|
||||
* This avoids having two different UvEdges with the same UVs on different positions. */
|
||||
if (offset1 < offset2) {
|
||||
all_edges[counter].uv1 = offset1;
|
||||
all_edges[counter].uv2 = offset2;
|
||||
|
|
|
@ -116,7 +116,7 @@ static bool ED_uvedit_ensure_uvs(Object *obedit)
|
|||
BM_uv_map_ensure_edge_select_attr(em->bm, active_uv_name);
|
||||
const BMUVOffsets offsets = BM_uv_map_get_offsets(em->bm);
|
||||
|
||||
/* select new UV's (ignore UV_SYNC_SELECTION in this case) */
|
||||
/* select new UVs (ignore UV_SYNC_SELECTION in this case) */
|
||||
BM_ITER_MESH (efa, &iter, em->bm, BM_FACES_OF_MESH) {
|
||||
BMIter liter;
|
||||
BMLoop *l;
|
||||
|
@ -176,7 +176,7 @@ typedef struct UnwrapOptions {
|
|||
/** Only affect selected faces. */
|
||||
bool only_selected_faces;
|
||||
/**
|
||||
* Only affect selected UV's.
|
||||
* Only affect selected UVs.
|
||||
* \note Disable this for operations that don't run in the image-window.
|
||||
* Unwrapping from the 3D view for example, where only 'only_selected_faces' should be used.
|
||||
*/
|
||||
|
@ -1650,7 +1650,7 @@ static void uv_map_clip_correct_properties(wmOperatorType *ot)
|
|||
|
||||
/**
|
||||
* \param per_face_aspect: Calculate the aspect ratio per-face,
|
||||
* otherwise use a single aspect for all UV's based on the material of the active face.
|
||||
* otherwise use a single aspect for all UVs based on the material of the active face.
|
||||
* TODO: using per-face aspect may split UV islands so more advanced UV projection methods
|
||||
* such as "Unwrap" & "Smart UV Projections" will need to handle aspect correction themselves.
|
||||
* For now keep using a single aspect for all faces in this case.
|
||||
|
@ -2073,7 +2073,7 @@ void UV_OT_unwrap(wmOperatorType *ot)
|
|||
/** \name Smart UV Project Operator
|
||||
* \{ */
|
||||
|
||||
/* Ignore all areas below this, as the UV's get zeroed. */
|
||||
/* Ignore all areas below this, as the UVs get zeroed. */
|
||||
static const float smart_uv_project_area_ignore = 1e-12f;
|
||||
|
||||
typedef struct ThickFace {
|
||||
|
@ -2281,7 +2281,7 @@ static int smart_project_exec(bContext *C, wmOperator *op)
|
|||
while ((thick_faces_len > 0) &&
|
||||
!(thick_faces[thick_faces_len - 1].area > smart_uv_project_area_ignore)) {
|
||||
|
||||
/* Zero UV's so they don't overlap with other faces being unwrapped. */
|
||||
/* Zero UVs so they don't overlap with other faces being unwrapped. */
|
||||
BMIter liter;
|
||||
BMLoop *l;
|
||||
BM_ITER_ELEM (l, &liter, thick_faces[thick_faces_len - 1].efa, BM_LOOPS_OF_FACE) {
|
||||
|
|
|
@ -139,7 +139,7 @@ enum {
|
|||
* - Physics/collision detection.
|
||||
*
|
||||
* Storing loop indices (instead of vertex indices) allows us to
|
||||
* directly access UV's, vertex-colors as well as vertices.
|
||||
* directly access UVs, vertex-colors as well as vertices.
|
||||
* The index of the source polygon is stored as well,
|
||||
* giving access to materials and polygon normals.
|
||||
*
|
||||
|
@ -364,7 +364,7 @@ typedef struct GridPaintMask {
|
|||
* Original space within a face (similar to UV coordinates),
|
||||
* however they are used to determine the original position in a face.
|
||||
*
|
||||
* Unlike UV's these are not user editable and always start out using a fixed 0-1 range.
|
||||
* Unlike UVs these are not user editable and always start out using a fixed 0-1 range.
|
||||
* Currently only used for particle placement.
|
||||
*/
|
||||
#
|
||||
|
|
|
@ -2526,11 +2526,11 @@ enum {
|
|||
#define UVCALC_FILLHOLES (1 << 0)
|
||||
/** Would call this UVCALC_ASPECT_CORRECT, except it should be default with old file. */
|
||||
#define UVCALC_NO_ASPECT_CORRECT (1 << 1)
|
||||
/** Adjust UV's while transforming with Vert or Edge Slide. */
|
||||
/** Adjust UVs while transforming with Vert or Edge Slide. */
|
||||
#define UVCALC_TRANSFORM_CORRECT_SLIDE (1 << 2)
|
||||
/** Use mesh data after subsurf to compute UV's. */
|
||||
/** Use mesh data after subsurf to compute UVs. */
|
||||
#define UVCALC_USESUBSURF (1 << 3)
|
||||
/** Adjust UV's while transforming to avoid distortion */
|
||||
/** Adjust UVs while transforming to avoid distortion */
|
||||
#define UVCALC_TRANSFORM_CORRECT (1 << 4)
|
||||
/** Keep equal values merged while correcting custom-data. */
|
||||
#define UVCALC_TRANSFORM_CORRECT_KEEP_CONNECTED (1 << 5)
|
||||
|
|
|
@ -4902,13 +4902,13 @@ static void rna_def_modifier_screw(BlenderRNA *brna)
|
|||
prop = RNA_def_property(srna, "use_stretch_u", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", MOD_SCREW_UV_STRETCH_U);
|
||||
RNA_def_property_ui_text(
|
||||
prop, "Stretch U", "Stretch the U coordinates between 0 and 1 when UV's are present");
|
||||
prop, "Stretch U", "Stretch the U coordinates between 0 and 1 when UVs are present");
|
||||
RNA_def_property_update(prop, 0, "rna_Modifier_update");
|
||||
|
||||
prop = RNA_def_property(srna, "use_stretch_v", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", MOD_SCREW_UV_STRETCH_V);
|
||||
RNA_def_property_ui_text(
|
||||
prop, "Stretch V", "Stretch the V coordinates between 0 and 1 when UV's are present");
|
||||
prop, "Stretch V", "Stretch the V coordinates between 0 and 1 when UVs are present");
|
||||
RNA_def_property_update(prop, 0, "rna_Modifier_update");
|
||||
|
||||
# if 0
|
||||
|
|
|
@ -92,7 +92,7 @@ static const EnumPropertyItem uv_sculpt_relaxation_items[] = {
|
|||
"COTAN",
|
||||
0,
|
||||
"Geometry",
|
||||
"Use Geometry (cotangent) relaxation, making UV's follow the underlying 3D geometry"},
|
||||
"Use Geometry (cotangent) relaxation, making UVs follow the underlying 3D geometry"},
|
||||
{0, NULL, 0, NULL, NULL},
|
||||
};
|
||||
#endif
|
||||
|
@ -3277,7 +3277,7 @@ static void rna_def_tool_settings(BlenderRNA *brna)
|
|||
RNA_def_property_boolean_sdna(prop, NULL, "uvcalc_flag", UVCALC_TRANSFORM_CORRECT);
|
||||
RNA_def_property_ui_text(prop,
|
||||
"Correct Face Attributes",
|
||||
"Correct data such as UV's and color attributes when transforming");
|
||||
"Correct data such as UVs and color attributes when transforming");
|
||||
RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
|
||||
|
||||
prop = RNA_def_property(srna, "use_transform_correct_keep_connected", PROP_BOOLEAN, PROP_NONE);
|
||||
|
|
|
@ -81,7 +81,7 @@ static void requiredDataMask(ModifierData *md, CustomData_MeshMasks *r_cddata_ma
|
|||
if (pmd->canvas) {
|
||||
DynamicPaintSurface *surface = pmd->canvas->surfaces.first;
|
||||
for (; surface; surface = surface->next) {
|
||||
/* UV's: #CD_PROP_FLOAT2. */
|
||||
/* UVs: #CD_PROP_FLOAT2. */
|
||||
if (surface->format == MOD_DPAINT_SURFACE_F_IMAGESEQ ||
|
||||
surface->init_color_type == MOD_DPAINT_INITIAL_TEXTURE) {
|
||||
r_cddata_masks->lmask |= CD_MASK_PROP_FLOAT2;
|
||||
|
|
|
@ -420,7 +420,7 @@ void wm_event_do_depsgraph(bContext *C, bool is_after_open_file)
|
|||
if (wm->is_interface_locked) {
|
||||
return;
|
||||
}
|
||||
/* Combine data-masks so one window doesn't disable UV's in another T26448. */
|
||||
/* Combine data-masks so one window doesn't disable UVs in another T26448. */
|
||||
CustomData_MeshMasks win_combine_v3d_datamask = {0};
|
||||
LISTBASE_FOREACH (wmWindow *, win, &wm->windows) {
|
||||
const Scene *scene = WM_window_get_active_scene(win);
|
||||
|
|
Loading…
Reference in New Issue