mirror of
https://github.com/penpot/penpot.git
synced 2025-05-17 17:26:11 +02:00
🐛 Fix blend mode against background
This commit is contained in:
parent
579a5729e6
commit
21da6ddd4a
5 changed files with 34 additions and 2 deletions
|
@ -49,6 +49,14 @@ pub extern "C" fn set_render_options(debug: u32, dpr: f32) {
|
|||
render_state.set_dpr(dpr);
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn set_canvas_background(raw_color: u32) {
|
||||
let state = unsafe { STATE.as_mut() }.expect("got an invalid state pointer");
|
||||
|
||||
let color = skia::Color::new(raw_color);
|
||||
state.set_background_color(color);
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn render() {
|
||||
let state = unsafe { STATE.as_mut() }.expect("got an invalid state pointer");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue