WandererXII / lishogi

☗ lishogi.org: the forever free, adless and open source shogi server forked from lichess.org ☗
https://lishogi.org
GNU Affero General Public License v3.0
261 stars 40 forks source link

Portella International Chu Shogi pieces corrupted #797

Closed CouchTomato87 closed 4 months ago

CouchTomato87 commented 4 months ago

image

Some of the down-facing pieces got messed up (you can see the strongest ones here). I'm not sure why because it was normal last time I used this set. Not only that, these are pngs so they aren't prone to glitches like svgs are. Any idea what happened here?

CouchTomato87 commented 4 months ago

Correction -- apparently these are pngs. This happens in Chrome but not in Firefox...

WandererXII commented 4 months ago

That's odd, the files weren't changed since they were added. I remember something similar happening with another piece set once - I had to manually tweak some svg attribute to resolve it, but the easiest solution is to probably rotate the up-facing pieces and use those. I will do it tomorrow.

WandererXII commented 4 months ago

lol, when I rotate it it's not red anymore, although it is red in inkscape... image

CouchTomato87 commented 4 months ago

I wouldn’t just rotate it since they’re not simply a mirror image (3D aspects account for position). I can try manipulating them a bit to see if that would fix the problem

WandererXII commented 4 months ago

I found what prob causes it - removing this filter fixes it:

<filter id="filter2484" width="1.105" height="1.093" x="-.053" y="-.047" style="color-interpolation-filters:sRGB">
  <feGaussianBlur id="feGaussianBlur2466" in="SourceGraphic" result="result0" stdDeviation="6"/>
  <feDiffuseLighting id="feDiffuseLighting2470" diffuseConstant="1" lighting-color="#FFF" result="result5" surfaceScale="4">
    <feDistantLight id="feDistantLight2468" azimuth="235" elevation="45"/>
  </feDiffuseLighting>
  <feComposite id="feComposite2472" in="result5" in2="SourceGraphic" k1="1.4" operator="arithmetic" result="fbSourceGraphic"/>
  <feGaussianBlur id="feGaussianBlur2474" in="fbSourceGraphic" result="result0" stdDeviation="6"/>
  <feSpecularLighting id="feSpecularLighting2478" in="result0" lighting-color="#FFF" result="result1" specularConstant="1" specularExponent="25" surfaceScale="4">
    <feDistantLight id="feDistantLight2476" azimuth="235" elevation="45"/>
  </feSpecularLighting>
  <feComposite id="feComposite2480" in="fbSourceGraphic" in2="result1" k2="1" k3="1" operator="arithmetic" result="result4"/>
  <feComposite id="feComposite2482" in="result4" in2="SourceGraphic" operator="in" result="result2"/>
</filter>

It's applied on the linear gradient with id='C' but it's not present on the pieces that display correctly. Without it it looks fine: image

CouchTomato87 commented 4 months ago

As your pfp suggests, you're a wizard!

WandererXII commented 4 months ago

https://github.com/WandererXII/lishogi/commit/ab28157c0ab796287ea7da66d92f85fe045d6ade