Níveis de Renderização Gráfica

A rendering tier defines a level of graphics hardware capability and performance for a device that runs a WPF application.

Este tópico contém as seguintes seções.

  • Graphics Hardware
  • Rendering Tier Definitions
  • Other Resources
  • Tópicos relacionados

Graphics Hardware

The features of the graphics hardware that most impact the rendering tier levels are:

  • Video RAM The amount of video memory on the graphics hardware determines the size and number of buffers that can be used for compositing graphics.

  • Pixel Shader A pixel shader is a graphics processing function that calculates effects on a per-pixel basis. Depending on the resolution of the displayed graphics, there could be several million pixels that need to be processed for each display frame.

  • Vertex Shader A vertex shader is a graphics processing function that performs mathematical operations on the vertex data of the object.

  • Multitexture Support Multitexture support refers to the ability to apply two or more distinct textures during a blending operation on a 3D graphics object. The degree of multitexture support is determined by the number of multitexture units on the graphics hardware.

Rendering Tier Definitions

The features of the graphics hardware determine the rendering capability of a WPF application. The WPF system defines three rendering tiers:

  • Rendering Tier 0 No graphics hardware acceleration. Todos os recursos de gráficos usam aceleração de software. The DirectX version level is less than version 9.0.

  • Processamento de nível 1 alguns recursos gráficos usam aceleração de hardware. The DirectX version level is greater than or equal to version 9.0.

  • Rendering Tier 2 Most graphics features use graphics hardware acceleration. O DirectX nível de versão é maior ou igual a versão 9.0.

O RenderCapability.Tier propriedade permite que você recupere a camada de processamento no aplicativo em execução o tempo. Você pode usar a camada de processamento para determinar se o dispositivo oferece suporte a determinados recursos de gráficos acelerada por hardware. Your application can then take different code paths at run time depending on the rendering tier supported by the device.

Rendering Tier 0

A rendering tier value of 0 means that there is no graphics hardware acceleration available for the application on the device. Esse nível de camada, você deve assumir que todos os elementos gráficos serão processados pelo software sem aceleração de hardware. A funcionalidade da camada corresponde a um DirectX versão é menor que a 9.0.

Processamento de nível 1 e nível 2 de processamento.

Observação

A partir do.NET Framework 4, a camada de processamento 1 foi redefinido para incluir somente o hardware de gráficos que suporta DirectX 9.0 ou maior.Hardware de gráficos que suporta DirectX 7 ou 8 agora é definido como nível de processamento 0.

Um valor 1 ou 2 do nível de processamento significa que a maioria dos recursos gráficos do WPF usará a aceleração de hardware se os recursos de sistema necessários estão disponíveis e não tem sido esgotados. Isso corresponde a um DirectX versão é maior que ou igual a 9.0.

A tabela a seguir mostra as diferenças nos gráficos requisitos de hardware para processamento 1 e 2 de camadas de processamento:

Feature

Nível 1

Nível 2

DirectXversão

Must be greater than or equal to 9.0.

Must be greater than or equal to 9.0.

Video RAM

Deve ser maior ou igual a 60 MB.

Must be greater than or equal to 120MB.

Pixel shader

Version level must greater than or equal to 2.0.

Version level must greater than or equal to 2.0.

Vertex shader

Nenhum requisito.

Version level must greater than or equal to 2.0.

Multitexture units

Nenhum requisito.

Number of units must greater than or equal to 4.

Os seguintes recursos e capacidades são acelerada para processamento 1 e 2 de camadas de processamento de hardware:

Feature

Notes

2D rendering

Most 2D rendering is supported.

3D rasterization

Most 3D rasterization is supported.

A filtragem de Anisotrópico mistura 3D

WPFtenta usar a filtragem de Anisotrópico mistura quando o conteúdo de processamento 3D. Anisotropic filtering refers to enhancing the image quality of textures on surfaces that are far away and steeply angled with respect to the camera.

Mapeamento de MIP 3D

WPFtenta usar o mapeamento de MIP durante a renderização de conteúdo 3D. Mapeamento de MIP melhora a qualidade de processamento de textura, quando uma textura ocupa um campo de visão menor em um Viewport3D.

Radial gradients

While supported, avoid the use of RadialGradientBrush on large objects.

3D lighting calculations

