Showing posts with label wpf. Show all posts
Showing posts with label wpf. Show all posts

02 February 2011

SlimDXControl 1.0.0 released!

I've just released the first version of SlimDXControl on CodePlex:
SlimDXControl is a WPF control that wraps the complexity of managing a D3DImage for you. You just have to implement the actual DirectX rendering pieces you care about -- no messing about with device management or IsFrontBufferAvailableChanged or window resizing events.

D3DImage is a Microsoft-supplied WPF control that allows to embed DirectX/D3D9 graphics into a WPF application. Unfortunately, but necessarily, to use D3DImage you need to write quite a bit of code on the application side that is completely foreign to many WPF developers. Yes, you can find several good articles on the web on how to use D3DImage – from which I have learned much, thank you! -- but they are largely blogs or sample code snippets. The project is designed to be a standalone control, supported and maintained, that you can directly use in your code today.
It's seems fully functional and stable to me, but we'll call it a beta release until we get some feedback.

08 August 2008

WPF and C# notes

I've been learning C# and the .NET framework and WPF in the background lately -- most recently reimplementing "jiffy", my JPEG 2000 dump utility.

Some random notes as I climb the learning curve:
  • Petzold's book really disappointed me. These two quotes from an Amazon reviewer sum it up nicely: "I prefer sample applications to be shorter in order to illustrate the point. I found myself wading through code listings that had very little to do with what I thought the lesson was about" and "I felt that the explanations spent more time on how the sample application worked as opposed to going over the WPF technology that was supposed to be covered by the sample". I'm not looking for a dumbed-down version, no, but some screen shots or diagrams, please! Anyway, Sells' book is the one I've been toting around with me.
  • Liberty's C# book is a good intro (I've rarely gone wrong with an O'Reilly title), but doesn't go deep enough for an ex-compiler wonk. I need Books Two and Three, probably a C# language reference and a Framework reference.
  • A small thank you to John Skeet and his utility classes -- I'm using the EndianBinaryReader. (suggestion: namespace his classes a bit more, e.g. from MiscUtil.* to Skeet.MiscUtil.*).
  • Thanks also go to John Stewien for his multi-select tree control. (That behaviour really should be part of the framework itself.)
  • ObservableCollection seems to live in WindowsBase.dll. At least I wasn't the only one stuck on that.
  • Cold-start app startup times are waayy painful. I've seen a few blog posts on this topic, I try some of the ideas myself at some point.
  • Building produces lines in the output pane of the form: "C:\WINDOWS\...\Csc.exe /noconfig /nowarn:1701,1702 /errorreport:prompt ..." Alas, using F4 to cycle through the compilation errors line by line always "hits" this line. Why is that? Can I omit that line somehow as a build/config option? (F4 is able to skip other kinds of lines, like "Compile complete -- 2 errors ...")
  • Refactoring is nice. More kinds, please!
  • "AddReference..." takes a long time to open the dialog. Why?