[wdmaudiodev] Re: AVStream driver & globally allocated memory
- From: Tim Roberts <timr@xxxxxxxxx>
- To: "wdmaudiodev@xxxxxxxxxxxxx" <wdmaudiodev@xxxxxxxxxxxxx>
- Date: Mon, 20 Jun 2016 14:12:54 -0700
alexander ivash wrote:
I understand this, but I failed to find 'Device context' (is it device
extension?) so decided to 'simulate' it by creating real global variable.
And yes, I manage memory by myself in such a case.
You're correct, the "avssamp" code blithely claims that "since this is a
software sample, we really don't care about device level notifications
and work." Clearly, that's not quite true. If you need to communicate
between filter instances, the device construct enables that.
If you need to do a lot of that communication, it would behoove you to
add the device notifications to your KSDEVICE_DESCRIPTOR. You can get
the skeleton from the avshws sample.
In general, it has been my experience that avssamp is not the right
place to start. Most real devices need the "pin-centric" approach
espoused by avshws.
Yes, that's the case. And as I said, I found the reason for BSOD. But
would still like to adjust code to follow the best practices using device
context. Just need to figure out what this context is and how to put data
Well, in an AVStream driver, the normal "device context" is owned by
AVStream. You need to use AVStream constructs to get your own contexts.
Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
URL to WDMAUDIODEV page:
Other related posts: