Blender  V3.3
GEO_uv_parametrizer.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 
3 #pragma once
4 
5 #include "BLI_sys_types.h" /* for intptr_t support */
6 
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
14 
15 typedef struct ParamHandle ParamHandle; /* Handle to an array of charts. */
16 typedef intptr_t ParamKey; /* Key (hash) for identifying verts and faces. */
17 #define PARAM_KEY_MAX INTPTR_MAX
18 
19 /* -------------------------------------------------------------------- */
35 
36 void GEO_uv_parametrizer_aspect_ratio(ParamHandle *handle, float aspx, float aspy);
37 
38 void GEO_uv_prepare_pin_index(ParamHandle *handle, const int bmvertindex, const float uv[2]);
39 
40 ParamKey GEO_uv_find_pin_index(ParamHandle *handle, const int bmvertindex, const float uv[2]);
41 
43  const ParamKey key,
44  const int nverts,
45  const ParamKey *vkeys,
46  const float **co,
47  float **uv, /* Output will eventually be written to `uv`. */
48  const bool *pin,
49  const bool *select);
50 
52 
54  bool fill,
55  bool topology_from_uvs,
56  int *count_fail);
58 
61 /* -------------------------------------------------------------------- */
74 void GEO_uv_parametrizer_lscm_begin(ParamHandle *handle, bool live, bool abf);
75 void GEO_uv_parametrizer_lscm_solve(ParamHandle *handle, int *count_changed, int *count_failed);
77 
80 /* -------------------------------------------------------------------- */
88 
91 /* -------------------------------------------------------------------- */
96  float margin,
97  bool do_rotate,
98  bool ignore_pinned);
99 
102 /* -------------------------------------------------------------------- */
107  bool ignore_pinned,
108  bool scale_uv,
109  bool shear);
110 
113 /* -------------------------------------------------------------------- */
117 void GEO_uv_parametrizer_scale(ParamHandle *handle, float x, float y);
118 
121 /* -------------------------------------------------------------------- */
127 
130 #ifdef __cplusplus
131 }
132 #endif
void GEO_uv_parametrizer_flush(ParamHandle *handle)
void GEO_uv_parametrizer_stretch_iter(ParamHandle *handle)
void GEO_uv_parametrizer_scale(ParamHandle *handle, float x, float y)
ParamHandle * GEO_uv_parametrizer_construct_begin(void)
void GEO_uv_prepare_pin_index(ParamHandle *handle, const int bmvertindex, const float uv[2])
void GEO_uv_parametrizer_lscm_end(ParamHandle *handle)
void GEO_uv_parametrizer_stretch_begin(ParamHandle *handle)
void GEO_uv_parametrizer_face_add(ParamHandle *handle, const ParamKey key, const int nverts, const ParamKey *vkeys, const float **co, float **uv, const bool *pin, const bool *select)
void GEO_uv_parametrizer_average(ParamHandle *handle, bool ignore_pinned, bool scale_uv, bool shear)
void GEO_uv_parametrizer_pack(ParamHandle *handle, float margin, bool do_rotate, bool ignore_pinned)
void GEO_uv_parametrizer_flush_restore(ParamHandle *handle)
void GEO_uv_parametrizer_construct_end(ParamHandle *handle, bool fill, bool topology_from_uvs, int *count_fail)
void GEO_uv_parametrizer_lscm_solve(ParamHandle *handle, int *count_changed, int *count_failed)
void GEO_uv_parametrizer_delete(ParamHandle *handle)
void GEO_uv_parametrizer_edge_set_seam(ParamHandle *handle, ParamKey *vkeys)
void GEO_uv_parametrizer_stretch_end(ParamHandle *handle)
ParamKey GEO_uv_find_pin_index(ParamHandle *handle, const int bmvertindex, const float uv[2])
intptr_t ParamKey
void GEO_uv_parametrizer_aspect_ratio(ParamHandle *handle, float aspx, float aspy)
void GEO_uv_parametrizer_lscm_begin(ParamHandle *handle, bool live, bool abf)
void GEO_uv_parametrizer_stretch_blend(ParamHandle *handle, float blend)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint y
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
Definition: avxb.h:154
_W64 int intptr_t
Definition: stdint.h:118
static int blend(const Tex *tex, const float texvec[3], TexResult *texres)