diff --git a/examples/animation/color_animation.rs b/examples/animation/color_animation.rs index cde5797b20385..813fcf4c72feb 100644 --- a/examples/animation/color_animation.rs +++ b/examples/animation/color_animation.rs @@ -7,15 +7,11 @@ use bevy::{ // We define this trait so we can reuse the same code for multiple color types that may be implemented using curves. trait CurveColor: Point + Into + Send + Sync + 'static {} -impl CurveColor for LinearRgba {} -impl CurveColor for Oklaba {} -impl CurveColor for Xyza {} +impl + Send + Sync + 'static> CurveColor for T {} // We define this trait so we can reuse the same code for multiple color types that may be implemented using mixing. trait MixedColor: Mix + Into + Send + Sync + 'static {} -impl MixedColor for Oklcha {} -impl MixedColor for Srgba {} -impl MixedColor for Hsla {} +impl + Send + Sync + 'static> MixedColor for T {} #[derive(Debug, Component)] struct Curve(CubicCurve);