mirror of
https://github.com/SpaceManiac/SpacemanDMM.git
synced 2025-12-23 05:36:47 +00:00
Remove RenderPass::adjust_vars
This commit is contained in:
parent
c8950c0ebc
commit
900177e280
2 changed files with 2 additions and 13 deletions
|
|
@ -58,9 +58,6 @@ pub fn generate(ctx: Context, icon_cache: &IconCache) -> Result<Image, ()> {
|
|||
continue;
|
||||
}
|
||||
'atom: for mut atom in get_atom_list(objtree, &map.dictionary[e], (x as u32, y as u32), render_passes, Some(ctx.errors)) {
|
||||
for pass in render_passes {
|
||||
pass.adjust_vars(&mut atom, &objtree);
|
||||
}
|
||||
for pass in render_passes.iter() {
|
||||
// Note that late_filter is NOT called during smoothing lookups.
|
||||
if !pass.late_filter(&atom, objtree) {
|
||||
|
|
|
|||
|
|
@ -35,12 +35,6 @@ pub trait RenderPass: Sync {
|
|||
output: &mut Vec<Atom<'a>>,
|
||||
) -> bool { false }
|
||||
|
||||
/// Adjust the variables of an atom.
|
||||
fn adjust_vars<'a>(&self,
|
||||
atom: &mut Atom<'a>,
|
||||
objtree: &'a ObjectTree,
|
||||
) {}
|
||||
|
||||
fn adjust_sprite<'a>(&self,
|
||||
atom: &Atom<'a>,
|
||||
sprite: &mut Sprite<'a>,
|
||||
|
|
@ -56,10 +50,8 @@ pub trait RenderPass: Sync {
|
|||
overlays: &mut Vec<Sprite<'a>>,
|
||||
) {}
|
||||
|
||||
/// Filter atoms at the end of the process.
|
||||
///
|
||||
/// Will act on adjusted atoms and pseudo-atoms from `adjust_vars` and
|
||||
/// `overlays`. Return `true` to keep and `false` to discard.
|
||||
/// Filter atoms at the end of the process, after they have been taken into
|
||||
/// account by their neighbors.
|
||||
fn late_filter(&self,
|
||||
atom: &Atom,
|
||||
objtree: &ObjectTree,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue