3.x资源模板定义

为了简化设置的复杂性,特意针对svg/img资源渲染方式实现了两个模板解析,省略链式设置的复杂性;通过设置资源模板 tpl 文件,来实现个性二维码的生成

说明:资源模板当前只支持3.x版本,若2.x版本需要使用,请升级

1. svg模板

svg模板中主要定义svg格式的资源信息,当前支持以下几种资源的的设置

二维码信息点

即我们常见的二维码中的黑白方块,其对应的type = pre/bg

探测图形

即三个回字形码眼,其设置方式有两种,若所有的码眼都是相同的资源,设置一个 type = detect 的symbol标签即可

若每个码眼对应的资源都是独立的,则需要设置三个symbol标签,对应的type分别为

  • detect_lt: 左上角 (left top)
  • detect_rt: 右上角 (right top)
  • detect_ld: 左下角 (left down)

logo

svg二维码依然支持logo设置,注意logo对应的资源标签symbol的属性 type = logo

1.1 模板格式说明

下面是一个可以直接使用的模板定义文件,将给予它对照说明

以一个可用的模板“愤怒的小猪”进行演示说明

点击展开 【愤怒的小猪】
<defs>
      <g id="def_HA62">
          <path d="M5.74,0.06c4.18-0.11,8.34-0.03,12.53,0c0.83-0.02,1.64,0.13,2.43,0.31c0.07,0.96,0.33,1.92,0.28,2.89c-0.06,1.24,0.18,2.5-0.16,3.72C13.95,7,7.08,7.05,0.26,6.67c-0.36-2.1-0.31-4.23-0.07-6.35C1.98-0.05,3.88,0.11,5.74,0.06" style="fill: #8C4410" />
          <path d="M0.68,0.53c2.11-0.16,4.23-0.07,6.34-0.15c1.6,0,3.2-0.12,4.8-0.01c1.47,0.1,2.95,0.05,4.43,0.1c-0.18,0.12-0.36,0.23-0.53,0.35C11.88,0.78,8.05,0.93,4.23,0.97C3.13,1,1.84,0.83,0.99,1.44C0.91,1.48,0.75,1.57,0.67,1.61C0.67,1.25,0.66,0.89,0.68,0.53z" style="fill: #e29126" />
          <path d="M11.81,0.37c2.15-0.06,4.3-0.01,6.45,0.01c0.7,0,1.37,0.13,2.03,0.27c-0.1,0.18-0.2,0.35-0.3,0.53c-1.28-0.11-2.54-0.27-3.82-0.35c-0.12-0.01-0.35-0.01-0.46-0.02c0.18-0.12,0.35-0.24,0.53-0.35C14.76,0.42,13.28,0.46,11.81,0.37z" style="fill: #e29126" />
          <path d="M4.23,0.97c3.83-0.04,7.65-0.19,11.48-0.15c0.11,0.01,0.35,0.01,0.46,0.02c-0.11,0.51-0.19,1.02-0.25,1.53c-0.73,0.03-1.46,0.05-2.19,0.06l0.01,0.1c0.68,0.01,1.36,0.03,2.05,0.06c-0.31,0.69-0.58,1.4-1.16,2.01c-0.46,0.48-1.01,0.93-1.5,1.4c-2.28,0.18-4.58,0.04-6.85,0.06C4.5,6.06,2.7,5.92,0.95,6.17C1.04,5.83,1.09,5.5,1.14,5.16C3,5.17,4.85,4.9,6.7,4.94l0.02-0.1C4.7,4.89,2.68,4.82,0.65,4.78c0.22-0.21,0.53-0.39,0.51-0.66C1.29,3.36,1.23,2.6,1.21,1.85c1.53-0.02,3.07,0.03,4.59-0.14C6.6,1.62,7.42,1.64,8.23,1.67l0.02-0.11c-2.42,0-4.87,0.13-7.26-0.12C1.84,0.84,3.12,1.01,4.23,0.97z" style="fill: #D27F1F" />
          <path d="M16.17,0.84c1.28,0.08,2.54,0.24,3.82,0.35c-0.22,0.37-0.42,0.74-0.6,1.12c-1.15,0.12-2.31,0.11-3.47,0.07C15.98,1.86,16.06,1.34,16.17,0.84z" style="fill: #D27F1F" />
          <path d="M15.78,2.58c1.18,0.1,2.36,0.18,3.55,0.15c-0.04,0.92,0.23,1.89-0.26,2.78c-0.11,0.32-0.66,0.27-1.04,0.31C16.39,5.87,14.75,5.87,13.12,6c0.49-0.47,1.03-0.92,1.5-1.4C15.2,3.98,15.47,3.27,15.78,2.58z" style="fill: #D27F1F" />
          <path d="M0.65,1.91C0.79,1.9,1.06,1.87,1.2,1.85C1.23,2.6,1.28,3.37,1.15,4.12C1.17,4.4,0.86,4.57,0.64,4.78C0.5,3.83,0.44,2.86,0.65,1.91z" style="fill: #e29126" />
          <path d="M19.32,2.73c0.37,0.07,0.99,0,0.98,0.38c0.07,1.18,0.2,2.37,0.21,3.55c-3.22,0-6.43-0.05-9.65,0.05C9.06,6.72,7.28,6.5,5.5,6.49C3.94,6.45,2.34,6.6,0.82,6.29l0.13-0.12c1.75-0.26,3.54-0.1,5.32-0.12C8.55,6.04,10.84,6.18,13.12,6c1.62-0.13,3.26-0.13,4.9-0.18c0.37-0.04,0.93,0.01,1.04-0.31C19.55,4.63,19.28,3.65,19.32,2.73z" style="fill: #B76A26" />
          <path d="M0.61,5.15c0.13,0.01,0.4,0.01,0.53,0.02C1.08,5.5,1.03,5.83,0.95,6.18L0.82,6.29L0.69,6.4C0.65,5.99,0.63,5.57,0.61,5.15z" style="fill: #e29126" />
      </g>
      <g id="def_pTxe">
          <path d="M5.74,0.06c4.18-0.11,8.34-0.03,12.53,0c0.83-0.02,1.64,0.13,2.43,0.31c0.07,0.96,0.33,1.92,0.28,2.89c-0.06,1.24,0.18,2.5-0.16,3.72C13.95,7,7.08,7.05,0.26,6.67c-0.36-2.1-0.31-4.23-0.07-6.35C1.98-0.05,3.88,0.11,5.74,0.06" style="fill: #8C4410" />
          <path d="M0.68,0.53c2.11-0.16,4.23-0.07,6.34-0.15c1.6,0,3.2-0.12,4.8-0.01c1.47,0.1,2.95,0.05,4.43,0.1c-0.18,0.12-0.36,0.23-0.53,0.35C11.88,0.78,8.05,0.93,4.23,0.97C3.13,1,1.84,0.83,0.99,1.44C0.91,1.48,0.75,1.57,0.67,1.61C0.67,1.25,0.66,0.89,0.68,0.53z" style="fill: #e29126" />
          <path d="M11.81,0.37c2.15-0.06,4.3-0.01,6.45,0.01c0.7,0,1.37,0.13,2.03,0.27c-0.1,0.18-0.2,0.35-0.3,0.53c-1.28-0.11-2.54-0.27-3.82-0.35c-0.12-0.01-0.35-0.01-0.46-0.02c0.18-0.12,0.35-0.24,0.53-0.35C14.76,0.42,13.28,0.46,11.81,0.37z" style="fill: #e29126" />
          <path d="M4.23,0.97c3.83-0.04,7.65-0.19,11.48-0.15c0.11,0.01,0.35,0.01,0.46,0.02c-0.11,0.51-0.19,1.02-0.25,1.53c-0.73,0.03-1.46,0.05-2.19,0.06l0.01,0.1c0.68,0.01,1.36,0.03,2.05,0.06c-0.31,0.69-0.58,1.4-1.16,2.01c-0.46,0.48-1.01,0.93-1.5,1.4c-2.28,0.18-4.58,0.04-6.85,0.06C4.5,6.06,2.7,5.92,0.95,6.17C1.04,5.83,1.09,5.5,1.14,5.16C3,5.17,4.85,4.9,6.7,4.94l0.02-0.1C4.7,4.89,2.68,4.82,0.65,4.78c0.22-0.21,0.53-0.39,0.51-0.66C1.29,3.36,1.23,2.6,1.21,1.85c1.53-0.02,3.07,0.03,4.59-0.14C6.6,1.62,7.42,1.64,8.23,1.67l0.02-0.11c-2.42,0-4.87,0.13-7.26-0.12C1.84,0.84,3.12,1.01,4.23,0.97z" style="fill: #D27F1F" />
          <path d="M16.17,0.84c1.28,0.08,2.54,0.24,3.82,0.35c-0.22,0.37-0.42,0.74-0.6,1.12c-1.15,0.12-2.31,0.11-3.47,0.07C15.98,1.86,16.06,1.34,16.17,0.84z" style="fill: #D27F1F" />
          <path d="M15.78,2.58c1.18,0.1,2.36,0.18,3.55,0.15c-0.04,0.92,0.23,1.89-0.26,2.78c-0.11,0.32-0.66,0.27-1.04,0.31C16.39,5.87,14.75,5.87,13.12,6c0.49-0.47,1.03-0.92,1.5-1.4C15.2,3.98,15.47,3.27,15.78,2.58z" style="fill: #D27F1F" />
          <path d="M0.65,1.91C0.79,1.9,1.06,1.87,1.2,1.85C1.23,2.6,1.28,3.37,1.15,4.12C1.17,4.4,0.86,4.57,0.64,4.78C0.5,3.83,0.44,2.86,0.65,1.91z" style="fill: #e29126" />
          <path d="M19.32,2.73c0.37,0.07,0.99,0,0.98,0.38c0.07,1.18,0.2,2.37,0.21,3.55c-3.22,0-6.43-0.05-9.65,0.05C9.06,6.72,7.28,6.5,5.5,6.49C3.94,6.45,2.34,6.6,0.82,6.29l0.13-0.12c1.75-0.26,3.54-0.1,5.32-0.12C8.55,6.04,10.84,6.18,13.12,6c1.62-0.13,3.26-0.13,4.9-0.18c0.37-0.04,0.93,0.01,1.04-0.31C19.55,4.63,19.28,3.65,19.32,2.73z" style="fill: #B76A26" />
          <path d="M0.61,5.15c0.13,0.01,0.4,0.01,0.53,0.02C1.08,5.5,1.03,5.83,0.95,6.18L0.82,6.29L0.69,6.4C0.65,5.99,0.63,5.57,0.61,5.15z" style="fill: #e29126" />
      </g>
      <g id="def_9zLD">
          <path d="M5.74,0.06c4.18-0.11,8.34-0.03,12.53,0c0.83-0.02,1.64,0.13,2.43,0.31c0.07,0.96,0.33,1.92,0.28,2.89c-0.06,1.24,0.18,2.5-0.16,3.72C13.95,7,7.08,7.05,0.26,6.67c-0.36-2.1-0.31-4.23-0.07-6.35C1.98-0.05,3.88,0.11,5.74,0.06" style="fill: #8C4410" />
          <path d="M0.68,0.53c2.11-0.16,4.23-0.07,6.34-0.15c1.6,0,3.2-0.12,4.8-0.01c1.47,0.1,2.95,0.05,4.43,0.1c-0.18,0.12-0.36,0.23-0.53,0.35C11.88,0.78,8.05,0.93,4.23,0.97C3.13,1,1.84,0.83,0.99,1.44C0.91,1.48,0.75,1.57,0.67,1.61C0.67,1.25,0.66,0.89,0.68,0.53z" style="fill: #e29126" />
          <path d="M11.81,0.37c2.15-0.06,4.3-0.01,6.45,0.01c0.7,0,1.37,0.13,2.03,0.27c-0.1,0.18-0.2,0.35-0.3,0.53c-1.28-0.11-2.54-0.27-3.82-0.35c-0.12-0.01-0.35-0.01-0.46-0.02c0.18-0.12,0.35-0.24,0.53-0.35C14.76,0.42,13.28,0.46,11.81,0.37z" style="fill: #e29126" />
          <path d="M4.23,0.97c3.83-0.04,7.65-0.19,11.48-0.15c0.11,0.01,0.35,0.01,0.46,0.02c-0.11,0.51-0.19,1.02-0.25,1.53c-0.73,0.03-1.46,0.05-2.19,0.06l0.01,0.1c0.68,0.01,1.36,0.03,2.05,0.06c-0.31,0.69-0.58,1.4-1.16,2.01c-0.46,0.48-1.01,0.93-1.5,1.4c-2.28,0.18-4.58,0.04-6.85,0.06C4.5,6.06,2.7,5.92,0.95,6.17C1.04,5.83,1.09,5.5,1.14,5.16C3,5.17,4.85,4.9,6.7,4.94l0.02-0.1C4.7,4.89,2.68,4.82,0.65,4.78c0.22-0.21,0.53-0.39,0.51-0.66C1.29,3.36,1.23,2.6,1.21,1.85c1.53-0.02,3.07,0.03,4.59-0.14C6.6,1.62,7.42,1.64,8.23,1.67l0.02-0.11c-2.42,0-4.87,0.13-7.26-0.12C1.84,0.84,3.12,1.01,4.23,0.97z" style="fill: #D27F1F" />
          <path d="M16.17,0.84c1.28,0.08,2.54,0.24,3.82,0.35c-0.22,0.37-0.42,0.74-0.6,1.12c-1.15,0.12-2.31,0.11-3.47,0.07C15.98,1.86,16.06,1.34,16.17,0.84z" style="fill: #D27F1F" />
          <path d="M15.78,2.58c1.18,0.1,2.36,0.18,3.55,0.15c-0.04,0.92,0.23,1.89-0.26,2.78c-0.11,0.32-0.66,0.27-1.04,0.31C16.39,5.87,14.75,5.87,13.12,6c0.49-0.47,1.03-0.92,1.5-1.4C15.2,3.98,15.47,3.27,15.78,2.58z" style="fill: #D27F1F" />
          <path d="M0.65,1.91C0.79,1.9,1.06,1.87,1.2,1.85C1.23,2.6,1.28,3.37,1.15,4.12C1.17,4.4,0.86,4.57,0.64,4.78C0.5,3.83,0.44,2.86,0.65,1.91z" style="fill: #e29126" />
          <path d="M19.32,2.73c0.37,0.07,0.99,0,0.98,0.38c0.07,1.18,0.2,2.37,0.21,3.55c-3.22,0-6.43-0.05-9.65,0.05C9.06,6.72,7.28,6.5,5.5,6.49C3.94,6.45,2.34,6.6,0.82,6.29l0.13-0.12c1.75-0.26,3.54-0.1,5.32-0.12C8.55,6.04,10.84,6.18,13.12,6c1.62-0.13,3.26-0.13,4.9-0.18c0.37-0.04,0.93,0.01,1.04-0.31C19.55,4.63,19.28,3.65,19.32,2.73z" style="fill: #B76A26" />
          <path d="M0.61,5.15c0.13,0.01,0.4,0.01,0.53,0.02C1.08,5.5,1.03,5.83,0.95,6.18L0.82,6.29L0.69,6.4C0.65,5.99,0.63,5.57,0.61,5.15z" style="fill: #e29126" />
      </g>
  </defs>
  <symbol id="symbol_1z" viewBox="0 0 49 49"  type="detect_rt">
          <use x="0.4" y="0" xlink:href="#def_HA62" />
          <use x="21.2" y="0" xlink:href="#def_HA62" />
          <use x="6.8" y="42" xlink:href="#def_HA62" />
          <use x="27.6" y="42" xlink:href="#def_HA62" />
          <use transform="rotate(90)" x="0.4" y="-49" xlink:href="#def_HA62" />
          <use transform="rotate(90)" x="21.2" y="-49" xlink:href="#def_HA62" />
          <use transform="rotate(90)" x="6.8" y="-7" xlink:href="#def_HA62" />
          <use transform="rotate(90)" x="27.6" y="-7" xlink:href="#def_HA62" />
          <path d="M17.68,15.8c4.12-0.29,8.25-0.32,12.39-0.26c1.08,0.1,2.51-0.15,3.12,1c0.71,1.36,0.8,2.96,1.08,4.45  c0.08,1.92,0,3.83,0.01,5.75c-0.12,2.45-0.03,5.03-1.1,7.29c-5.11,0.55-10.27,0.64-15.38,0.22c-2.45-5.39-2.48-11.52-1.55-17.25  C16.29,16.3,16.98,15.81,17.68,15.8" style="fill: #8C4410" />
          <path d="M16.65,29.41c0.58,0.12,1.16,0.26,1.75,0.4c0.12,0.96,0.25,1.92,0.37,2.88c-0.3,0.1-0.91,0.3-1.21,0.39  C17.31,31.85,16.97,30.62,16.65,29.41z" style="fill: #E29126" />
          <path d="M18.56,17.94c4.68-0.57,9.42-0.32,14.11-0.86c-0.32,1.08-0.56,2.2-0.75,3.32c-2.53,0.34-5.08,0.46-7.61,0.74  c1.47,0.16,2.96,0.23,4.44,0.36c0.58,0.28,1.17,0.58,1.74,0.89c-1.88,2.99-4.27,6.79-8.33,6.42c-1.87,0-3.74-0.17-5.59-0.37  c0.39-0.07,1.16-0.2,1.56-0.28C18.16,24.75,17.97,21.32,18.56,17.94z" style="fill: #D27F1F" />
          <path d="M16.86,16.29c4.48-0.18,8.94-0.3,13.42-0.2c0.83,0.08,1.83-0.04,2.49,0.62l-0.1,0.38  c-4.68,0.53-9.43,0.29-14.11,0.86c-0.58,3.38-0.4,6.81-0.44,10.23c-0.39,0.07-1.17,0.21-1.56,0.28  C15.9,24.41,16.19,20.3,16.86,16.29z" style="fill: #E29126" />
          <path d="M28.74,21.5c1.18,0.08,2.34,0.32,3.47,0.62c-0.32,1.5-0.31,3.04-0.22,4.58c0.13,1.67-0.79,3.16-1.44,4.65  c-3.94,0.23-7.95,0.36-11.8,1.34c-0.12-0.96-0.25-1.93-0.37-2.88c-0.58-0.14-1.17-0.27-1.75-0.4c1.83-0.31,3.66-0.48,5.51-0.59  c4.06,0.37,6.44-3.44,8.33-6.42C29.91,22.08,29.32,21.78,28.74,21.5z" style="fill: #D27F1F" />
          <path d="M32.77,16.71L32.77,16.71c1.12,5.6,1.21,11.1,0.25,16.73c-4.47,0.62-8.99,0.69-13.49,0.47  c-0.76,0.04-1.42-0.34-1.98-0.82c0.31-0.1,0.91-0.3,1.21-0.4c3.85-0.97,7.84-1.11,11.8-1.34c0.65-1.48,1.57-2.97,1.44-4.65  c-0.08-1.53-0.1-3.08,0.22-4.58c-1.14-0.31-2.29-0.54-3.47-0.62c-1.48-0.13-2.96-0.19-4.44-0.36c2.53-0.28,5.09-0.4,7.61-0.74  c0.19-1.12,0.44-2.23,0.75-3.32L32.77,16.71z" style="fill: #B56925" />
      </symbol>
<symbol id="symbol_1A" viewBox="0 0 49 49" type="detect_lt">
      <use x="0.4" y="0" xlink:href="#def_pTxe" />
      <use x="21.2" y="0" xlink:href="#def_pTxe" />
      <use x="6.8" y="42" xlink:href="#def_pTxe" />
      <use x="27.6" y="42" xlink:href="#def_pTxe" />
      <use transform="rotate(90)" x="0.4" y="-49" xlink:href="#def_pTxe" />
      <use transform="rotate(90)" x="21.2" y="-49" xlink:href="#def_pTxe" />
      <use transform="rotate(90)" x="6.8" y="-7" xlink:href="#def_pTxe" />
      <use transform="rotate(90)" x="27.6" y="-7" xlink:href="#def_pTxe" />
      <path d="M17.68,15.8c4.12-0.29,8.25-0.32,12.39-0.26c1.08,0.1,2.51-0.15,3.12,1c0.71,1.36,0.8,2.96,1.08,4.45  c0.08,1.92,0,3.83,0.01,5.75c-0.12,2.45-0.03,5.03-1.1,7.29c-5.11,0.55-10.27,0.64-15.38,0.22c-2.45-5.39-2.48-11.52-1.55-17.25  C16.29,16.3,16.98,15.81,17.68,15.8" style="fill: #8C4410" />
      <path d="M16.65,29.41c0.58,0.12,1.16,0.26,1.75,0.4c0.12,0.96,0.25,1.92,0.37,2.88c-0.3,0.1-0.91,0.3-1.21,0.39  C17.31,31.85,16.97,30.62,16.65,29.41z" style="fill: #E29126" />
      <path d="M18.56,17.94c4.68-0.57,9.42-0.32,14.11-0.86c-0.32,1.08-0.56,2.2-0.75,3.32c-2.53,0.34-5.08,0.46-7.61,0.74  c1.47,0.16,2.96,0.23,4.44,0.36c0.58,0.28,1.17,0.58,1.74,0.89c-1.88,2.99-4.27,6.79-8.33,6.42c-1.87,0-3.74-0.17-5.59-0.37  c0.39-0.07,1.16-0.2,1.56-0.28C18.16,24.75,17.97,21.32,18.56,17.94z" style="fill: #D27F1F" />
      <path d="M16.86,16.29c4.48-0.18,8.94-0.3,13.42-0.2c0.83,0.08,1.83-0.04,2.49,0.62l-0.1,0.38  c-4.68,0.53-9.43,0.29-14.11,0.86c-0.58,3.38-0.4,6.81-0.44,10.23c-0.39,0.07-1.17,0.21-1.56,0.28  C15.9,24.41,16.19,20.3,16.86,16.29z" style="fill: #E29126" />
      <path d="M28.74,21.5c1.18,0.08,2.34,0.32,3.47,0.62c-0.32,1.5-0.31,3.04-0.22,4.58c0.13,1.67-0.79,3.16-1.44,4.65  c-3.94,0.23-7.95,0.36-11.8,1.34c-0.12-0.96-0.25-1.93-0.37-2.88c-0.58-0.14-1.17-0.27-1.75-0.4c1.83-0.31,3.66-0.48,5.51-0.59  c4.06,0.37,6.44-3.44,8.33-6.42C29.91,22.08,29.32,21.78,28.74,21.5z" style="fill: #D27F1F" />
      <path d="M32.77,16.71L32.77,16.71c1.12,5.6,1.21,11.1,0.25,16.73c-4.47,0.62-8.99,0.69-13.49,0.47  c-0.76,0.04-1.42-0.34-1.98-0.82c0.31-0.1,0.91-0.3,1.21-0.4c3.85-0.97,7.84-1.11,11.8-1.34c0.65-1.48,1.57-2.97,1.44-4.65  c-0.08-1.53-0.1-3.08,0.22-4.58c-1.14-0.31-2.29-0.54-3.47-0.62c-1.48-0.13-2.96-0.19-4.44-0.36c2.53-0.28,5.09-0.4,7.61-0.74  c0.19-1.12,0.44-2.23,0.75-3.32L32.77,16.71z" style="fill: #B56925" />
  </symbol>
<symbol id="symbol_1B" viewBox="0 0 49 49" type="detect_ld">
      <use x="0.4" y="0" xlink:href="#def_9zLD" />
      <use x="21.2" y="0" xlink:href="#def_9zLD" />
      <use x="6.8" y="42" xlink:href="#def_9zLD" />
      <use x="27.6" y="42" xlink:href="#def_9zLD" />
      <use transform="rotate(90)" x="0.4" y="-49" xlink:href="#def_9zLD" />
      <use transform="rotate(90)" x="21.2" y="-49" xlink:href="#def_9zLD" />
      <use transform="rotate(90)" x="6.8" y="-7" xlink:href="#def_9zLD" />
      <use transform="rotate(90)" x="27.6" y="-7" xlink:href="#def_9zLD" />
      <path d="M17.68,15.8c4.12-0.29,8.25-0.32,12.39-0.26c1.08,0.1,2.51-0.15,3.12,1c0.71,1.36,0.8,2.96,1.08,4.45  c0.08,1.92,0,3.83,0.01,5.75c-0.12,2.45-0.03,5.03-1.1,7.29c-5.11,0.55-10.27,0.64-15.38,0.22c-2.45-5.39-2.48-11.52-1.55-17.25  C16.29,16.3,16.98,15.81,17.68,15.8" style="fill: #8C4410" />
      <path d="M16.65,29.41c0.58,0.12,1.16,0.26,1.75,0.4c0.12,0.96,0.25,1.92,0.37,2.88c-0.3,0.1-0.91,0.3-1.21,0.39  C17.31,31.85,16.97,30.62,16.65,29.41z" style="fill: #E29126" />
      <path d="M18.56,17.94c4.68-0.57,9.42-0.32,14.11-0.86c-0.32,1.08-0.56,2.2-0.75,3.32c-2.53,0.34-5.08,0.46-7.61,0.74  c1.47,0.16,2.96,0.23,4.44,0.36c0.58,0.28,1.17,0.58,1.74,0.89c-1.88,2.99-4.27,6.79-8.33,6.42c-1.87,0-3.74-0.17-5.59-0.37  c0.39-0.07,1.16-0.2,1.56-0.28C18.16,24.75,17.97,21.32,18.56,17.94z" style="fill: #D27F1F" />
      <path d="M16.86,16.29c4.48-0.18,8.94-0.3,13.42-0.2c0.83,0.08,1.83-0.04,2.49,0.62l-0.1,0.38  c-4.68,0.53-9.43,0.29-14.11,0.86c-0.58,3.38-0.4,6.81-0.44,10.23c-0.39,0.07-1.17,0.21-1.56,0.28  C15.9,24.41,16.19,20.3,16.86,16.29z" style="fill: #E29126" />
      <path d="M28.74,21.5c1.18,0.08,2.34,0.32,3.47,0.62c-0.32,1.5-0.31,3.04-0.22,4.58c0.13,1.67-0.79,3.16-1.44,4.65  c-3.94,0.23-7.95,0.36-11.8,1.34c-0.12-0.96-0.25-1.93-0.37-2.88c-0.58-0.14-1.17-0.27-1.75-0.4c1.83-0.31,3.66-0.48,5.51-0.59  c4.06,0.37,6.44-3.44,8.33-6.42C29.91,22.08,29.32,21.78,28.74,21.5z" style="fill: #D27F1F" />
      <path d="M32.77,16.71L32.77,16.71c1.12,5.6,1.21,11.1,0.25,16.73c-4.47,0.62-8.99,0.69-13.49,0.47  c-0.76,0.04-1.42-0.34-1.98-0.82c0.31-0.1,0.91-0.3,1.21-0.4c3.85-0.97,7.84-1.11,11.8-1.34c0.65-1.48,1.57-2.97,1.44-4.65  c-0.08-1.53-0.1-3.08,0.22-4.58c-1.14-0.31-2.29-0.54-3.47-0.62c-1.48-0.13-2.96-0.19-4.44-0.36c2.53-0.28,5.09-0.4,7.61-0.74  c0.19-1.12,0.44-2.23,0.75-3.32L32.77,16.71z" style="fill: #B56925" />
  </symbol>
<symbol id="symbol_1D" viewBox="0 0 50 50" size="1x1">
      <path d="M13.93,3.75c3.01-0.79,6.11-1.19,9.21-1.43c2.38-0.07,4.76-0.14,7.13-0.07c2.6,0.98,4.82,2.72,6.93,4.51c3.48,3.03,6.67,6.45,9.24,10.29c1.08,1.65,2.09,3.47,2.06,5.51c-0.02,3.98-0.5,7.99-1.52,11.85c-0.51,2.1-1.93,3.82-3.56,5.17c-3.34,2.82-6.82,5.58-10.76,7.52c-2.21,1.17-4.75,0.55-7.08,0.21c-5.34-1.01-10.69-2.13-15.89-3.7c-1.1-0.44-2.53-0.67-3.05-1.88c-1.87-3.88-3.04-8.07-4.22-12.21c-0.58-2.57-1.59-5.39-0.31-7.91c2.3-5.23,5.45-10.03,8.55-14.81C11.53,5.61,12.35,4.08,13.93,3.75" style="fill: #515151" />
      <path d="M17.56,4.27c3.55-0.58,7.15-1.02,10.75-0.97c2.85,0.05,5.2,1.96,7.19,3.81C29.98,8.38,24.5,6.01,19,6.7C18.52,5.9,18.03,5.08,17.56,4.27z" style="fill: #D5D5D5" />
      <path d="M12.3,6.59c1.1-2.19,3.83-1.34,5.38-0.16c-4.32,1.97-5.2,6.96-7.66,10.53c-2.16,3.69-6.02,6.67-6.06,11.29l-0.11,0.77c-1.06-2.25-1.67-4.99-0.43-7.29C5.84,16.39,9.02,11.43,12.3,6.59z" style="fill: #D5D5D5" />
      <path d="M19,6.71c5.51-0.69,10.98,1.67,16.5,0.41l0.41-0.05c0.79,0.73,1.57,1.46,2.38,2.19l-0.12,0.39c-0.92,2.62-1.17,5.43-2.17,8.01c-1.2,1.53-2.96,2.48-4.29,3.88c-2.75,2.81-4.15,6.55-5.8,10.04c-1.16,2.63-4.3,3.71-6.97,3.85c-2.77-1.23-4.41-4.44-7.61-4.83c-2.61-0.58-4.63,1.55-6.62,2.85c-0.61-1.64,0.42-3.45,2.03-4c2.54-0.97,5.23-1.48,7.8-2.33c-3.57-0.13-7.15,0.24-10.6,1.13c0.05-4.62,3.9-7.6,6.06-11.29c2.47-3.58,3.35-8.57,7.66-10.53c0.23,0.44,0.46,0.89,0.69,1.35C18.54,7.52,18.84,6.98,19,6.71 M26.58,19.7c-0.62,1.99-1.08,4.02-1.35,6.09c1.41-1.74,2.52-3.74,4.25-5.19c1.29-1.07,2.64-2.05,3.91-3.13C31.07,18.06,28.82,18.89,26.58,19.7z" style="fill: #A0A0A0" />
      <path d="M36.02,17.67c1-2.59,1.24-5.39,2.17-8.01c3.34,2.52,5.98,5.89,8.1,9.48c1.11,1.76,0.93,3.88,0.89,5.87c-0.82,0.12-1.63,0.24-2.45,0.37c0.83,0.38,1.63,0.77,2.46,1.16c-0.45,2.93-0.72,5.93-1.83,8.7c-0.84,2.12-2.65,3.63-4.34,5.08c-0.38-1.24-0.76-2.47-1.12-3.7c-1.1-0.29-2.21-0.58-3.31-0.85c1.65,1.46,2.61,3.43,2.92,5.6c-2.83,1.8-5.45,4.19-8.75,5.08c-4.07,0.29-8.01-1.04-11.96-1.76c-3.6-0.87-7.4-1.39-10.67-3.19c-1.81-2.32-2.22-5.37-3.4-8.02c1.99-1.29,4.01-3.43,6.62-2.85c3.19,0.39,4.84,3.6,7.61,4.83c2.67-0.14,5.8-1.22,6.97-3.85c1.65-3.49,3.05-7.23,5.8-10.04C33.05,20.15,34.82,19.2,36.02,17.67z" style="fill: #828282" />
  </symbol>
<symbol id="symbol_1F" viewBox="0 0 100 50" size="2x1">
      <path d="M28,1.48c19.29-0.75,38.59-0.22,57.91-0.01c3.85-0.11,7.58,0.91,11.21,2.09c0.33,6.59,1.52,13.15,1.27,19.76  c-0.3,8.48,0.82,17.06-0.75,25.45C65.99,49,34.27,49.31,2.69,46.76C1.04,32.36,1.28,17.81,2.36,3.38C10.63,0.74,19.44,1.85,28,1.48" style="fill: #8C4410" />
      <path d="M4.63,4.68c9.74-1.06,19.56-0.47,29.32-1c7.39-0.01,14.78-0.8,22.16-0.08c6.8,0.66,13.63,0.36,20.44,0.7  c-0.82,0.79-1.64,1.6-2.45,2.39C56.4,6.41,38.71,7.44,21.02,7.75c-5.1,0.23-11.03-0.94-14.95,3.19c-0.36,0.29-1.1,0.86-1.47,1.16  C4.57,9.62,4.56,7.15,4.63,4.68z" style="fill: #FFBE63" />
      <path d="M56.11,3.6c9.92-0.41,19.86-0.05,29.78,0.1c3.22,0,6.34,0.87,9.37,1.85c-0.46,1.21-0.93,2.42-1.4,3.63  c-5.9-0.75-11.74-1.82-17.64-2.37c-0.54-0.04-1.61-0.1-2.14-0.13c0.81-0.8,1.63-1.61,2.45-2.39C69.74,3.96,62.9,4.26,56.11,3.6z" style="fill: #E9A14C" />
      <g>
          <path d="M69.62,31.56c-0.18,0.31-0.35,0.62-0.54,0.92c-1.02,1.56-2.12,3.07-3.23,4.56c1.11-1.49,2.21-2.99,3.23-4.55   C69.27,32.19,69.44,31.87,69.62,31.56z" style="fill: none" />
          <path d="M91.09,16.79c0.82-2.57,1.77-5.11,2.77-7.62c-5.89-0.74-11.73-1.81-17.63-2.36c0,0.01,0,0.01,0,0.02   c-0.54-0.03-1.61-0.09-2.14-0.13C56.39,6.42,38.7,7.45,21.02,7.75C15.92,7.97,9.99,6.8,6.08,10.93c11.09,1.68,22.39,0.8,33.56,0.79   l-0.07,0.75c-3.77-0.2-7.55-0.32-11.28,0.28c-7.01,1.16-14.15,0.84-21.21,0.97c0.12,5.15,0.36,10.35-0.23,15.49   c0.08,1.9-1.36,3.13-2.36,4.54c9.37,0.25,18.72,0.72,28.1,0.39l-0.11,0.67c-8.6-0.27-17.1,1.6-25.7,1.56   c-0.25,2.31-0.49,4.62-0.88,6.91c8.06-1.77,16.37-0.7,24.56-0.82c10.57-0.12,21.18,0.84,31.71-0.39c1.09-1.57,2.25-3.1,3.39-4.64   c-1.15,1.54-2.3,3.07-3.39,4.65c7.5-0.9,15.09-0.9,22.62-1.2c1.73-0.3,4.28,0.07,4.8-2.14c2.28-6.05,1.05-12.69,1.22-18.99   c-5.48,0.19-10.95-0.38-16.38-1.04c0,0,0,0.01,0,0.01c-3.15-0.19-6.29-0.31-9.44-0.39l-0.04-0.65c3.37-0.07,6.75-0.18,10.11-0.39   c0.14-1.65,0.3-3.29,0.47-4.94c-0.17,1.64-0.33,3.28-0.46,4.92C80.41,17.54,85.78,17.6,91.09,16.79z M69.08,32.48   c0.19-0.3,0.36-0.61,0.54-0.92c-0.18,0.31-0.35,0.62-0.54,0.93c-1.02,1.56-2.12,3.06-3.23,4.55   C66.96,35.55,68.06,34.04,69.08,32.48z" style="fill: #D27F1F" />
      </g>
      <path d="M4.5,14.16c0.64-0.11,1.92-0.31,2.56-0.42c0.13,5.15,0.36,10.35-0.23,15.49c0.08,1.89-1.36,3.12-2.36,4.54  C3.81,27.26,3.51,20.62,4.5,14.16z" style="fill: #FEBC61" />
      <path d="M90.82,19.75c1.71,0.5,4.58,0.01,4.5,2.59c0.33,8.07,0.94,16.16,0.95,24.25c-14.86,0-29.76-0.38-44.61,0.33  c-8.27,0.13-16.47-1.32-24.75-1.4C19.7,45.23,12.3,46.27,5.29,44.1l0.6-0.81c8.07-1.78,16.37-0.71,24.56-0.82  c10.57-0.12,21.18,0.85,31.71-0.39c7.5-0.88,15.08-0.88,22.62-1.2c1.73-0.29,4.28,0.08,4.8-2.14C91.88,32.7,90.65,26.05,90.82,19.75  z" style="fill: #B76A26" />
      <path d="M4.33,36.26c0.62,0.04,1.83,0.08,2.43,0.12c-0.26,2.3-0.5,4.62-0.88,6.91l-0.6,0.81L4.7,44.91  C4.51,42.03,4.43,39.14,4.33,36.26z" style="fill: #F8B456" />
  </symbol>
<symbol id="symbol_1C" viewBox="0 0 50 50" size="1x1">
      <path d="M6.6,1.74C16.99,1.02,27.42,0.91,37.84,1.1c2.72,0.25,6.34-0.39,7.86,2.52c1.79,3.44,2.02,7.45,2.71,11.23c0.2,4.83,0.01,9.67,0.02,14.51c-0.29,6.18-0.07,12.7-2.78,18.41c-12.89,1.39-25.9,1.61-38.82,0.56C0.66,34.75,0.58,19.28,2.91,4.81C3.14,3.02,4.85,1.76,6.6,1.74" style="fill: #8C4410" />
      <path d="M4.92,35.61c1.41,0.3,2.81,0.62,4.22,0.96c0.29,2.32,0.6,4.64,0.9,6.97c-0.72,0.24-2.19,0.71-2.93,0.95C6.52,41.49,5.71,38.53,4.92,35.61z" style="fill: #FEBD62" />
      <path d="M9.54,7.93C20.84,6.55,32.29,7.14,43.6,5.86c-0.77,2.62-1.34,5.3-1.82,8.01c-6.11,0.82-12.27,1.13-18.38,1.79c3.56,0.39,7.14,0.55,10.71,0.87c1.42,0.67,2.81,1.41,4.21,2.15c-4.55,7.2-10.29,16.39-20.1,15.5c-4.51,0-9.02-0.4-13.49-0.89c0.94-0.17,2.81-0.5,3.76-0.67C8.58,24.38,8.13,16.1,9.54,7.93z" style="fill: #E29126" />
      <path d="M5.45,3.94c10.8-0.42,21.58-0.72,32.39-0.5c2.02,0.2,4.42-0.1,6,1.5L43.6,5.86C32.29,7.14,20.84,6.55,9.54,7.93c-1.41,8.15-0.96,16.44-1.05,24.68c-0.95,0.17-2.82,0.51-3.76,0.67C3.12,23.54,3.82,13.64,5.45,3.94z" style="fill: #FFBE63" />
      <path d="M34.12,16.53c2.84,0.2,5.63,0.77,8.38,1.51c-0.76,3.63-0.73,7.35-0.53,11.05c0.31,4.04-1.9,7.63-3.46,11.22c-9.52,0.55-19.18,0.88-28.47,3.23c-0.3-2.33-0.61-4.65-0.9-6.97c-1.41-0.34-2.81-0.66-4.22-0.96c4.4-0.73,8.85-1.17,13.3-1.43c9.81,0.89,15.56-8.3,20.1-15.5C36.93,17.94,35.53,17.19,34.12,16.53z" style="fill: #D27F1F" />
      <path d="M43.84,4.94L43.84,4.94c2.72,13.51,2.93,26.79,0.6,40.37c-10.78,1.51-21.7,1.65-32.56,1.15c-1.83,0.08-3.42-0.82-4.77-1.98c0.73-0.24,2.2-0.71,2.93-0.95c9.29-2.36,18.94-2.68,28.47-3.23c1.56-3.58,3.77-7.17,3.46-11.22c-0.21-3.7-0.24-7.42,0.53-11.05c-2.75-0.73-5.54-1.31-8.38-1.51c-3.57-0.31-7.15-0.48-10.71-0.87c6.12-0.67,12.29-0.97,18.38-1.79c0.48-2.71,1.05-5.38,1.82-8.01L43.84,4.94z" style="fill: #B56925" />
  </symbol>
<symbol id="symbol_1H" viewBox="0 0 50 50" size="1x1">
      <path d="M2.35,2.66C7.74,1.72,13.23,1.7,18.68,1.51c9.65-0.01,19.36-0.13,28.95,1.14c0.37,2.98,1.12,6.01,0.35,8.99c0.4,8.66,0.63,17.34,0.09,26.01c0.54,3.41-0.04,6.83-0.66,10.19c-14.85,0.55-29.84,1.45-44.6-0.72C2.2,44,1.56,40.83,2.1,37.66c-0.66-8.45-0.58-16.94-0.19-25.4C1.37,9.05,1.9,5.84,2.35,2.66" style="fill: #492C1D" />
      <path d="M3.8,4.07C10.47,3.03,17.23,3.16,23.96,3c7.48,0.18,14.98,0.08,22.41,1.11c-0.26,0.11-0.78,0.34-1.04,0.45C31.97,4.9,18.59,4.66,5.24,5.37C4.81,7,4.44,8.66,3.78,10.23l-0.53,0.61C3.17,8.57,3.5,6.31,3.8,4.07z" style="fill: #EBB175" />
      <path d="M3.48,11.65c0.35-0.01,1.05-0.02,1.4-0.04C5.21,20.3,5.2,29,5.37,37.69c1.95,0.14,3.89,0.28,5.85,0.29c0.09-0.02,0.28-0.06,0.37-0.09c0.24-0.13,0.73-0.37,0.97-0.49c1.36-0.08,2.73-0.12,4.1-0.12l0.89-0.01c6.86,0.05,13.72,0.38,20.57-0.17c0.6-8.01-0.27-16.04,0.04-24.04c0.19-0.53,0.41-1.05,0.67-1.56c1.33,8.74,1.13,17.67,0.17,26.43c1.95-0.06,3.9-0.17,5.85-0.19c0.58,0.21,2.37-0.09,1.44,0.92c-0.38,0.07-1.13,0.21-1.5,0.28c-12.96,0.63-25.94,0.39-38.91,0.36c-0.14,2.22-0.3,4.44-0.61,6.65c-1.39-0.29-1.26-1.82-1.52-2.9c-0.52-2.77-0.02-5.59-0.27-8.38C2.89,27.01,3.13,19.31,3.48,11.65z" style="fill: #EBB175" />
      <path d="M43.37,11.92c1.01,0.02,2.02,0.06,3.03,0.09c0.46,6.19,0.55,12.39,0.44,18.58c-0.03,2.11-0.32,4.22-0.06,6.33c0.46,3.17-0.31,6.34-0.89,9.44c-5.32,0.27-10.63,0.51-15.95,0.52c-3.64-0.01-7.31,0.42-10.91-0.26c8.29-1.09,16.67-1.25,25-2c0.25-1.89,0.5-3.78,0.75-5.67c0.38-0.07,1.13-0.21,1.5-0.28c0.93-1.01-0.86-0.71-1.44-0.92c-0.02-8.56-0.04-17.11-0.15-25.66C44.36,12.04,43.7,11.96,43.37,11.92z" style="fill: #7F4C25" />
      <path d="M46.37,4.11c0.13,2.12,0.32,4.25,0.58,6.36c-0.69-0.02-1.38-0.04-2.05-0.06c0.11-1.95,0.2-3.91,0.44-5.84C45.59,4.44,46.11,4.22,46.37,4.11z" style="fill: #7F4C25" />
      <path d="M12.56,37.4c-0.6-8.03-0.58-16.48-0.06-24.54h25.65c-0.31,8,0.56,16.53-0.04,24.54H12.56z" style="fill: #8E4E24" />
      <g style="fill: #AF6B33">
          <path d="M16.06,33.57c-2.15-0.81-2.18-3.44-2.25-5.49c0,0,1.38-8.12,3.09-10.15c1.28-1.52,5.23-2.94,7.12-3.56c1.32-0.43,5.56,0.12,5.56,0.12c1.01,0.16,3.06,0.69,3.88,1.31c1.72,1.3,2.05,3.31,2.01,5.45c-0.06,3.58-1.62,11.08-4.01,13.73c-1.42,1.57-4.13,0.88-6.18,0.58C22.95,35.2,18.27,34.4,16.06,33.57z" />
          <path d="M5.24,5.37C18.59,4.66,31.97,4.9,45.33,4.56c-0.24,1.94-0.32,3.89-0.44,5.84C31.2,9.5,17.48,10.23,3.78,10.23C4.44,8.66,4.81,7,5.24,5.37z" />
          <path d="M4.87,11.46c2.12-0.06,4.24-0.11,6.37-0.22c-1.35,8.85-1.1,17.88-0.02,26.75c-1.95-0.01-3.9-0.16-5.85-0.29C5.2,29,5.21,20.3,4.88,11.61L4.87,11.46z" />
          <path d="M38.81,11.51c1.52,0.14,3.04,0.24,4.56,0.41c0.33,0.04,0.99,0.12,1.32,0.17c0.11,8.55,0.12,17.1,0.15,25.66c-1.95,0.03-3.9,0.14-5.85,0.19C39.94,29.18,40.14,20.25,38.81,11.51z" />
          <path d="M5.86,39.31c12.97,0.03,25.95,0.27,38.91-0.36c-0.25,1.89-0.5,3.78-0.75,5.67c-8.33,0.75-16.71,0.91-25,2c-4.6,0.28-9.19-0.28-13.77-0.66C5.56,43.75,5.72,41.53,5.86,39.31z" />
      </g>
      <g style="fill: #492C1D">
          <rect x="16.75" y="12.86" width="1.2" height="24.54" style="fill: #492C1D" />
          <rect x="24.02" y="12.73" width="1.2" height="24.67" style="fill: #492C1D" />
          <rect x="31.65" y="12.73" width="1.2" height="24.67" style="fill: #492C1D" />
      </g>
      <path d="M37.41,21.6l-2.27,11.05l-22.79-4.84l1.68-10.45L37.41,21.6z" style="fill: #E8E5E2" />
      <path d="M21.76,27.31l1.31-1.68l2.81,4.11l1.54-4.02l2.95-1.1l2.29-1.49l2.13-2.01l2.62,0.48l-2.27,11.05l-22.79-4.84l0,0c1.64-0.19,3.4-0.83,5.05-0.88C18.92,26.88,21.76,27.31,21.76,27.31z" style="fill: #D2CDC8" />
      <g style="fill: #D00505">
          <path d="M16.07,21.34c1.37-1.89,4.02-1.08,5.94-0.7c0.65,1.39-1.46,0.67-2.19,1.02c-0.98,1.56-0.87,3.49-1.05,5.26c-0.34-0.01-1-0.01-1.34-0.02c0.27-1.7,0.59-3.39,0.99-5.06C17.62,21.68,16.84,21.51,16.07,21.34z" style="fill: #D00505" />
          <path d="M23.63,20.65c0.85,2.12,1.2,4.39,1.87,6.57c0.5-1.84,0.44-3.8,1.24-5.55c0.83,0.7,0.62,1.83,0.68,2.79c-0.19,1.82-0.64,3.62-1.53,5.25c-1.02-1.31-1.96-2.68-2.81-4.11c-0.09,0.91-0.19,1.83-0.29,2.74c-0.34-0.35-0.68-0.7-1.02-1.06C22.17,25.02,22.6,22.73,23.63,20.65z" style="fill: #D00505" />
          <path d="M27.8,23.98c1.47-0.91,3.23-0.87,4.89-0.87c0.66,0.42,1.22,0.97,1.75,1.54c-0.66-0.09-1.98-0.29-2.64-0.39c-0.69,1.85-0.91,3.82-1.29,5.74c-0.26-0.05-0.78-0.14-1.04-0.18c0.05-1.78,0.53-3.5,0.93-5.22c-0.21,0.05-0.62,0.15-0.83,0.2C29.12,24.58,28.24,24.18,27.8,23.98z" style="fill: #D00505" />
      </g>
  </symbol>
<!-- 将小猪猪设置为 2x2 资源位 -->
<symbol id="symbol_pig" viewBox="0 0 50 50" size="2x2">
        <path d="M7.76,14.25c0,0-3.24-2.27-2.87-4.63c0.37-2.36,1.82-4.2,4.37-4.17c2.56,0.03,4.06,2.13,4.35,3.72c0,0,3.21-2.36,8.38-2.04c0,0-0.47-5.31,4.01-5.21c4.48,0.11,5.32,2.1,4.27,6.19c0,0,16.96,3.55,18.18,19.16c0.33,4.21-1.1,7.75-2.83,10.56C40.94,45.4,30.99,48.15,24.21,48.1c-9.29-0.07-22.17-4.77-22.69-16.12C1.01,20.65,7.76,14.25,7.76,14.25z" style="fill: #aaaaaa" />
        <path d="M8.87,13.96c-1.4-1.04-3-1.77-3.08-3.65C5.72,8.33,7.22,6.77,9.26,6.6c2.72-0.22,3.31,1.25,3.8,3.67c1.18-0.88,2.77-1.43,3.99-1.8c1.89-0.6,3.62-0.77,5.86-0.74c-0.26-2.97,0.13-5.26,3.75-5.01c4.01,0.41,3.58,2.49,2.77,5.75c9.52,2.1,18.3,9.29,18.45,19.95c-0.04,4.7-2.24,8.58-5.04,11.56c-4.36,4.63-10.74,6.84-17.32,7.2c-3.45,0.07-7.88-0.46-11.3-1.56c-5.45-1.76-9.44-5.13-11.21-10.94C1.42,27.7,3.65,19,8.87,13.96z" style="fill: #6DE249" />
        <g style="fill: #000017">
            <path d="M9.65,8.22c1.24,0,2.25,1.02,2.25,2.25s-1.02,2.25-2.25,2.25c-1.24,0-2.25-1.02-2.25-2.25S8.42,8.22,9.65,8.22L9.65,8.22z M26.24,4.2c1.24,0,2.25,1.02,2.25,2.25S27.47,8.7,26.24,8.7s-2.25-1.02-2.25-2.25S25,4.2,26.24,4.2z" />
            <path d="M6.44,22.34c0,0-0.37-4.55,5.26-3.3C11.7,19.05,8.36,19.69,6.44,22.34L6.44,22.34z M38.44,18.39c0,0,4.71-3.23,6.07,2.39C44.52,20.77,42.36,18.31,38.44,18.39z" />
            <path d="M9.31,25.49c2.5,0,4.55,2.19,4.55,4.87c0,2.69-2.04,4.87-4.55,4.87c-2.5,0-4.55-2.19-4.55-4.87C4.76,27.68,6.8,25.49,9.31,25.49z" />
            <path d="M21.56,37.39c0,0-6.37-0.53-7.03-6.28c-0.26-2.29,0.7-4.13,2.04-5.64c2.02-2.27,5.15-3.47,8.17-3.66c5.06-0.32,11.93,2.24,12.33,7.71c0.4,5.47-6.71,7.19-6.71,7.19s-0.87,2.81-4.4,2.84C22.43,39.58,21.93,38.74,21.56,37.39z" />
            <path d="M42.31,23.19c2.53,0,4.6,2.25,4.6,5.03c0,2.77-2.06,5.03-4.6,5.03c-2.54,0-4.6-2.25-4.6-5.03C37.71,25.44,39.77,23.19,42.31,23.19z" />
        </g>
        <path d="M9.32,25.89c2.27,0,4.12,1.84,4.12,4.1s-1.85,4.1-4.12,4.1c-2.28,0-4.12-1.84-4.12-4.1S7.04,25.89,9.32,25.89z" style="fill: #FFFFFF" />
        <path d="M42.31,23.6c2.32,0,4.22,1.92,4.22,4.28c0,2.35-1.9,4.28-4.22,4.28c-2.32,0-4.22-1.92-4.22-4.28C38.08,25.52,39.98,23.6,42.31,23.6z" style="fill: #FFFFFF" />
        <path d="M14.93,30.74c0,0-0.12-0.95,0.4-2.3c0.86-2.19,3.19-5.29,8.75-5.94c3.93-0.46,6.85,0.49,8.84,1.76c2.57,1.62,3.66,3.89,3.62,5.77c-0.06,3.34-4.58,6.6-10.83,6.85C19.48,37.12,14.93,35.51,14.93,30.74z" style="fill: #A5E900" />
        <path d="M22.32,37.5c0,0,4.75,0.24,7.1-0.49c0,0-1.19,2-3.66,2C23.29,39,22.76,38.5,22.32,37.5z" style="fill: #72A600" />
        <g style="fill: #231815">
            <path d="M22.3,26.96c1.28,0,2.31,1.25,2.31,2.77c0,1.53-1.04,2.77-2.31,2.77s-2.31-1.25-2.31-2.77C19.99,28.2,21.04,26.96,22.3,26.96L22.3,26.96z" />
            <path d="M29.58,27.03c1.28,0,2.31,1.07,2.31,2.39c0,1.31-1.04,2.39-2.31,2.39s-2.31-1.07-2.31-2.39C27.27,28.11,28.31,27.03,29.58,27.03z" />
            <path d="M43.83,26.65c0.66,0,1.21,0.56,1.21,1.23s-0.55,1.23-1.21,1.23s-1.21-0.56-1.21-1.23S43.16,26.65,43.83,26.65z" />
            <circle cx="8.65" cy="29.64" r="1.25" />
        </g>
</symbol>
<symbol id="symbol_1E" viewBox="0 0 50 100" size="1x2" type="pre" count="-1">
      <path d="M48.53,28c0.75,19.29,0.22,38.59,0.01,57.91c0.11,3.85-0.91,7.58-2.09,11.21  c-6.59,0.33-13.15,1.52-19.76,1.27c-8.49-0.3-17.06,0.82-25.45-0.75c-0.23-31.65-0.55-63.37,2-94.95  c14.4-1.65,28.95-1.41,43.38-0.33C49.26,10.63,48.15,19.44,48.53,28" style="fill: #8C4410" />
      <path d="M45.32,4.63c1.06,9.74,0.47,19.56,1,29.32c0.01,7.39,0.8,14.78,0.08,22.16c-0.66,6.8-0.36,13.63-0.7,20.44  c-0.79-0.82-1.6-1.64-2.39-2.45c0.27-17.7-0.75-35.39-1.07-53.08c-0.23-5.09,0.94-11.03-3.18-14.95c-0.29-0.36-0.86-1.1-1.16-1.47  C40.38,4.57,42.85,4.56,45.32,4.63z" style="fill: #FFBE63" />
      <path d="M46.4,56.11c0.41,9.92,0.05,19.86-0.1,29.78c0,3.22-0.87,6.34-1.85,9.37c-1.21-0.46-2.42-0.93-3.63-1.4  c0.75-5.9,1.82-11.74,2.37-17.64c0.04-0.54,0.1-1.61,0.13-2.14c0.8,0.81,1.61,1.63,2.39,2.45C46.04,69.74,45.74,62.9,46.4,56.11z" style="fill: #E9A14C" />
      <path d="M42.25,21.02c-0.22-5.1,0.95-11.03-3.18-14.94c-1.68,11.09-0.8,22.39-0.79,33.56l-0.75-0.07  c0.2-3.77,0.32-7.55-0.28-11.28c-1.16-7.01-0.84-14.15-0.97-21.21C31.13,7.2,25.93,7.44,20.79,6.85c-1.9,0.08-3.13-1.36-4.54-2.36  c-0.25,9.37-0.72,18.72-0.39,28.09l-0.67-0.11c0.27-8.6-1.6-17.1-1.56-25.7c-2.31-0.25-4.62-0.49-6.91-0.88  c1.77,8.06,0.7,16.37,0.82,24.56c0.12,10.58-0.84,21.19,0.4,31.72c3.23,2.25,6.29,4.76,9.59,6.91c0.54,0.35,1.09,0.67,1.65,0.97  c-0.57-0.3-1.12-0.62-1.67-0.97c-3.3-2.16-6.36-4.67-9.59-6.91c0.9,7.5,0.9,15.09,1.2,22.62c0.3,1.73-0.07,4.28,2.14,4.8  c6.05,2.28,12.69,1.05,18.99,1.22c-0.19-5.47,0.38-10.94,1.04-16.36c0,0,0,0,0,0c0.19-3.16,0.31-6.31,0.39-9.46l0.65-0.04  c0.07,3.37,0.18,6.75,0.39,10.11c0.33,0.03,0.65,0.07,0.98,0.1c-0.32-0.03-0.64-0.06-0.97-0.09c-0.27,5.34-0.33,10.71,0.48,16.02  c2.58,0.82,5.11,1.77,7.62,2.77c0.74-5.89,1.81-11.73,2.36-17.63c0,0-0.01,0-0.01,0c0.03-0.54,0.09-1.61,0.13-2.14  C43.58,56.39,42.55,38.7,42.25,21.02z" style="fill: #D27F1F" />
      <path d="M35.84,4.5c0.11,0.64,0.31,1.92,0.42,2.56c-5.15,0.13-10.35,0.36-15.49-0.23c-1.89,0.08-3.12-1.36-4.54-2.36  C22.74,3.81,29.38,3.51,35.84,4.5z" style="fill: #FEBC61" />
      <path d="M30.25,90.82c-0.5,1.71-0.01,4.58-2.59,4.5c-8.07,0.33-16.16,0.94-24.25,0.95c0-14.86,0.38-29.76-0.33-44.61  c-0.13-8.27,1.32-16.47,1.4-24.75C4.78,19.7,3.74,12.3,5.91,5.28l0.81,0.6c1.78,8.07,0.71,16.37,0.82,24.56  c0.12,10.57-0.85,21.18,0.39,31.71c0.88,7.5,0.88,15.08,1.2,22.62c0.29,1.73-0.08,4.28,2.14,4.8C17.3,91.88,23.95,90.65,30.25,90.82  z" style="fill: #B76A26" />
      <path d="M13.74,4.33c-0.04,0.62-0.08,1.83-0.12,2.43C11.32,6.5,9,6.26,6.71,5.88L5.9,5.28L5.09,4.7  C7.97,4.51,10.86,4.43,13.74,4.33z" style="fill: #F8B456" />
</symbol>

  <symbol id="logo" viewBox="0 0 128 128" type="logo">
      <path
          d="M0 0 C-11.91748629 60.04956663 -132.41278585 73.45579157 -152.74511719 12.375 C-197.07840594 -147.5180797 26.35203916 -161.75468891 0 0 Z "
          transform="translate(141.8310546875,94.8125)" style="fill: #FFFFFF;"/>
      <path
          d="M0 0 C-11.91748629 60.04956663 -132.41278585 73.45579157 -152.74511719 12.375 C-197.07840594 -147.5180797 26.35203916 -161.75468891 0 0 Z M-116.83105469 -70.8125 C-118.81105469 -69.8225 -118.81105469 -69.8225 -120.83105469 -68.8125 C-122.92107171 -65.57258216 -122.92107171 -65.57258216 -124.83105469 -61.8125 C-127.26979437 -57.3160737 -129.15680638 -54.48674831 -132.83105469 -50.8125 C-133.58575313 -47.83342721 -134.26206015 -44.83254796 -134.83105469 -41.8125 C-135.32605469 -41.3175 -135.32605469 -41.3175 -135.83105469 -40.8125 C-135.93076603 -37.12611288 -135.96073752 -33.43773242 -135.95605469 -29.75 C-135.95863281 -27.71714844 -135.96121094 -25.68429688 -135.96386719 -23.58984375 C-136.62295465 -18.6458977 -136.62295465 -18.6458977 -134.83105469 -18.8125 C-134.39792969 -16.811875 -133.96480469 -14.81125 -133.51855469 -12.75 C-131.98190104 -3.83058473 -131.98190104 -3.83058473 -125.83105469 1.1875 C-124.84105469 4.6525 -124.84105469 4.6525 -123.83105469 8.1875 C-120.30245921 12.65890452 -120.30245921 12.65890452 -115.83105469 12.1875 C-115.50105469 13.8375 -115.17105469 15.4875 -114.83105469 17.1875 C-108.35006416 22.06644792 -102.83923638 25.74340166 -94.83105469 27.1875 C-92.81238281 27.93773438 -92.81238281 27.93773438 -90.75292969 28.703125 C-85.366157 30.32770724 -80.88546444 30.62091497 -75.26855469 30.625 C-72.60599609 30.65400391 -72.60599609 30.65400391 -69.88964844 30.68359375 C-64.55656976 30.1605814 -61.43837072 28.82797888 -56.83105469 26.1875 C-55.18105469 25.5275 -53.53105469 24.8675 -51.83105469 24.1875 C-37.77085273 16.03254449 -37.77085273 16.03254449 -29.83105469 3.1875 C-29.17105469 3.1875 -28.51105469 3.1875 -27.83105469 3.1875 C-26.75651268 0.5499878 -25.77512722 -2.12552434 -24.83105469 -4.8125 C-24.12980469 -6.524375 -23.42855469 -8.23625 -22.70605469 -10 C-20.13458384 -16.60010851 -19.67109922 -22.16915291 -19.64355469 -29.1875 C-19.629375 -30.82460938 -19.61519531 -32.46171875 -19.60058594 -34.1484375 C-20.11940661 -44.64796102 -24.36419616 -56.34564148 -31.83105469 -63.8125 C-32.82105469 -65.7925 -33.81105469 -67.7725 -34.83105469 -69.8125 C-43.98672996 -78.78156843 -43.98672996 -78.78156843 -55.83105469 -81.8125 C-56.82105469 -83.7925 -56.82105469 -83.7925 -57.83105469 -85.8125 C-64.41388262 -86.75290399 -70.56465862 -87.01489143 -77.20605469 -87.0625 C-79.35878906 -87.08828125 -81.51152344 -87.1140625 -83.72949219 -87.140625 C-91.32121706 -86.73236323 -116.83105469 -80.41832587 -116.83105469 -70.8125 Z "
          transform="translate(141.8310546875,94.8125)" style="fill: #FFFFFF;"/>
      <path
          d="M0 0 C0.33 -0.33 0.66 -0.66 1 -1 C7.1879402 -0.9254465 18 -0.64792373 18 8 C18.66 8 19.32 8 20 8 C20 16 20 16 15 17 C13.95650161 24.2236068 13.95650161 24.2236068 19 26 C20.64477784 27.64477784 25.62024371 33 20 33 C20 33.99 20 34.98 20 36 C18.35 37.65 16.7 39.3 15 41 C12.05719096 45.70710678 12.05719096 45.70710678 16 44 C15.67 45.32 15.34 46.64 15 48 C15.99 48.33 16.98 48.66 18 49 C17 52 17 52 10 52 C10 52.66 10 53.32 10 54 C8.35 54 6.7 54 5 54 C5 55.98 5 57.96 5 60 C4.67 60.66 4.34 61.32 4 62 C5.98 60.68 7.96 59.36 10 58 C12.72832091 60.72832091 12.21033613 66 8 66 C7.66666667 68.33333333 7.66666667 68.33333333 10 68 C11.79264592 75.17058367 6.45474303 75.22737152 0 72 C-0.33 70.35 -0.66 68.7 -1 67 C-8.01594702 64.53884276 -8.01594702 64.53884276 -9 71 C-13.81488674 75.81488674 -18 74.9571358 -18 68 C-16.02 67.01 -16.02 67.01 -14 66 C-12.15672596 62.0513167 -12.15672596 62.0513167 -19 63 C-18.74699685 58.99411676 -18.41161891 54.99270347 -18 51 C-19.32 50.67 -20.64 50.34 -22 50 C-22 49.34 -22 48.68 -22 48 C-23.485 47.505 -23.485 47.505 -25 47 C-25 46.34 -25 45.68 -25 45 C-27.31 45 -29.62 45 -32 45 C-32 44.34 -32 43.68 -32 43 C-32.99 42.67 -33.98 42.34 -35 42 C-35 36 -35 36 -32 32 C-31.95385863 24.60555325 -31.95385863 24.60555325 -37 24 C-44.06317662 16.93682338 -36.34281148 9.17140574 -30 6 C-29.67 5.34 -29.34 4.68 -29 4 C-27.35 4.33 -25.7 4.66 -24 5 C-23.56298279 1.67866922 -23.23867466 -1.65855471 -23 -5 C-14.95824804 -13.04175196 -3.52078289 -10.56234868 0 0 Z "
          transform="translate(70,32)" style="fill: #52514F;"/>
      <path
          d="M0 0 C2.57039063 -0.01675781 5.14078125 -0.03351562 7.7890625 -0.05078125 C19.375 0.58830071 19.375 0.58830071 19.375 5.3125 C21.685 5.6425 23.995 5.9725 26.375 6.3125 C30.375 9 30.375 9 34.375 12.3125 C36.23125 13.735625 36.23125 13.735625 38.125 15.1875 C41.69079777 18.6161517 43.33184666 21.8478316 45.375 26.3125 C46.035 26.6425 46.695 26.9725 47.375 27.3125 C59.11858845 46.88514741 57.03447886 67.10704933 48.375 87.3125 C47.88 88.7975 47.88 88.7975 47.375 90.3125 C46.715 90.3125 46.055 90.3125 45.375 90.3125 C44.715 92.2925 44.055 94.2725 43.375 96.3125 C25.66958919 114.01791081 2.37569703 124.33984729 -21.625 113.3125 C-23.935 112.6525 -26.245 111.9925 -28.625 111.3125 C-39.44514388 105.21178058 -39.44514388 105.21178058 -40.625 99.3125 C-42.275 98.9825 -43.925 98.6525 -45.625 98.3125 C-49.625 93.3125 -49.625 93.3125 -50.625 88.3125 C-51.285 88.3125 -51.945 88.3125 -52.625 88.3125 C-56.39697403 81.71154545 -58.34519098 75.77805264 -59.625 68.3125 C-59.955 68.3125 -60.285 68.3125 -60.625 68.3125 C-60.75421393 64.77263944 -60.80101427 61.22969947 -60.8125 57.6875 C-60.82667969 55.71523438 -60.84085938 53.74296875 -60.85546875 51.7109375 C-60.54411851 44.41795396 -58.87184749 37.55934749 -53.625 32.3125 C-51.62201478 28.64746321 -49.62214373 24.98072319 -47.625 21.3125 C-43.625 16.3125 -43.625 16.3125 -41.625 16.3125 C-41.625 15.6525 -41.625 14.9925 -41.625 14.3125 C-28.96723412 3.60208272 -16.3122882 0.02459139 0 0 Z M-24.125 11.3125 C-27.625 13.3125 -27.625 13.3125 -30.625 12.3125 C-32.99036695 14.95079391 -35.3189976 17.62216387 -37.625 20.3125 C-39.95833333 21.97916667 -42.29166667 23.64583333 -44.625 25.3125 C-44.625 26.3025 -44.625 27.2925 -44.625 28.3125 C-45.285 28.3125 -45.945 28.3125 -46.625 28.3125 C-47.79166667 35.8125 -47.79166667 35.8125 -43.625 35.3125 C-44.40875 36.715 -45.1925 38.1175 -46 39.5625 C-49.65323682 46.173119 -51.15850228 50.94898257 -52.1875 58.4375 C-53.52777778 68.11805556 -53.52777778 68.11805556 -54.625 70.3125 C-39.6381516 127.00188307 33.20000942 119.32203139 50.375 69.3125 C54.75198232 47.42758842 46.11948298 9.90771605 18.375 11.3125 C16.725 10.9825 15.075 10.6525 13.375 10.3125 C8.07881068 9.42980178 3.34848177 9.14653173 -2 9.125 C-3.61648437 9.11082031 -5.23296875 9.09664062 -6.8984375 9.08203125 C-10.95769769 8.71079525 -10.95769769 8.71079525 -10.625 11.3125 C-17.91096572 9.46459923 -17.91096572 9.46459923 -24.125 11.3125 Z "
          transform="translate(66.625,7.6875)" style="fill: #DEDEDE;"/>
      <path
          d="M0 0 C0 0.99 0 1.98 0 3 C0.66 3 1.32 3 2 3 C10.22034933 19.44069866 5.91429357 36.86664834 -1 53 C-1.33 53.99 -1.66 54.98 -2 56 C-2.66 56 -3.32 56 -4 56 C-4.99 58.97 -4.99 58.97 -6 62 C-23.70541081 79.70541081 -46.99930297 90.02734729 -71 79 C-73.31 78.34 -75.62 77.68 -78 77 C-88.82014388 70.89928058 -88.82014388 70.89928058 -90 65 C-91.65 64.67 -93.3 64.34 -95 64 C-99 59 -99 59 -100 54 C-100.66 54 -101.32 54 -102 54 C-103.29021026 49.88745479 -113.95288971 11 -106 11 C-105.8624606 13.89444024 -105.76689048 16.79088153 -105.6875 19.6875 C-103.59537402 63.62214555 -56.56422286 93.21661778 -19 64 C-17.80375 63.0925 -16.6075 62.185 -15.375 61.25 C0.5190736 45.94459579 5.48810946 22.59230103 -2 2 C-2 -2 -2 -2 0 0 Z "
          transform="translate(116,42)" style="fill: #D1D1D1;"/>
      <path
          d="M0 0 C0.33 -0.33 0.66 -0.66 1 -1 C12 -0.25842697 12 -0.25842697 12 1 C10.02 1 8.04 1 6 1 C6.495 1.99 6.495 1.99 7 3 C8.27084765 17.82655596 -3.6531799 18.27959921 -15.75 18.375 C-18.21726562 18.41753906 -18.21726562 18.41753906 -20.734375 18.4609375 C-28.01173316 17.67455631 -32.49922861 10.99845722 -29 4 C-27.35 4.33 -25.7 4.66 -24 5 C-23.56298279 1.67866922 -23.23867466 -1.65855471 -23 -5 C-14.95824804 -13.04175196 -3.52078289 -10.56234868 0 0 Z "
          transform="translate(70,32)" style="fill: #E6AC68;"/>
      <path
          d="M0 0 C-2 3 -2 3 -6.125 4 C-10.48413866 4.4579469 -10.48413866 4.4579469 -10 8 C-8.515 7.71125 -7.03 7.4225 -5.5 7.125 C1.51414897 6.93016253 0.13347896 10.08971683 -1 16 C-2.65 16 -4.3 16 -6 16 C-6 17.98 -6 19.96 -6 22 C-6.33 22.66 -6.66 23.32 -7 24 C-5.02 22.68 -3.04 21.36 -1 20 C1.72832091 22.72832091 1.21033613 28 -3 28 C-3.33333333 30.33333333 -3.33333333 30.33333333 -1 30 C0.79264592 37.17058367 -4.54525697 37.22737152 -11 34 C-11.33 32.35 -11.66 30.7 -12 29 C-17.295236 27.21010022 -17.295236 27.21010022 -21 30 C-21 27 -21 27 -16 26 C-17.32 25.67 -18.64 25.34 -20 25 C-22 22 -22 22 -22 19 C-22.99 18.67 -23.98 18.34 -25 18 C-23.46740186 11.86960744 -20.63698148 13.35577355 -15 14 C-15.33 15.32 -15.66 16.64 -16 18 C-9.86702806 18 -14.18035443 13.37293671 -17 11.875 C-18.32 11.25625 -19.64 10.6375 -21 10 C-20 8 -20 8 -13 8 C-11.48534976 2.53915739 -11.48534976 2.53915739 -13 0 C-13 -12.48649291 0 -12.07922721 0 0 Z "
          transform="translate(81,70)" style="fill: #5E5E5E;"/>
      <path
          d="M0 0 C0 0.99 0 1.98 0 3 C0.66 3 1.32 3 2 3 C3.46323411 8.85293645 7.83550467 45 -1 45 C-1.20625 46.340625 -1.4125 47.68125 -1.625 49.0625 C-3.34102021 55.22457257 -6.0831973 57.08192285 -11 61 C-11.99 62.98 -11.99 62.98 -13 65 C-13.66 65 -14.32 65 -15 65 C-15.495 66.485 -15.495 66.485 -16 68 C-16.66 68 -17.32 68 -18 68 C-18 68.66 -18 69.32 -18 70 C-25.29411765 74 -25.29411765 74 -28 74 C-28 74.66 -28 75.32 -28 76 C-42.0752658 80.35662989 -96 81.43384744 -96 56 C-92 58 -92 58 -87.6875 61.875 C-68.24383878 78.98542187 -39.4704894 79.92149176 -19 64 C-17.80375 63.0925 -16.6075 62.185 -15.375 61.25 C0.5190736 45.94459579 5.48810946 22.59230103 -2 2 C-2 -2 -2 -2 0 0 Z "
          transform="translate(116,42)" style="fill: #959595;"/>
      <path
          d="M0 0 C1.65 0.33 3.3 0.66 5 1 C5 5 5 5 -2 5 C1.27796366 8.27796366 3.21151769 8.20191961 8 9 C7.01 9.33 6.02 9.66 5 10 C4.67 11.65 4.34 13.3 4 15 C1 14 1 14 2 11 C-6.14702468 8.58135205 -6.75714178 10.15143336 -5 18 C-6 20 -6 20 -11 20 C-9.68 19.34 -8.36 18.68 -7 18 C-8.15834953 13.35824452 -8.15834953 13.35824452 -10 9 C-9.34 9 -8.68 9 -8 9 C-8.33 8.01 -8.66 7.02 -9 6 C-8.01 4.35 -7.02 2.7 -6 1 C-5.34 -0.65 -4.68 -2.3 -4 -4 C0.42011297 -6.21005649 0 -5.39040718 0 0 Z "
          transform="translate(63,74)" style="fill: #494949;"/>
      <path d="M0 0 C-8.0619463 8.0619463 -13 1.80310411 -13 -7 C-4.27283844 -13.54537117 0 -9.18631582 0 0 Z "
            transform="translate(59,74)" style="fill: #D0D0D0;"/>
      <path d="M0 0 C-6.19742061 9.29613092 -13 2.30741332 -13 -6 C-6.13427144 -12.86572856 0 -8.59694961 0 0 Z "
            transform="translate(81,70)" style="fill: #FFFFFF;"/>
      <path
          d="M0 0 C1.82503648 15.61420096 -11.01859282 13.6818687 -23 13 C-27.5 4 -27.5 4 -23 4 C-23 5.65 -23 7.3 -23 9 C-11.55256017 10.34897976 -11.55256017 10.34897976 -4 6 C-3.34 6 -2.68 6 -2 6 C-2 0 -2 0 0 0 Z "
          transform="translate(71,35)" style="fill: #BA5929;"/>
      <path
          d="M0 0 C5.22871699 1.53087334 9.50605012 1.74313879 14.94140625 1.66015625 C17.48214844 1.63695313 17.48214844 1.63695313 20.07421875 1.61328125 C25.21069947 1.47159953 25.21069947 1.47159953 31.81640625 0.41015625 C26.32999307 5.89656943 -10.18359375 6.29517622 -10.18359375 -2.58984375 C-11.17359375 -2.91984375 -12.16359375 -3.24984375 -13.18359375 -3.58984375 C-13.18359375 -5.43641432 -2.07372011 -0.78805237 0 0 Z "
          transform="translate(50.18359375,118.58984375)" style="fill: #BDBDBD;"/>
      <path
          d="M0 0 C-0.99 0.66 -1.98 1.32 -3 2 C-3.33 2.99 -3.66 3.98 -4 5 C-15.17311755 2.20672061 -5.77266024 -11.54532048 0 0 Z "
          transform="translate(79,67)" style="fill: #8B8B8B;"/>
      <path
          d="M0 0 C0.99 0.33 1.98 0.66 3 1 C4.38999538 6.55998151 -0.00125081 10.99874919 -6 5 C-6 0 -6 0 -4 2 C-3.12031007 -1.5187597 -2.14744919 -4.29489838 0 0 Z "
          transform="translate(77,99)" style="fill: #434343;"/>
      <path
          d="M0 0 C-12 0 -12 0 -12 -5 C-6 -5 -6 -5 -5 -2 C-2.39366094 -1.67661917 -2.39366094 -1.67661917 -2 -6 C4.76067757 -7.69016939 3.72366511 -3.72366511 0 0 Z "
          transform="translate(70,90)" style="fill: #909CA3;"/>
      <path
          d="M0 0 C-3 3 -3 3 -6 0 C-5.01 -1.32 -4.02 -2.64 -3 -4 C-4 -6.5 -4 -6.5 -8 -8 C-0.98371506 -10.33876165 0 -6.01124205 0 0 Z "
          transform="translate(81,70)" style="fill: #F6F6F6;"/>
      <path
          d="M0 0 C5 1 5 1 6 4 C5.34 4 4.68 4 4 4 C4 4.99 4 5.98 4 7 C3.34 7 2.68 7 2 7 C2 7.66 2 8.32 2 9 C-2 9 -2 9 -3 3 C-2.67 3.66 -2.34 4.32 -2 5 C2.66666667 5.66666667 2.66666667 5.66666667 2 1 C1.34 0.67 0.68 0.34 0 0 Z "
          transform="translate(51,66)" style="fill: #313131;"/>
      <path d="M0 0 C0 4 0 4 -7 4 C-9.12492755 -2.37478266 -6.50304687 -0.9290067 0 0 Z " transform="translate(68,75)"
            style="fill: #262626;"/>
      <path
          d="M0 0 C-0.99 0.33 -1.98 0.66 -3 1 C-3.33 2.65 -3.66 4.3 -4 6 C-7 5 -7 5 -6 2 C-8.31 1.67 -10.62 1.34 -13 1 C-8.08263942 -1.45868029 -5.33783649 -0.78497596 0 0 Z "
          transform="translate(71,83)" style="fill: #263039;"/>
      <path
          d="M0 0 C-0.99 0.66 -1.98 1.32 -3 2 C-3.33 2.99 -3.66 3.98 -4 5 C-8 4 -8 4 -9 0 C-6.525 0.495 -6.525 0.495 -4 1 C-3.67 0.01 -3.34 -0.98 -3 -2 C-2 -3 -2 -3 0 0 Z "
          transform="translate(79,67)" style="fill: #282828;"/>
      <path
          d="M0 0 C-0.99 0.495 -0.99 0.495 -2 1 C-2.33 2.32 -2.66 3.64 -3 5 C-3 4.01 -3 3.02 -3 2 C-4.65 2 -6.3 2 -8 2 C-6 -3 -6 -3 0 0 Z "
          transform="translate(87,48)" style="fill: #7E7F7E;"/>
      <path
          d="M0 0 C1.65 0.33 3.3 0.66 5 1 C5 2 5 2 0 1.875 C-5.49984382 1.17890239 -5.49984382 1.17890239 -5 5 C-7 5 -7 5 -7 1 C-5.35 0.67 -3.7 0.34 -2 0 C-2 -2 -2 -2 0 0 Z "
          transform="translate(65,95)" style="fill: #383837;"/>
      <path d="M0 0 C0 2 0 2 -2 2 C-2.33 3.65 -2.66 5.3 -3 7 C-7 3 -7 3 -5 3 C-4 -1 -4 -1 0 0 Z "
            transform="translate(42,52)" style="fill: #838380;"/>
      <path d="M0 0 C-3.9375 1.1875 -3.9375 1.1875 -8 2 C-6.8799542 -3.60022901 -2.2799859 -6.83995769 0 0 Z "
            transform="translate(55,57)" style="fill: #14110F;"/>
      <path
          d="M0 0 C0 0.66 0 1.32 0 2 C0.99 2.33 1.98 2.66 3 3 C5 10 5 10 2 8 C2 7.01 2 6.02 2 5 C0.68 4.34 -0.64 3.68 -2 3 C-3 -1 -3 -1 0 0 Z "
          transform="translate(112,30)" style="fill: #E0E0E0;"/>
      <path d="M0 0 C-6.66666667 6.66666667 -6.66666667 6.66666667 -5 0 C-1 -4 -1 -4 0 0 Z "
            transform="translate(110,102)" style="fill: #B7B7B7;"/>
      <path
          d="M0 0 C-2 -1 -2 -1 -2 -4 C-2.66 -4.33 -3.32 -4.66 -4 -5 C1.69658179 -10.69658179 0.92805376 -6.49637635 0 0 Z "
          transform="translate(80,98)" style="fill: #767777;"/>
      <path
          d="M0 0 C0 1.65 0 3.3 0 5 C0.66 5 1.32 5 2 5 C2 9.06950087 -3.14989571 6.4453288 -6 6 C-5 4 -5 4 -2 3 C-1 0 -1 0 0 0 Z "
          transform="translate(58,95)" style="fill: #727272;"/>
      <path d="M0 0 C-4 0 -4 0 -5 -3 C-1.28796139 -6.71203861 0 -4.50824632 0 0 Z " transform="translate(53,71)"
            style="fill: #FFFFFF;"/>
      <path d="M0 0 C0 2 0 2 -8 2 C-7 -1 -7 -1 0 0 Z " transform="translate(76,52)" style="fill: #08090C;"/>
  </symbol>

模板资源文件定义说明

一级标签支持支持两种:

  • <defs>: 等同于svg标准的defs标签用法,其中定义一些svg形状,供其他<symbol>标签通过<use>方式进行引用
    • 注意,一个模板文件中,只能有一个<defs>标签,请教所有共用的形状定义放在一起
  • <symbol>: 定义最终输出二维码图片的资源信息,如上面提到的二维码信息点,探测图形,logo,都是放在symbol标签中

1.2 symbol标签属性说明

通常而言,一个symbol标签会包含以下几个属性

属性名 实例 是否必须 属性类型 说明
id logo svg属性 标签的唯一id
viwBox “0 0 128 128” svg属性 svg的视窗
width 50 svg属性 定义资源占用的宽度
height 50 svg属性 定义资源占用的高度
size 1x1,2x2 模板自有属性 定义这个资源,在最终二维码中可以占据的位置,如1个黑色点,2x2的黑色点)
count -1 模板自有属性 定义这个资源在最终二维码中最多出现次数,-1表示无次数限制;>0则表示为次数上限
miss 1-1,2-2 模板自有属性 定义这个资源未能覆盖的区域
type pre,bg,logo,detect,detect_lt,detect_ld,detect_rt 模板自有属性 不存在时默认值为pre,用于定义这个资源类型

