1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
use crate::import_objc_macros::*;
use crate::{handle, DeviceCreated, Object, ObjectPointer};

pub struct MTLComputePipelineState(ObjectPointer);
handle!(MTLComputePipelineState);

impl DeviceCreated for MTLComputePipelineState {}

impl Object for MTLComputePipelineState {
    unsafe fn from_ptr(ptr: ObjectPointer) -> Self
    where
        Self: Sized,
    {
        MTLComputePipelineState(ptr)
    }

    fn get_ptr(&self) -> ObjectPointer {
        self.0
    }
}