Blender V5.0
blender::ed::sculpt_paint::greasepencil::ColorGrid Struct Reference

Public Member Functions

float2 pos_to_coords (const int2 pos, const float2 center) const
int2 coords_to_pos (const float2 coord, const float2 center) const
int pos_to_index (const int2 pos) const

Public Attributes

Array< float4colors
int size
int cell_size_px
float2 center

Detailed Description

Definition at line 19 of file grease_pencil_vertex_smear.cc.

Member Function Documentation

◆ coords_to_pos()

int2 blender::ed::sculpt_paint::greasepencil::ColorGrid::coords_to_pos ( const float2 coord,
const float2 center ) const
inline

Definition at line 37 of file grease_pencil_vertex_smear.cc.

References center, blender::math::floor(), and pos.

◆ pos_to_coords()

float2 blender::ed::sculpt_paint::greasepencil::ColorGrid::pos_to_coords ( const int2 pos,
const float2 center ) const
inline

Definition at line 30 of file grease_pencil_vertex_smear.cc.

References center, and pos.

◆ pos_to_index()

int blender::ed::sculpt_paint::greasepencil::ColorGrid::pos_to_index ( const int2 pos) const
inline

Definition at line 45 of file grease_pencil_vertex_smear.cc.

References pos.

Member Data Documentation

◆ cell_size_px

int blender::ed::sculpt_paint::greasepencil::ColorGrid::cell_size_px

Definition at line 25 of file grease_pencil_vertex_smear.cc.

◆ center

float2 blender::ed::sculpt_paint::greasepencil::ColorGrid::center

Definition at line 27 of file grease_pencil_vertex_smear.cc.

Referenced by coords_to_pos(), and pos_to_coords().

◆ colors

Array<float4> blender::ed::sculpt_paint::greasepencil::ColorGrid::colors

Definition at line 21 of file grease_pencil_vertex_smear.cc.

◆ size

int blender::ed::sculpt_paint::greasepencil::ColorGrid::size

Definition at line 23 of file grease_pencil_vertex_smear.cc.


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