WPFexecuta a iluminação por vértice, o que significa que a intensidade da luz deve ser calculada em cada vértice para cada material aplicado a uma malha.

Text rendering

Sub-pixel font rendering uses available pixel shaders on the graphics hardware.

Os seguintes recursos e capacidades são acelerado para o nível 2 do processamento de hardware:

Feature

Notes

3D anti-aliasing

Suavização de serrilhado 3D é suportada apenas em sistemas operacionais que suportam o Windows Driver WDDM (Display Model), como Windows Vista e Windows 7.

Os seguintes recursos e capacidades são não acelerada de hardware:

Feature

Notes

Printed content

All printed content is rendered using the WPF software pipeline.

Rasterized content that uses RenderTargetBitmap

Qualquer conteúdo processado usando o Render o método de RenderTargetBitmap.

Tiled content that uses TileBrush

Any tiled content in which the TileMode property of the TileBrush is set to Tile.

Surfaces that exceed the maximum texture size of the graphics hardware

For most graphics hardware, large surfaces are 2048x2048 or 4096x4096 pixels in size.

Any operation whose video RAM requirement exceeds the memory of the graphics hardware

Você pode monitorar o uso de memória RAM de vídeo de aplicativos usando a ferramenta de Perforator incluídas na Suite de desempenho do WPF no Windows SDK.

Layered windows

Layered windows allow WPF applications to render content to the screen in a non-rectangular window. Em sistemas operacionais que suportam o Windows Driver WDDM (Display Model), como Windows Vista e Windows 7, em camadas windows são hardware acelerado. On other systems, such as Windows XP, layered windows are rendered by software with no hardware acceleration.

You can enable layered windows in WPF by setting the following Window properties:

Other Resources

The following resources can help you analyze the performance characteristics of your WPF application.

Graphics Rendering Registry Settings

WPF provides four registry settings for controlling WPF rendering:

Setting

Description

Disable Hardware Acceleration Option

Specifies whether hardware acceleration should be enabled.

Maximum Multisample Value

Specifies the degree of multisampling for antialiasing 3-D content.

Required Video Driver Date Setting

Specifies whether the system disables hardware acceleration for drivers released before November 2004.

Use Reference Rasterizer Option

Specifies whether WPF should use the reference rasterizer.

These settings can be accessed by any external configuration utility that knows how to reference the WPF registry settings. These settings can also be created or modified by accessing the values directly by using the Windows Registry Editor. For more information, see Configurações do Registro para Renderização Gráfica.

WPF Performance Profiling Tools

WPF provides a suite of performance profiling tools that allow you to analyze the run-time behavior of your application and determine the types of performance optimizations you can apply. A tabela a seguir lista o ferramentas incluídas de perfis de desempenho do Windows SDK ferramenta de conjunto de desempenho do WPF:

Tool

Description

Perforator

Use for analyzing rendering behavior.

Visual Profiler

Use para criar o perfil de uso de WPF serviços, como o layout e de manipulação de eventos, pelos elementos na árvore visual.

O conjunto de desempenho do WPF fornece uma exibição gráfica avançada de dados de desempenho. Para obter mais informações sobre as ferramentas de desempenho do WPF, consulte Suite de desempenho do WPF.

DirectX Diagnostic Tool

The DirectX Diagnostic Tool, Dxdiag.exe, is designed to help you troubleshoot DirectX-related issues. The default installation folder for the DirectX Diagnostic Tool is:

~\Windows\System32

When you run the DirectX Diagnostic Tool, the main window contains a set of tabs that allow you to display and diagnose DirectX-related information. For example, the System tab provides system information about your computer and specifies the version of DirectX that is installed on your computer.

DirectX Diagnostic Tool main window

Captura de tela: ferramenta de diagnóstico DirectX

Consulte também

Referência

RenderCapability

RenderOptions

Conceitos

Optimizing WPF Application Performance

Suite de desempenho do WPF

Configurações do Registro para Renderização Gráfica

Dicas e truques de animação

Histórico de alterações

Date

History

Motivo

Outubro de 2010

Informações atualizadas sobre.NET Framework 4 e o nível de processamento 2.

Comentários do cliente.

Setembro de 2010

Adicionadas informações sobre ferramentas de criação de perfil de desempenho do WPF.

Aprimoramento de informações.