Blender V5.0
blender::image_engine::TextureInfo Struct Reference

#include <image_texture_info.hh>

Inherits blender::NonCopyable.

Public Member Functions

 TextureInfo ()=default
 TextureInfo (TextureInfo &&other)=default
 ~TextureInfo ()
int2 offset () const
 return the offset of the texture with the area.
void ensure_gpu_texture (int2 texture_size)
Public Member Functions inherited from blender::NonCopyable
 NonCopyable (const NonCopyable &other)=delete
NonCopyableoperator= (const NonCopyable &other)=delete
 NonCopyable ()=default
 NonCopyable (NonCopyable &&other)=default
NonCopyableoperator= (NonCopyable &&other)=default

Public Attributes

bool need_full_update: 1
 does this texture need a full update.
rcti clipping_bounds
 area of the texture in screen space.
rctf clipping_uv_bounds
 uv area of the texture in screen space.
int2 tile_id
gpu::Batch * batch = nullptr
 Batch to draw the associated text on the screen.
Texture texture = {"Image.Tile"}
 GPU Texture for a partial region of the image editor.
int2 last_texture_size = int2(0)

Detailed Description

Definition at line 23 of file image_texture_info.hh.

Constructor & Destructor Documentation

◆ TextureInfo() [1/2]

blender::image_engine::TextureInfo::TextureInfo ( )
default

Referenced by TextureInfo().

◆ TextureInfo() [2/2]

blender::image_engine::TextureInfo::TextureInfo ( TextureInfo && other)
default

References TextureInfo().

◆ ~TextureInfo()

blender::image_engine::TextureInfo::~TextureInfo ( )
inline

Definition at line 59 of file image_texture_info.hh.

References batch, and GPU_batch_discard().

Member Function Documentation

◆ ensure_gpu_texture()

◆ offset()

int2 blender::image_engine::TextureInfo::offset ( ) const
inline

return the offset of the texture with the area.

A texture covers only a part of the area. The offset if the offset in screen coordinates between the area and the part that the texture covers.

Definition at line 73 of file image_texture_info.hh.

References clipping_bounds.

Member Data Documentation

◆ batch

gpu::Batch* blender::image_engine::TextureInfo::batch = nullptr

Batch to draw the associated text on the screen.

Contains a VBO with pos and uv. pos (2xI32) is relative to the origin of the space. uv (2xF32) reflect the uv bounds.

Definition at line 47 of file image_texture_info.hh.

Referenced by ~TextureInfo().

◆ clipping_bounds

rcti blender::image_engine::TextureInfo::clipping_bounds

◆ clipping_uv_bounds

rctf blender::image_engine::TextureInfo::clipping_uv_bounds

uv area of the texture in screen space.

Definition at line 34 of file image_texture_info.hh.

Referenced by blender::image_engine::OneTexture::update_bounds().

◆ last_texture_size

int2 blender::image_engine::TextureInfo::last_texture_size = int2(0)

Definition at line 54 of file image_texture_info.hh.

Referenced by ensure_gpu_texture().

◆ need_full_update

bool blender::image_engine::TextureInfo::need_full_update

does this texture need a full update.

When set to false the texture can be updated using a partial update.

Definition at line 29 of file image_texture_info.hh.

Referenced by ensure_gpu_texture(), and blender::image_engine::OneTexture::update_bounds().

◆ texture

Texture blender::image_engine::TextureInfo::texture = {"Image.Tile"}

GPU Texture for a partial region of the image editor.

Definition at line 52 of file image_texture_info.hh.

Referenced by ensure_gpu_texture().

◆ tile_id

int2 blender::image_engine::TextureInfo::tile_id

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