Se ha denunciado esta presentación.
Utilizamos tu perfil de LinkedIn y tus datos de actividad para personalizar los anuncios y mostrarte publicidad más relevante. Puedes cambiar tus preferencias de publicidad en cualquier momento.
Direct3D to WPF  Daosheng Mu    2012.1.3
Outline• WPF• Direct3D• Binding-P/Invoke, CIL
WPF• Windows Presentation Foundation  – Based on .NET 3.0  – GUI utilizes DirectX  – eXtensible Application Markup Languag...
Direct3D• 3D graphics API supported by Microsoft• Utilize GPU hardware acceleration• Used to render 3D application which  ...
Communication between WPF/D3D• How?  – P/Invoke    • extern identifier, huge cost  – CIL(Common Intermediate Language)    ...
How to write CLI• Project Setting  – Adjust on Win32 dll project  – Create CLR project
Adjust on Win32 dll project      Add dll to WPF project
Adjust on Win32 dll project                       Code Generation
Adjust on Win32 dll                 CLR Support
Create CLR Project              Create CLR Class Library
CIL Sample• Extend Idisposable• Class ref• *ObjPtr using  IntPtr
Result• https://github.com/DaoshengMu/WPFd3dIma  geCpp
Próxima SlideShare
Cargando en…5
×

Direct3D to WPF

2.353 visualizaciones

Publicado el

Talk about using Direct3D on WPF

Publicado en: Tecnología
  • Sé el primero en comentar

  • Sé el primero en recomendar esto

Direct3D to WPF

  1. 1. Direct3D to WPF Daosheng Mu 2012.1.3
  2. 2. Outline• WPF• Direct3D• Binding-P/Invoke, CIL
  3. 3. WPF• Windows Presentation Foundation – Based on .NET 3.0 – GUI utilizes DirectX – eXtensible Application Markup Language (XAML) • For more effective to develop UI
  4. 4. Direct3D• 3D graphics API supported by Microsoft• Utilize GPU hardware acceleration• Used to render 3D application which performance is important• Game engine usually is designed to use c++/d3d commonly
  5. 5. Communication between WPF/D3D• How? – P/Invoke • extern identifier, huge cost – CIL(Common Intermediate Language) • Marshaling at compile time, better performance
  6. 6. How to write CLI• Project Setting – Adjust on Win32 dll project – Create CLR project
  7. 7. Adjust on Win32 dll project Add dll to WPF project
  8. 8. Adjust on Win32 dll project Code Generation
  9. 9. Adjust on Win32 dll CLR Support
  10. 10. Create CLR Project Create CLR Class Library
  11. 11. CIL Sample• Extend Idisposable• Class ref• *ObjPtr using IntPtr
  12. 12. Result• https://github.com/DaoshengMu/WPFd3dIma geCpp

×