MCPcopy Create free account
hub / github.com/MeshInspector/MeshLib / getUV

Function getUV

source/MRMesh/MRTextureColors.cpp:14–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12{
13
14static UVCoord getUV( VertId v, const ThreeVertIds& tri, const ThreeUVCoords& uvs )
15{
16 for ( int i = 0; i < 3; ++i )
17 {
18 if ( tri[i] != v )
19 continue;
20 return uvs[i];
21 }
22 assert( false ); // no such vertex in the triangle
23 return {};
24}
25
26std::optional<UVCoord> findVertexUV( const MeshTopology& topology, VertId v, const TriCornerUVCoords& triCornerUvCoords )
27{

Callers 2

findVertexUVFunction · 0.85
sampleVertexColorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected