06 Mar 2016 @ 8:57 PM 

Just thought I would make a quick post on this. I’ve been tweaking BASeBlock a bit to try to get it to allow for a larger window size, since it’s pretty ridiculously small. Thankfully, it was already using a backbuffered approach, so I simply made the window resizable. But I found in doing so that performance dropped substantially as I increased the size of the image.

I used the Performance and Diagnostics feature to try to diagnose the cause. most of the added time was in the GDI+ DrawImage function when it drew the backbuffer to the visible control.

After some experimentation, I was able to increase performance by a fairly good margin. This can be done by adjusting the CompositingMode, CompositingQuality, and InterpolationMode properties of the Graphics context in use and using SourceCopy, HighSpeed, and NearestNeighbor, respectively.

 

Looking into it it seems that GDI+ just has poor performance for image scaling.

Have something to say about this post? Comment!

Posted By: BC_Programming
Last Edit: 06 Mar 2016 @ 08:57 PM

EmailPermalink
Tags
Categories: .NET, Windows


 

Responses to this post » (None)

 
Post a Comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">

Tags
Comment Meta:
RSS Feed for comments

 Last 50 Posts
 Back
Change Theme...
  • Users » 42425
  • Posts/Pages » 353
  • Comments » 104
Change Theme...
  • VoidVoid « Default
  • LifeLife
  • EarthEarth
  • WindWind
  • WaterWater
  • FireFire
  • LightLight

PP



    No Child Pages.

Windows optimization tips



    No Child Pages.

BC’s Todo List



    No Child Pages.