<div dir="ltr"><div>Hello, this is google translation, sorry!</div><div><br></div><div>I realize SWF To bitmap conversion is found a problem, the code is as follows (using C # call cairo.dll,v1.12.14)</div><div><br></div><div>
  Cairo.Context c = new Context (new ImageSurface (Format.ARGB32, 150, 150));</div><div>             Matrix m1 = new Matrix ();</div><div>             m1.Scale (0.1, 0.1);</div><div>             / / m1.Scale (0.5, 0.5);</div>
<div>             / / m1.Scale (1, 1);</div><div>             c.Matrix = m1;</div><div><br></div><div>             Cairo.LinearGradient lg = new LinearGradient (-16384, 0, 16384, 0);</div><div>             Cairo.Matrix m2 = new Matrix ();</div>
<div>             m2.Scale (0.01220703125, 0.01220703125);</div><div>             m2.Translate (3896.0, 0);</div><div>             m2.Invert ();</div><div>             lg.Extend = Extend.Repeat;</div><div>             lg.Matrix = m2;</div>
<div>             lg.AddColorStop (0, new Cairo.Color (0, 0, 0));</div><div>             lg.AddColorStop (0.4, new Cairo.Color (1, 0, 0));</div><div>             lg.AddColorStop (0.8, new Cairo.Color (1, 1, 0));</div><div>
             lg.AddColorStop (1, new Cairo.Color (1, 1, 1));</div><div><br></div><div>             c.Pattern = lg;</div><div>             c.MoveTo (0, 0);</div><div>             c.LineTo (4096, 0);</div><div>             c.LineTo (4096, 4096);</div>
<div>             c.LineTo (0, 4096);</div><div>             c.LineTo (0, 0);</div><div>             c.ClosePath ();</div><div>             c.FillPreserve ();</div><div>             c.Color = new Cairo.Color (0, 0, 0, 1);</div>
<div>             c.Stroke ();</div><div>             c.Target.WriteToPng (@ "c: \ test.png");</div><div>             c.Target.Dispose ();</div><div><br></div><div>In the above code, if you use m1.Scale (1, 1); m1.Scale (0.5, 0.5); gradient effect with the normal output picture, but if you use m1.Scale (0.1,0.1); or low scaling, such as m1.Scale (0.05,0.05), the picture output is blank.</div>
<div>I do not know whether this is a BUG, please test it yourself and give back. Thank you!</div><div><br></div><div>Mail attachment in my test pictures, please check.</div><div><br></div><div><img src="cid:ii_13f51e71b2f76c9b" alt="ÄÚǶͼƬ 2"><img src="cid:ii_13f51e7388700fdd" alt="ÄÚǶͼƬ 3"><img src="cid:ii_13f51e751d39f7ba" alt="ÄÚǶͼƬ 1"><br>
</div></div>