Blender V5.3
blender::bke::pbvh::uv_islands::UVIslandsMask Struct Reference

#include <pbvh_uv_islands.hh>

Classes

struct  Tile

Public Member Functions

UVIslandsMask
void add_tile (float2 udim_offset, ushort2 resolution)
const Tile * find_tile (float2 uv) const
bool is_masked (uint16_t island_index, float2 uv) const
void add (const MeshData &mesh_data, GroupedSpan< int > tris_by_island)
void dilate (int max_iterations)

Public Attributes

Vector< Tile > tiles

Detailed Description

Mask to find the index of the UVIsland for a given UV coordinate.

Definition at line 263 of file pbvh_uv_islands.hh.

Member Function Documentation

◆ add()

void blender::bke::pbvh::uv_islands::UVIslandsMask::add ( const MeshData & mesh_data,
GroupedSpan< int > tris_by_island )

Rasterize the UV islands into the mask, using the per-island triangle grouping. Tiles should be added beforehand using the 'add_tile' method.

Definition at line 1538 of file pbvh_uv_islands.cc.

References blender::Editor, blender::IndexRange::IndexRange(), blender::threading::parallel_for(), PRF_scope, and tiles.

Referenced by blender::bke::pbvh::pixels::update_pixels().

◆ add_tile()

void blender::bke::pbvh::uv_islands::UVIslandsMask::add_tile ( float2 udim_offset,
ushort2 resolution )

Definition at line 1551 of file pbvh_uv_islands.cc.

References Tile::Tile(), and tiles.

Referenced by blender::bke::pbvh::pixels::update_pixels().

◆ dilate()

void blender::bke::pbvh::uv_islands::UVIslandsMask::dilate ( int max_iterations)

◆ find_tile()

const UVIslandsMask::Tile * blender::bke::pbvh::uv_islands::UVIslandsMask::find_tile ( float2 uv) const

Find a tile containing the given uv coordinate.

Definition at line 1660 of file pbvh_uv_islands.cc.

References tile, and tiles.

Referenced by blender::bke::pbvh::pixels::do_encode_pixels(), and is_masked().

◆ is_masked()

bool blender::bke::pbvh::uv_islands::UVIslandsMask::is_masked ( uint16_t island_index,
float2 uv ) const

Is the given uv coordinate part of the given island_index mask.

true - part of the island mask. false - not part of the island mask.

Definition at line 1670 of file pbvh_uv_islands.cc.

References find_tile(), and tile.

Member Data Documentation

◆ tiles

Vector<Tile> blender::bke::pbvh::uv_islands::UVIslandsMask::tiles

Definition at line 285 of file pbvh_uv_islands.hh.

Referenced by add(), add_tile(), dilate(), and find_tile().


The documentation for this struct was generated from the following files: