Extract pad destination texture dispatch helper
This commit is contained in:
@@ -847,17 +847,16 @@ void Canvas::stroke_draw()
|
||||
},
|
||||
};
|
||||
const auto make_pad_destination_texture_dispatch = [&](int face_index) {
|
||||
return pp::panopainter::LegacyCanvasStrokeTextureInputDispatch {
|
||||
.activate_texture_unit = [&](int texture_slot) {
|
||||
return pp::panopainter::make_legacy_canvas_stroke_pad_destination_texture_dispatch(
|
||||
[&](int texture_slot) {
|
||||
set_active_texture_unit(texture_slot);
|
||||
},
|
||||
.bind_stroke_destination = [&] {
|
||||
[&] {
|
||||
m_tex[face_index].bind();
|
||||
},
|
||||
.unbind_stroke_destination = [&] {
|
||||
[&] {
|
||||
m_tex[face_index].unbind();
|
||||
},
|
||||
};
|
||||
});
|
||||
};
|
||||
[[maybe_unused]] const auto pad_result = pp::panopainter::execute_legacy_canvas_stroke_pad_faces(
|
||||
pp::panopainter::LegacyCanvasStrokePadExecutionRequest {
|
||||
|
||||
Reference in New Issue
Block a user