![]() |
libgpac
Documentation of the core library of GPAC
|
#include <gpac/internal/mesh.h>#include <gpac/nodes_mpeg4.h>#include <gpac/nodes_x3d.h>#include <gpac/color.h>#include "gl_inc.h"
Include dependency graph for mesh.c:Data Structures | |
| struct | face_info |
| struct | pt_info |
| struct | SCP |
| struct | SCPInfo |
Macros | |
| #define | HIGH_SPEED_RATIO 2 |
| #define | MESH_CHECK_VERTEX(m) |
| #define | MESH_CHECK_IDX(m) |
| #define | CYLINDER_SUBDIV 24 |
| #define | CONE_SUBDIV 24 |
| #define | ELLIPSE_SUBDIV 32 |
| #define | COL_TO_RGBA(res, col) { res.red = col.red; res.green = col.green; res.blue = col.blue; res.alpha = FIX_ONE; } |
| #define | MESH_GET_COL(thecol, index) |
| #define | GET_IDX(idx, array) |
| #define | REGISTER_POINT_FACE(FACE_IDX) |
| #define | NEAR_ZERO(__x) (ABS(__x)<=FIX_EPSILON) |
Functions | |
| void | compositor_get_srdmap_size (const GF_PropertyValue *srd_map, u32 *width, u32 *height, u32 *min_x, u32 *min_y) |
| static void | del_aabb_node (AABBNode *node) |
| void | mesh_reset (GF_Mesh *mesh) |
| void | mesh_free (GF_Mesh *mesh) |
| GF_Mesh * | new_mesh () |
| static void | mesh_fit_alloc (GF_Mesh *m) |
| void | mesh_update_bounds (GF_Mesh *mesh) |
| void | mesh_clone (GF_Mesh *dest, GF_Mesh *orig) |
| static GFINLINE GF_Vertex | set_vertex (Fixed x, Fixed y, Fixed z, Fixed nx, Fixed ny, Fixed nz, Fixed u, Fixed v) |
| void | mesh_set_vertex (GF_Mesh *mesh, Fixed x, Fixed y, Fixed z, Fixed nx, Fixed ny, Fixed nz, Fixed u, Fixed v) |
| void | mesh_set_vertex_v (GF_Mesh *mesh, SFVec3f pt, SFVec3f nor, SFVec2f tx, SFColorRGBA col) |
| void | mesh_set_vertex_vx (GF_Mesh *mesh, GF_Vertex *vx) |
| void | mesh_set_point (GF_Mesh *mesh, Fixed x, Fixed y, Fixed z, SFColorRGBA col) |
| void | mesh_set_index (GF_Mesh *mesh, u32 idx) |
| void | mesh_set_triangle (GF_Mesh *mesh, u32 v1_idx, u32 v2_idx, u32 v3_idx) |
| void | mesh_set_line (GF_Mesh *mesh, u32 v1_idx, u32 v2_idx) |
| void | mesh_recompute_normals (GF_Mesh *mesh) |
| void | mesh_generate_tex_coords (GF_Mesh *mesh, GF_Node *__texCoords) |
| void | mesh_new_box (GF_Mesh *mesh, SFVec3f size) |
| void | mesh_new_unit_bbox (GF_Mesh *mesh) |
| static void | compute_cylinder (Fixed height, Fixed radius, s32 numFacets, SFVec3f *coords, SFVec2f *texcoords) |
| void | mesh_new_cylinder (GF_Mesh *mesh, Fixed height, Fixed radius, Bool bottom, Bool side, Bool top, Bool low_res) |
| void | mesh_new_cone (GF_Mesh *mesh, Fixed height, Fixed radius, Bool bottom, Bool side, Bool low_res) |
| void | compute_sphere (Fixed radius, SFVec3f *coords, SFVec2f *texcoords, u32 num_steps, GF_MeshSphereAngles *sphere_angles) |
| void | mesh_new_sphere (GF_Mesh *mesh, Fixed radius, Bool low_res, GF_MeshSphereAngles *sphere_angles) |
| void | mesh_new_spherical_srd (GF_Mesh *mesh, Fixed radius, const GF_PropertyValue *srd_map, const GF_PropertyValue *srd_ref) |
| void | mesh_new_rectangle_ex (GF_Mesh *mesh, SFVec2f size, SFVec2f *orig, u32 flip, u32 rotate) |
| void | mesh_new_rectangle (GF_Mesh *mesh, SFVec2f size, SFVec2f *orig, Bool flip) |
| void | mesh_new_planar_srd (GF_Mesh *mesh, SFVec2f size, u32 flip, u32 rotate, const GF_PropertyValue *srd_map, const GF_PropertyValue *srd_ref) |
| void | mesh_new_ellipse (GF_Mesh *mesh, Fixed a_dia, Fixed b_dia, Bool low_res) |
| void | mesh_from_path_intern (GF_Mesh *mesh, GF_Path *path, Bool make_ccw) |
| void | mesh_from_path (GF_Mesh *mesh, GF_Path *path) |
| void | mesh_get_outline (GF_Mesh *mesh, GF_Path *path) |
| void | mesh_new_ils (GF_Mesh *mesh, GF_Node *__coord, MFInt32 *coordIndex, GF_Node *__color, MFInt32 *colorIndex, Bool colorPerVertex, Bool do_close) |
| void | mesh_new_ps (GF_Mesh *mesh, GF_Node *__coord, GF_Node *__color) |
| void | register_point_in_face (struct face_info *fi, u32 pt_index) |
| void | register_face_in_point (struct pt_info *pi, u32 face_index) |
| static GFINLINE SFVec3f | smooth_face_normals (struct pt_info *pts, u32 nb_pts, struct face_info *faces, u32 nb_faces, u32 pt_idx_in_face, u32 face_idx, Fixed creaseAngleCos) |
| void | mesh_new_ifs_intern (GF_Mesh *mesh, GF_Node *__coord, MFInt32 *coordIndex, GF_Node *__color, MFInt32 *colorIndex, Bool colorPerVertex, GF_Node *__normal, MFInt32 *normalIndex, Bool normalPerVertex, GF_Node *__texCoords, MFInt32 *texCoordIndex, Fixed creaseAngle) |
| void | mesh_new_ifs2d (GF_Mesh *mesh, GF_Node *node) |
| void | mesh_new_ifs (GF_Mesh *mesh, GF_Node *node) |
| void | mesh_new_elevation_grid (GF_Mesh *mesh, GF_Node *node) |
| static void | mesh_extrude_path_intern (GF_Mesh *mesh, GF_Path *path, MFVec3f *thespine, Fixed creaseAngle, Fixed min_cx, Fixed min_cy, Fixed width_cx, Fixed width_cy, Bool begin_cap, Bool end_cap, MFRotation *spine_ori, MFVec2f *spine_scale, Bool tx_along_spine) |
| void | mesh_extrude_path_ext (GF_Mesh *mesh, GF_Path *path, MFVec3f *thespine, Fixed creaseAngle, Fixed min_cx, Fixed min_cy, Fixed width_cx, Fixed width_cy, Bool begin_cap, Bool end_cap, MFRotation *spine_ori, MFVec2f *spine_scale, Bool tx_along_spine) |
| void | mesh_extrude_path (GF_Mesh *mesh, GF_Path *path, MFVec3f *thespine, Fixed creaseAngle, Bool begin_cap, Bool end_cap, MFRotation *spine_ori, MFVec2f *spine_scale, Bool tx_along_spine) |
| void | mesh_new_extrusion (GF_Mesh *mesh, GF_Node *node) |
| #define HIGH_SPEED_RATIO 2 |
| #define MESH_CHECK_VERTEX | ( | m | ) |
| #define MESH_CHECK_IDX | ( | m | ) |
| #define CYLINDER_SUBDIV 24 |
| #define CONE_SUBDIV 24 |
| #define ELLIPSE_SUBDIV 32 |
| #define COL_TO_RGBA | ( | res, | |
| col | |||
| ) | { res.red = col.red; res.green = col.green; res.blue = col.blue; res.alpha = FIX_ONE; } |
| #define MESH_GET_COL | ( | thecol, | |
| index | |||
| ) |
| #define GET_IDX | ( | idx, | |
| array | |||
| ) |
| #define REGISTER_POINT_FACE | ( | FACE_IDX | ) |
| #define NEAR_ZERO | ( | __x | ) | (ABS(__x)<=FIX_EPSILON) |
| void compositor_get_srdmap_size | ( | const GF_PropertyValue * | srd_map, |
| u32 * | width, | ||
| u32 * | height, | ||
| u32 * | min_x, | ||
| u32 * | min_y | ||
| ) |
Here is the caller graph for this function:
|
static |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_reset | ( | GF_Mesh * | mesh | ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_free | ( | GF_Mesh * | mesh | ) |
Here is the call graph for this function:
Here is the caller graph for this function:| GF_Mesh * new_mesh | ( | ) |
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_update_bounds | ( | GF_Mesh * | mesh | ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_set_vertex | ( | GF_Mesh * | mesh, |
| Fixed | x, | ||
| Fixed | y, | ||
| Fixed | z, | ||
| Fixed | nx, | ||
| Fixed | ny, | ||
| Fixed | nz, | ||
| Fixed | u, | ||
| Fixed | v | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_set_vertex_v | ( | GF_Mesh * | mesh, |
| SFVec3f | pt, | ||
| SFVec3f | nor, | ||
| SFVec2f | tx, | ||
| SFColorRGBA | col | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the caller graph for this function:| void mesh_set_point | ( | GF_Mesh * | mesh, |
| Fixed | x, | ||
| Fixed | y, | ||
| Fixed | z, | ||
| SFColorRGBA | col | ||
| ) |
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_recompute_normals | ( | GF_Mesh * | mesh | ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_unit_bbox | ( | GF_Mesh * | mesh | ) |
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Here is the caller graph for this function:| void mesh_new_cylinder | ( | GF_Mesh * | mesh, |
| Fixed | height, | ||
| Fixed | radius, | ||
| Bool | bottom, | ||
| Bool | side, | ||
| Bool | top, | ||
| Bool | low_res | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_cone | ( | GF_Mesh * | mesh, |
| Fixed | height, | ||
| Fixed | radius, | ||
| Bool | bottom, | ||
| Bool | side, | ||
| Bool | low_res | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void compute_sphere | ( | Fixed | radius, |
| SFVec3f * | coords, | ||
| SFVec2f * | texcoords, | ||
| u32 | num_steps, | ||
| GF_MeshSphereAngles * | sphere_angles | ||
| ) |
Here is the caller graph for this function:| void mesh_new_sphere | ( | GF_Mesh * | mesh, |
| Fixed | radius, | ||
| Bool | low_res, | ||
| GF_MeshSphereAngles * | sphere_angles | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_spherical_srd | ( | GF_Mesh * | mesh, |
| Fixed | radius, | ||
| const GF_PropertyValue * | srd_map, | ||
| const GF_PropertyValue * | srd_ref | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_planar_srd | ( | GF_Mesh * | mesh, |
| SFVec2f | size, | ||
| u32 | flip, | ||
| u32 | rotate, | ||
| const GF_PropertyValue * | srd_map, | ||
| const GF_PropertyValue * | srd_ref | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_ils | ( | GF_Mesh * | mesh, |
| GF_Node * | __coord, | ||
| MFInt32 * | coordIndex, | ||
| GF_Node * | __color, | ||
| MFInt32 * | colorIndex, | ||
| Bool | colorPerVertex, | ||
| Bool | do_close | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_new_ifs_intern | ( | GF_Mesh * | mesh, |
| GF_Node * | __coord, | ||
| MFInt32 * | coordIndex, | ||
| GF_Node * | __color, | ||
| MFInt32 * | colorIndex, | ||
| Bool | colorPerVertex, | ||
| GF_Node * | __normal, | ||
| MFInt32 * | normalIndex, | ||
| Bool | normalPerVertex, | ||
| GF_Node * | __texCoords, | ||
| MFInt32 * | texCoordIndex, | ||
| Fixed | creaseAngle | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_extrude_path_ext | ( | GF_Mesh * | mesh, |
| GF_Path * | path, | ||
| MFVec3f * | thespine, | ||
| Fixed | creaseAngle, | ||
| Fixed | min_cx, | ||
| Fixed | min_cy, | ||
| Fixed | width_cx, | ||
| Fixed | width_cy, | ||
| Bool | begin_cap, | ||
| Bool | end_cap, | ||
| MFRotation * | spine_ori, | ||
| MFVec2f * | spine_scale, | ||
| Bool | tx_along_spine | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void mesh_extrude_path | ( | GF_Mesh * | mesh, |
| GF_Path * | path, | ||
| MFVec3f * | thespine, | ||
| Fixed | creaseAngle, | ||
| Bool | begin_cap, | ||
| Bool | end_cap, | ||
| MFRotation * | spine_ori, | ||
| MFVec2f * | spine_scale, | ||
| Bool | tx_along_spine | ||
| ) |
Here is the call graph for this function:
Here is the caller graph for this function: