21 double current_time_ = 0.0;
23 bool enabled_ =
false;
26 bool any_animated_ =
false;
46 state.clipping_plane_count);
50 any_animated_ =
false;
66 const float time = current_time_ - ob_ref.
object->
runtime->overlay_mode_transfer_start_time;
67 const float alpha = alpha_from_time_get(time);
72 ps_.push_constant(
"ucolor",
float4(flash_color_.xyz() * alpha, alpha));
76 if (use_sculpt_pbvh) {
80 ps_.draw(
batch.batch, handle);
109 static constexpr float flash_length = 0.55f;
110 static constexpr float flash_alpha = 0.25f;
112 static float alpha_from_time_get(
const float anim_time)
114 if (anim_time > flash_length) {
117 if (anim_time < 0.0f) {
120 return (1.0f - (anim_time / flash_length)) * flash_alpha;
bool BKE_sculptsession_use_pbvh_draw(const Object *ob, const RegionView3D *rv3d)
MINLINE void srgb_to_linearrgb_v4(float linear[4], const float srgb[4])
double BLI_time_now_seconds(void)
void GPU_framebuffer_bind(GPUFrameBuffer *framebuffer)
void UI_GetThemeColor3fv(int colorid, float col[3])
ResourceHandle unique_handle(const ObjectRef &ref)
ResourceHandle resource_handle_for_sculpt(const ObjectRef &ref)
void submit(PassSimple &pass, View &view)
void object_sync(Manager &manager, const ObjectRef &ob_ref, const State &state)
void draw(Framebuffer &framebuffer, Manager &manager, View &view)
void begin_sync(Resources &res, const State &state)
blender::gpu::Batch * DRW_cache_object_surface_get(Object *ob)
bool DRW_object_is_renderable(const Object *ob)
bool DRW_state_is_image_render()
void DRW_viewport_request_redraw()
@ DRW_STATE_DEPTH_LESS_EQUAL
struct @157336070235062372277311340362362342103123126032::@262166344314164341202215145112231240022370055142 batch
detail::Pass< command::DrawCommandBuf > PassSimple
Vector< SculptBatch > sculpt_batches_get(const Object *ob, SculptBatchFeature features)
VecBase< float, 4 > float4
ObjectRuntimeHandle * runtime
GPUUniformBuf * globals_buf
const SelectionType selection_type