其中size,count,miss三个属性的设置实际上对应的是二维码配置参数中的三个同名配置

size说明

默认情况下我们会认为一个资源文件的对应的就是一个黑色/白色小方块,此时size = 1x1,取值规则为 “size=宽x高”

当我们希望一个资源文件是一个宽100,高50时,此时希望它对应一个横向连着的两个小方块,此时则需要显示设置 size = 2x1

同样的一个等宽高的资源文件,除了对应1x1的区域之外,还可以对应2x2, 3x3的区域,即一个资源文件可以对应多个size,此时size的取值可以是 size=1x1,2x2,3x3

count

当我们希望控制一个资源最多出现的次数时,则可以使用这个属性,默认值为-1,表示不限制次数

miss

默认的情况下,我们认为一个资源内容是将 size 对应的区域完全填充的,不留空白的,但是某些特殊的场景下我们并不是这么希望的,比如我现在有一个十字架结构的资源,它对应的区域为3x3,但是它会有四个明显的空白区域:左上,左下,右上,右下

此时我们可以通过设置miss属性来定义这个资源文件中,空白的坐标点

如上面距离的十字架,对应的miss=0-0,0-2,2-0,2-2

  • 英文逗号分隔
  • x-x表示空白地方的坐标点

1.3 使用实例

接下来看一下一个最简单的资源模板使用实例

/**
 * 通过svg 模板的方式来生成 svg二维码
 *
 * @throws Exception
 */
@Test
public void svgTemplate() throws Exception {
    // 第一步,读取模板内容
    String svgTemplate = FileReadUtil.readAll("svg/愤怒小猪svg.template");
    // 输出svg格式的二维码,这里除了指定模板文件之外,还设置了二维码默认的大小500
    String msg = "http://weixin.qq.com/r/FS9waAPEg178rUcL93oH";
    boolean ans = QrCodeGenV3.of(msg).setW(500).setSvgTemplate(svgTemplate).build()
            .asFile("./愤怒的小猪.svg");
    System.out.println(ans);
}

最终生成的二维码如

愤怒的小猪

2. img模板

主要应用于使用图片资源来渲染二维码的场景;对于普通几何图形、颜色自定义等场景,请不要使用模板方式

模板格式说明,json格式;主要分四块资源配置

  • draw: 二维码0/1点对应的资源
  • detect: 探测图形对应的资源
  • logo: logo对应的配置信息
  • bg: 背景图资源参数
  • ft: 前置图资源参数

同样以一个真实的资源实例进行说明

点击展开 【花草二维码】
{
    "bg": {
        "img": "http://cdn.hhui.top/quick/quick-media/leaf/bg.jpg",
        "bgH": 1850,
        "bgStyle": "OVERRIDE",
        "bgW": 1080,
        "startX": 140,
        "startY": 140
    },
    "draw": {
        "drawStyle": "IMAGE",
        "imgs": [
            {
                "count": -1,
                "img": [
                    "http://cdn.hhui.top/quick/quick-media/leaf/11.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/12.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/13.png"
                ],
                "size": "1x1"
            },
            {
                "count": -1,
                "img": [
                    "http://cdn.hhui.top/quick/quick-media/leaf/23.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/22.png"
                ],
                "size": "2x1"
            },
            {
                "img": [
                    "http://cdn.hhui.top/quick/quick-media/leaf/31.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/32.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/33.png"
                ],
                "size": "1x2"
            },
            {
                "img": [
                    "http://cdn.hhui.top/quick/quick-media/leaf/41.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/42.png",
                    "http://cdn.hhui.top/quick/quick-media/leaf/43.png"
                ],
                "miss": "1-0",
                "size": "2x2"
            }
        ],
        "picStyle": "NORMAL",
        "transparencyBgFill": true
    },

    "logo": {
        "borderColor": "0xFFF7EED6",
        "img": "http://cdn.hhui.top/quick/quick-media/leaf/logo.jpg",
        "picStyle": "ROUND",
        "rate": 16
    },
    "detect": {
        "img": "leaf/eye.png"
    },
    "ft": {
        "ftW": 900,
        "ftH": 840,
        "img": "http://cdn.hhui.top/quick/quick-media/leaf/ft_1.png",
        "startX": -160,
        "startY": -528
    }
}

2.1 模板配置说明

图片模板,要求是标准的json格式文件(后续考虑兼容yaml格式);区别于svg模板,它还可以设置背景图、前置图,下面对不同模块进行分别说明

2.1.1 二维码信息点

即二维码中的黑白方块,其配置信息放在 draw 下面

配置参数

// 二维码中1点对应的颜色(即普通二维码黑色区域,可以指定替换为其他的颜色)
private String preColor;
// 二维码中0点对应的颜色(即普通二维码白色区域,可以指定替换为其他的颜色)
private String bgColor;
// 绘制方式,默认为IMAGE
private DrawStyle drawStyle;
/**
 * 图片透明处填充,true则表示透明处用bgColor填充; false则透明处依旧透明
 */
private Boolean transparencyBgFill = true;

/**
 * 最终生成二维码的样式,可以是圆,可以是圆角,默认为普通的正方形
 */
private PicStyle picStyle;

/**
 * 最终生成二维码,如果时圆角,则这个参数用于控制圆角的弧度,默认为 1 / 8
 */
private Float cornerRadius;
// 这个对应的是图片资源
private List<DrawImgTemplate> imgs;

图片资源是一个数组,其内的配置项与svg的差不多

// 图片资源的路径,可以是本地路径,也可以是网络路径
public List<String> img;
public String size;
public String miss;
public Integer count;

2.2.2 探测图形(码眼)

探测图形有三个,通常有两种方式,若三个码眼长一样,则直接设置img值即可;若不一样,则分别设置lt, ld, rt

// 一个探测图形时使用
private String img;
// 左上
private String ltImg;
// 左下
private String ldImg;
// 右上
private String rtImg;

对于logo的配置基本上就和直接设置logo参数一样,模板中自定义的几个属性如下

// logo图片
public String img;
// logo图片的处理,可以圆角、圆形
public PicStyle picStyle;
// 如果希望给logo加边框,就设置这个颜色
public String borderColor;
// 两层边框的场景,用于设置外层边框颜色
public String outerBorderColor;
// 二维码 / logo 的大小,值越大,则logo越小
public Integer rate;
// 设置logo的透明度,默认为1
public Float opacity;
// true则将logo覆盖的二维码信息都清除掉,主要是为了美观,避免出现一部份被二维码覆盖,一部分没有
public Boolean clearLogoArea;

2.2.4 bg背景图

背景图设置,具体参数同样可以参考背景图的参数含义

public String img; 
// 如果是gif图片,请指定imgType = gif
public String imgType;
public PicStyle picStyle;
public Float cornerRadius;
public Integer bgW;
public Integer bgH;
public BgStyle bgStyle;
public Float opacity;
public Integer startX;
public Integer startY;

需要额外注意的一点是,若背景图为gif图,请一定一定设置 imgType = gif

2.2.5 ft前置图

前置图设置,具体参数同样参考前置图的参数定义

public String img;
// 如果是gif图片,请指定imgType = gif
public String imgType;
public PicStyle picStyle;
public Float cornerRadius;
public Integer ftW;
public Integer ftH;
public Integer startX;
public Integer startY;
public String fillColor;

2.2 使用实例

@Test
public void imgTplTest() throws Exception {
    String content = FileReadUtil.readAll("tpl/flower.tpl");
    String msg = "http://weixin.qq.com/r/FS9waAPEg178rUcL93oH";
    Boolean ans = QrCodeGenV3.of(msg).setW(700)
            .setImgTemplate(content).build()
            .asFile("./flower.png");
    System.out.println("over");
}