BitmapCache size

丶灬走出姿态 提交于 2019-12-13 05:15:00

问题


How much can this cache hold?

UIElement.CacheMode = new BitmapCache();

I don't get any exception, but a blurry (jpg-ish) appearance for given absurd size (ClipToBounds = false):

protected override void OnRender(DrawingContext context)
{
    context.DrawLine(new Pen(Brushes.Red, 1),
        new Point(-1000000, -1000000),
        new Point(1000000, 1000000));
}

MSDN say

The cache functions when hardware acceleration is not available. In this case, the bitmap is rendered in software, and the maximum bitmap dimensions are 2048 x 2048

And what if hardware acceleration is available (which I tend to think is a standard option for modern PC, no)?

I don't want jpg. And I am trying to estimate if it is possible to use cache for wpf graph.

来源:https://stackoverflow.com/questions/25507861/bitmapcache-size

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!