1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
use crate::prelude::*;
use crate::{scalar, PathEffect};
use skia_bindings as sb;
use skia_bindings::SkPathEffect;

impl RCHandle<SkPathEffect> {
    pub fn corner_path(radius: scalar) -> Option<Self> {
        new(radius)
    }
}

pub fn new(radius: scalar) -> Option<PathEffect> {
    PathEffect::from_ptr(unsafe { sb::C_SkCornerPathEffect_Make(radius) })
}