[Mono-list] LockBits() on Mono 2.2?
stifu at free.fr
Fri Mar 20 14:15:55 EDT 2009
I haven't yet, but I plan to. I want to replace my unsafe FastBitmap class
with it, so my app can be fully managed and get a little speed boost.
However, the good thing about the FastBitmap class implementation was that
it was handled pretty much exactly like the Bitmap one... Not sure if it can
be done with the pointerless method, at least not as is, apparently, because
I had a quick look at the class, and it had no SetPixel or GetPixel methods.
> have you actually tried the "Fast Pointerless Image Pocessing" method on
> CodeProject? I'm implementing it right now and praying there are no
> issues. If I can't do fast pixel drawing it's a showstopper for sure. I
> want this to work so badly...
> Stifu wrote:
>> Mono being faster than .NET with SetPixel must have been on a particular
>> case... I have found a huge performance issue with Mono and
>> Get/SetPixel() in a particular situation, making Mono crawl... Something
>> instantaneous with .NET can easily take 10 seconds with Mono (the perf
>> hit is exponential, too).
>> I couldn't make a reduced test case for that one either yet...
>> But hey, that aside, I've been happy with Mono too. :p
>> Dan Shryock wrote:
>>> On Fri, Mar 20, 2009 at 8:40 AM, LKeene <lionel.keene at gmail.com> wrote:
>>>> I actually intend to use it to draw to a memory bitmap pixel-by-pixel,
>>>> than calling SetPixel() each time. Apparently that would be extremely
>>>> form what I've read online. The only alternative to Set/GetPixel()
>>>> seems to
>>>> be declaring an unsafe block and using LockBits(). I'll try to test the
>>>> LockBits() implementation today, but assuming that there is indeed a
>>>> does anyone have any other ideas of how to accomplish drawing to a
>>>> Bitmap other than SetPixel()? I have a precomputed "Color[,]" that
>>>> the pixels colors.
>>> In a recent project, I had no troubles working with lockbits on Mono
>>> 1.9 on linux.
>>> In the past, using some older version of Mono (probably 1.1.x or 1.2.x)
>>> I had
>>> encountered few troubles working with lockbits but they have been
>>> resolved in
>>> newer Mono releases.
>>> Another thing that I noticed is that calling SetPixel repeatedly on
>>> .NET is much slower than calling SetPixel repeatedly on Mono (though
>>> was still faster on both).
>>> Mono-list maillist - Mono-list at lists.ximian.com
View this message in context: http://www.nabble.com/LockBits%28%29-on-Mono-2.2--tp22611389p22625984.html
Sent from the Mono - General mailing list archive at Nabble.com.
More information about the Mono-list