rt draws: the render encoder's error links by the imported paths, and the stencil test's state no longer shadows its maker

The private-docs lint refused eight explicit link targets that the imports now resolve, and the
m2v_gpu build refused the stencil test calling state() after a local binding of that name.
Lint 44799 at 54bb771de4 failed on these alone; rebased onto b1eeec6981 (step 2 as landed).
This commit is contained in:
Anees Iqbal committed 2026-11-18 03:13:47 -08:00
1 parent b29fcccdc9
commit 69f8f3bb7c
2 files changed
+10 -10

No files matched your search

+8 -8
View File
@@ -228,14 +228,14 @@ impl CommandBuffer {
/// `vkCmdBeginRendering` between the pass's first barrier and its commands. The command
/// buffer keeps each attachment's texture until it retires.
///
/// Err: [`Refusal::Committed`](crate::Refusal::Committed);
/// [`Refusal::EncoderOpen`](crate::Refusal::EncoderOpen) while another encoder of the command
/// buffer is open; [`Refusal::OtherDevice`](crate::Refusal::OtherDevice) for another device's
/// texture; [`Refusal::AttachmentUsage`](crate::Refusal::AttachmentUsage);
/// [`Refusal::AttachmentPlace`](crate::Refusal::AttachmentPlace);
/// [`Refusal::AttachmentFormat`](crate::Refusal::AttachmentFormat);
/// [`Gap::RenderPass`](crate::Gap::RenderPass);
/// [`Limit::ColorAttachments`](crate::Limit::ColorAttachments); [`Error::Vulkan`] where an
/// Err: [`Refusal::Committed`];
/// [`Refusal::EncoderOpen`] while another encoder of the command
/// buffer is open; [`Refusal::OtherDevice`] for another device's
/// texture; [`Refusal::AttachmentUsage`];
/// [`Refusal::AttachmentPlace`];
/// [`Refusal::AttachmentFormat`];
/// [`Gap::RenderPass`];
/// [`Limit::ColorAttachments`]; [`Error::Vulkan`] where an
/// attachment's view cannot be made or the command buffer cannot record. A refused
/// descriptor leaves the command buffer as it was, open for another encoder.
pub fn render_command_encoder(
+2 -2
View File
@@ -402,7 +402,7 @@ mod on_device {
let mut d = plain.clone();
d.stencil_format = Some(PixelFormat::Stencil8);
each_device("draw_stencil", |name, _, device| {
let state = state(name, &device, &d);
let stenciled = state(name, &device, &d);
let mut buffers = Buffers::new(&device);
let (positions, colors) = vertices(&device, &mut buffers);
let color = target(
@@ -432,7 +432,7 @@ mod on_device {
.render_command_encoder(&pass(&color, Some(&stencil))))
.unwrap_or_else(|error| panic!("{name}: {error}"));
let draw = |result: Result<(), Error>| result.unwrap_or_else(|e| panic!("{name}: {e}"));
draw(encoder.set_render_pipeline_state(&state));
draw(encoder.set_render_pipeline_state(&stenciled));
draw(encoder.set_vertex_buffer(Some(&positions), 0, 0));
draw(encoder.set_vertex_buffer(Some(&colors), 0, 1));
// 0x1a5 saturates to 255 as Metal stores it; the test compares what the first draw