use objc2::{extern_protocol, rc::Retained, runtime::ProtocolObject};
use crate::{
MTLCommandEncoder,
render_command_encoder::MTLRenderCommandEncoder,
render_pass::{MTLStoreAction, MTLStoreActionOptions},
};
extern_protocol!(
pub unsafe trait MTLParallelRenderCommandEncoder: MTLCommandEncoder {
#[unsafe(method(renderCommandEncoder))]
#[unsafe(method_family = none)]
fn render_command_encoder(&self) -> Option<Retained<ProtocolObject<dyn MTLRenderCommandEncoder>>>;
#[unsafe(method(setColorStoreAction:atIndex:))]
#[unsafe(method_family = none)]
fn set_color_store_action_at_index(
&self,
store_action: MTLStoreAction,
color_attachment_index: usize,
);
#[unsafe(method(setDepthStoreAction:))]
#[unsafe(method_family = none)]
fn set_depth_store_action(
&self,
store_action: MTLStoreAction,
);
#[unsafe(method(setStencilStoreAction:))]
#[unsafe(method_family = none)]
fn set_stencil_store_action(
&self,
store_action: MTLStoreAction,
);
#[unsafe(method(setColorStoreActionOptions:atIndex:))]
#[unsafe(method_family = none)]
fn set_color_store_action_options_at_index(
&self,
store_action_options: MTLStoreActionOptions,
color_attachment_index: usize,
);
#[unsafe(method(setDepthStoreActionOptions:))]
#[unsafe(method_family = none)]
fn set_depth_store_action_options(
&self,
store_action_options: MTLStoreActionOptions,
);
#[unsafe(method(setStencilStoreActionOptions:))]
#[unsafe(method_family = none)]
fn set_stencil_store_action_options(
&self,
store_action_options: MTLStoreActionOptions,
);
}
);