Blender V5.3
blender::PixelBitmapDrawer Class Reference

#include <BIF_glutil.hh>

Public Member Functions

 PixelBitmapDrawer (GPUBuiltinShader builtin_shader)
 PixelBitmapDrawer ()
gpu::Shader * shader_get ()
void draw (float x, float y, int img_w, int img_h, gpu::TextureFormat gpu_format, bool use_filter, const void *rect, float scale_x, float scale_y, const float color[4])

Detailed Description

Utility to render a quad using pixel bitmap data in system memory.

Definition at line 30 of file BIF_glutil.hh.

Constructor & Destructor Documentation

◆ PixelBitmapDrawer() [1/2]

blender::PixelBitmapDrawer::PixelBitmapDrawer ( GPUBuiltinShader builtin_shader)

Prepares for drawing, using one of built-in shaders (e.g. GPU_SHADER_3D_IMAGE_COLOR).

Before drawing additional uniforms can be set on the shader.

Definition at line 36 of file glutil.cc.

References blender::GPU_shader_get_builtin_shader(), and blender::immBindBuiltinProgram().

◆ PixelBitmapDrawer() [2/2]

blender::PixelBitmapDrawer::PixelBitmapDrawer ( )

Prepares for drawing, with shader set up by the caller. The shader is expected to use pos and texCoord attributes, and image texture.

Definition at line 31 of file glutil.cc.

References blender::nullptr.

Member Function Documentation

◆ draw()

◆ shader_get()

gpu::Shader * blender::PixelBitmapDrawer::shader_get ( )
inline

Definition at line 51 of file BIF_glutil.hh.

Referenced by blender::draw_filled_lasso(), and blender::ED_mask_draw_region().


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