Files
vectorcraft/crates/svg/tests/it/main.rs
T
dotCooCoo 0663c76be1 Envelopes: a partly transparent image keeps its alpha where its warp pieces overlap
An envelope or the Warp effect cuts an image into triangle pieces that
reach a little past their edges, so neighbors overlap and no seams show.
On an image with alpha, the overlap drew that alpha twice: a 50% image
came out about 75% opaque along every cell edge and diagonal.

- The pieces now form a knockout group, and each piece is marked as a
  warp piece (`warp_piece`) whose knockout shape is its whole triangle,
  so where pieces overlap only the top one draws.
- The canvas knocks each piece out by its triangle at full coverage.
- SVG and PDF draw the pieces of a partly transparent image (its pixels,
  opacity, color mask or colorize paint) through one mask each, of the
  later triangles that reach it; pixels on a triangle's antialiased edge
  come out slightly lighter there. Pieces of an opaque image are drawn
  one over another as before.
- SVG writes one copy of the image for pieces cut by opacity masks
  (Preserve Shape Using Transparency) too.
- A cell count past the generated-object budget makes an empty group
  instead of overflowing.

Docs: docs/target-app-parity.md.
2026-11-13 08:38:48 -08:00

45 lines
961 B
Rust
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
//! Integration tests: one test binary for the crate, one module per area.
// Unwrapping and panicking on failure is fine here, unlike in shipped code (AGENTS.md › Robustness).
#![allow(clippy::unwrap_used, clippy::expect_used, clippy::panic)]
mod basic_shapes;
mod blend_export;
mod clip_text;
mod colorized_images;
mod colour_glyphs;
mod conic;
mod container_export;
mod css_rules;
mod dash_align;
mod data_attributes;
mod diamond;
mod effects_export;
mod encoding_profile_fonts;
mod focal;
mod font_weights;
mod foreign_attributes;
mod gradients;
mod ids;
mod image_orientation;
mod import_details;
mod import_live;
mod import_text;
mod import_units;
mod interactivity;
mod mask_options;
mod mesh_export;
mod non_scaling_stroke;
mod options;
mod prop_svg;
mod raster_paints;
mod roundtrip;
mod spread;
mod stroke_export;
mod svg_glyphs;
mod symbols_layers;
mod text_layout;
mod text_paint_order;
mod text_stroke;
mod title_control_chars;
mod warp_pieces;