> On 02/02/2011 02:11 PM, Kevin Fishburne wrote: > > I have an image, blandscape, that is 1408 x 1408 pixels. This code works: > > > > blandscape.Draw(blandscape, 0, -128) > > > > This code produces odd results (attached): > > > > blandscape.Draw(blandscape, 0, 128) > > > > I'm trying to shift the image in any of eight directions (up, down, > > left, right, up-left, up-right, down-left, down-right) by 128 pixels, > > which is the size of the "tiles" used in the game. I'm basically > > copying the image onto itself but offset by 128 pixels. Any idea > > what's going on here? I tried using all the available parameters for > > the Draw method and it still didn't work. > > I think I figured it out. It looks like the Draw method doesn't create a > "temporary" image to do the copying, meaning it's literally writing over > itself in memory. I worked around the issue by using a temporary image, > though it is slower. I don't think the Draw method should be changed, as > it is more efficient this way. Having it automatically create a > temporary image when the source and target are the same would really > slow things down if it wasn't needed.
Actually you want some sort of scrolling? -- Benoît Minisini ------------------------------------------------------------------------------ Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)! Finally, a world-class log management solution at an even better price-free! Download using promo code Free_Logger_4_Dev2Dev. Offer expires February 28th, so secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsight-sfd2d _______________________________________________ Gambas-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/gambas-user
