Format
This commit is contained in:
parent
59c2b53350
commit
8ff17aca1e
30 changed files with 222 additions and 244 deletions
|
|
@ -615,7 +615,7 @@ impl VulkanRenderer {
|
|||
format: pipelines.format,
|
||||
vert: self.rounded_tex_vert_shader.clone(),
|
||||
frag: self.rounded_tex_frag_shader.clone(),
|
||||
blend: true, // always blend since corners are transparent
|
||||
blend: true, // always blend since corners are transparent
|
||||
src_has_alpha: true, // rounding makes everything have alpha
|
||||
has_alpha_mult,
|
||||
alpha_mode: key.tex_alpha_mode,
|
||||
|
|
@ -973,7 +973,9 @@ impl VulkanRenderer {
|
|||
}
|
||||
VulkanOp::RoundedFill(mut f) => {
|
||||
f.range_address = memory.data_buffer.len() as DeviceAddress;
|
||||
memory.data_buffer.extend_from_slice(uapi::as_bytes(&f.target));
|
||||
memory
|
||||
.data_buffer
|
||||
.extend_from_slice(uapi::as_bytes(&f.target));
|
||||
mops.push(VulkanOp::RoundedFill(f));
|
||||
}
|
||||
VulkanOp::RoundedTex(mut c) => {
|
||||
|
|
@ -1370,8 +1372,18 @@ impl VulkanRenderer {
|
|||
for pass in RenderPass::variants() {
|
||||
for cmd in &mut memory.ops[pass] {
|
||||
let tex_data = match cmd {
|
||||
VulkanOp::Tex(c) => Some((&c.tex, &mut c.buffer_resv, &mut c.acquire_sync, c.release_sync)),
|
||||
VulkanOp::RoundedTex(c) => Some((&c.tex, &mut c.buffer_resv, &mut c.acquire_sync, c.release_sync)),
|
||||
VulkanOp::Tex(c) => Some((
|
||||
&c.tex,
|
||||
&mut c.buffer_resv,
|
||||
&mut c.acquire_sync,
|
||||
c.release_sync,
|
||||
)),
|
||||
VulkanOp::RoundedTex(c) => Some((
|
||||
&c.tex,
|
||||
&mut c.buffer_resv,
|
||||
&mut c.acquire_sync,
|
||||
c.release_sync,
|
||||
)),
|
||||
_ => None,
|
||||
};
|
||||
if let Some((tex, buffer_resv, acquire_sync, release_sync)) = tex_data {
|
||||
|
|
@ -1623,8 +1635,7 @@ impl VulkanRenderer {
|
|||
let memory = &*self.memory.borrow();
|
||||
let fill_pl = self.get_or_create_fill_pipelines(target.format.vk_format)?;
|
||||
let tex_pl = self.get_or_create_tex_pipelines(target.format.vk_format, target_cd);
|
||||
let rounded_fill_pl =
|
||||
self.get_or_create_rounded_fill_pipelines(target.format.vk_format)?;
|
||||
let rounded_fill_pl = self.get_or_create_rounded_fill_pipelines(target.format.vk_format)?;
|
||||
let rounded_tex_pl =
|
||||
self.get_or_create_rounded_tex_pipelines(target.format.vk_format, target_cd);
|
||||
let dev = &self.device.device;
|
||||
|
|
@ -2416,9 +2427,7 @@ impl VulkanRenderer {
|
|||
// but they do paint pixels and need paint regions.
|
||||
(false, rf.rect)
|
||||
}
|
||||
GfxApiOpt::RoundedCopyTexture(ct) => {
|
||||
(false, ct.target)
|
||||
}
|
||||
GfxApiOpt::RoundedCopyTexture(ct) => (false, ct.target),
|
||||
};
|
||||
if opaque || bb.is_none() {
|
||||
tag |= 1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue