代码之家  ›  专栏  ›  技术社区  ›  cjds

使用SMIL链接两个<animateTransform>s

  •  2
  • cjds  · 技术社区  · 7 年前

    我试图在SVG中一个接一个地运行两个动画。

    但是,当我运行此操作时,变换似乎在第一个动画结束时重置

        <animateTransform attributeName="transform"
                          id="anim1" 
                          type="rotate"
                          from="0 72 72"
                          to="40 72 72"
                          begin="0s; anim2.end"
                          dur="1s"
                          fill="freeze" repeatCount="1" />
        <animateTransform attributeName="transform"
                          id="anim2"
                          type="translate"
                          from="0 0"
                          to="10 0"
                           begin="anim1.end" dur="0.4s" fill="freeze"/>
    
    1 回复  |  直到 7 年前
        1
  •  4
  •   ccprog    3 年前

    定义 additive="sum" on top of the other .