Sign In
Windows Media and DirectShow tips, gotchas and code bits
This blog is dedicated to assisting fellow Software Engineers who are integrating Microsoft’s audio and video technologies into their software.
Translate This Page
Translate this page
Powered by
Microsoft® Translator
Options
About
Email Blog Author
RSS for posts
Atom
OK
Search
Advanced search options...
Search In:
Everything
Blogs
Forums
People
Groups
Places
Pages
Date range:
All Time
Last Year
Last 6 Months
Last 3 Months
Last Month
Last Week
Last Two Days
Tags
Async File Source
Audio
AVI Splitter
COPP
deinterlacing
Direct Media Object
DirectMusic
DirectShow
DMO
DRM
DV Decoder
Expression Encoder
HTTP Streaming
Media Foundation
Media Foundation Transform
MediaElement
MF
mfpmp.exe
VMR9
WASAPI
Windows Media Encoder
Windows Media Format SDK
Windows Media Player
WM DRM
WMRM SDK
Archive
Archives
June 2010
(1)
July 2009
(1)
May 2009
(1)
April 2009
(4)
March 2009
(2)
February 2009
(2)
January 2009
(2)
October 2008
(3)
September 2008
(4)
April 2008
(1)
March 2008
(5)
MSDN Blogs
>
Windows Media and DirectShow tips, gotchas and code bits
Posts
Subscribe via RSS
Sort by:
Most Recent
|
Most Views
|
Most Comments
Excerpt View
|
Full Post View
Windows Media and DirectShow tips, gotchas and code bits
Out of memory errors with the Windows Media Format SDK
Posted
over 2 years ago
by
James Dailey
Over the last few years I’ve worked with a number of engineers that have reported out of memory errors when encoding high definition (HD) video using the Windows Media Format SDK. This issue typically only occurs on 32 bit systems. As we know on...
Windows Media and DirectShow tips, gotchas and code bits
Why are the Multimedia Timer APIs (timeSetEvent) not as accurate as I would expect?
Posted
over 3 years ago
by
James Dailey
The Multimedia Timer APIs (MM Timer APIs) get their high accuracy by using the Programmable Interrupt Controller (PIC) built into the hardware on the machine. By default Windows specifies a PIC duration of about 10 – 16 milliseconds. Every time...
Windows Media and DirectShow tips, gotchas and code bits
Here is a consolidated list of changes that we can expect for DirectShow Windows 7
Posted
over 3 years ago
by
James Dailey
1
Comments
Potentially Breaking Change (*IMPORTANT*): Intelligent Connect adds a level of indirection on Win 7 that may have a major impact to DirectShow developers. Starting in Windows 7, DirectShow has a list of preferred filters for certain media subtypes...
Windows Media and DirectShow tips, gotchas and code bits
Activating an audio endpoint when not connected causes the device to report incorrect capabilities
Posted
over 3 years ago
by
James Dailey
1
Comments
The other day we had a major OEM report an issue with the WASAPI. In particular when they found that when they called “IAudioEndpointVolume::QueryHardwareSupport” it would occasionally return unexpected results for USB web cam devices. Most...
Windows Media and DirectShow tips, gotchas and code bits
Exception playing .mp3 & .wma files using embedded WMP from .hta files
Posted
over 3 years ago
by
James Dailey
1
Comments
We recently had an engineer report a strange exception when displaying .hta files via mshta.exe. If you embed the Windows Media Player OCX control (WMP) in a web page and then start playback of a file, you will get an exception like the following: ...
Windows Media and DirectShow tips, gotchas and code bits
Playing an MPEG1 file in WMP via HTTP returns the wrong duration
Posted
over 3 years ago
by
James Dailey
1
Comments
A colleague of mine in Japan recently found this very interesting issue in Windows Media Player (WMP) on Windows XP. From what he found WMP returns the wrong duration value when playing back MPEG1 files via HTTP. This only appears to occur if the file...
Windows Media and DirectShow tips, gotchas and code bits
Calling the Format SDK, DirectShow, Media Foundation or the WASAPI from managed code (C#, VB.net)
Posted
over 3 years ago
by
James Dailey
1
Comments
I get this series of questions from different developers from around the world at least once a week. Q. I want to use DirectShow (Windows Media Format SDK, WASAPIs) from my C# (VB.net, managed) code. Why doesn’t Microsoft have a COM interop library...
Windows Media and DirectShow tips, gotchas and code bits
Using the Format SDK to push to multiple publishing points on the same server
Posted
over 3 years ago
by
James Dailey
1
Comments
I have been working with an engineer for weeks trying to figure out why we were not able to push to multiple publishing points on the same server using the Windows Media Format SDK. I know that there was a bug in the Format SDK that prevented multiple...
Windows Media and DirectShow tips, gotchas and code bits
Where the heck did Microsoft hide the WM Format SDK x64 libraries for Vista? How about XP?
Posted
over 3 years ago
by
James Dailey
1
Comments
It looks like the 64 bit version of the Windows Media Format SDK .lib static library files are not where you would expect to find them. If you go to the Windows Media SDK downloads page, there is a happy little link for the Windows Media Format 11 SDK...
Windows Media and DirectShow tips, gotchas and code bits
DirectShow Filter vs. DMO - Ready... Fight!
Posted
over 3 years ago
by
James Dailey
1
Comments
There are some rather interesting misunderstandings surrounding Direct Media Objects (DMO). I talked to one engineer the other day that called DMOs inferior to DirectShow filters. While I personally think that DirectShow is one of the most amazing technologies...
Windows Media and DirectShow tips, gotchas and code bits
Rendering MMS, RTSP and HTTP with DirectShow in Vista and Windows 7
Posted
over 3 years ago
by
James Dailey
I was talking to a DirectShow engineer the other day that was having issues rendering URLs using DirectShow on XP and Vista. He noticed that the behavior was very different between the two operating systems. Luckily I was privy to a very interesting conversation...
Windows Media and DirectShow tips, gotchas and code bits
“MediaElement.SetSource” throws “AE_INVALID_FORMAT_ERROR” when setting “Stream” sources
Posted
over 3 years ago
by
James Dailey
1
Comments
When reading a stream from a location such as a media resource object, and then calling “MediaElement.SetSource” may return “AE_INVALID_FORMAT_ERROR”. If you construct a “MemoryStream” using your “Stream”...
Windows Media and DirectShow tips, gotchas and code bits
“Leave audio at remote computer” Doesn't Work in Windows Server 2008
Posted
over 3 years ago
by
James Dailey
1
Comments
When connecting to Windows Server 2008 through remote desktop choosing to leave the audio on the remote machine does not work as expected. Although the option shows up on the remote desktop application, if you select it and then connect, the audio is...
Windows Media and DirectShow tips, gotchas and code bits
Hotfix 929182 not updating Windows Media Encoder 9 components as expected on Vista
Posted
over 4 years ago
by
James Dailey
1
Comments
I was in training a few weeks ago (WMS 2008 new features) and found that no matter what I did I was not able to get hotfix KB929182 installed on my Vista lab machine. The hotfix would act as if it installed correctly but the affected DLLs were not updated...
Windows Media and DirectShow tips, gotchas and code bits
Windows Media Player does not negotiate media types for DMO DSP plug-ins on Vista
Posted
over 4 years ago
by
James Dailey
1
Comments
Here is an interesting issue I ran across writing Windows Media Player (WMP) custom DSP plug-ins. When I am prototyping a new filter or plug-in for DirectShow or WMP, I will usually write my transform’s algorithm using a single format / media type...
Windows Media and DirectShow tips, gotchas and code bits
Using the WM Encoder to Protect Existing Content with WM DRM
Posted
over 4 years ago
by
James Dailey
One of the things that a lot of DRM savvy CDNs are doing is to use WM Encoder to add WM DRM to their content without actually re-encoding. This is basically a copy operation from the input file (WMV) to an output file (WMV). The samples are never decompressed...
Windows Media and DirectShow tips, gotchas and code bits
WMRM SDK 10.1.2 best practice sample code
Posted
over 4 years ago
by
James Dailey
1
Comments
I wrote this sample code a while back to show how to validate the latest individualization version when using predelivery. Here are a few tricks that you need to do to make this work. Namely, you need to parse the “ClientInfo” XML fragment...
Windows Media and DirectShow tips, gotchas and code bits
Custom DirectShow Audio Renderer hangs playback in Windows Media Player 11
Posted
over 4 years ago
by
James Dailey
If you write your own DirectShow based Audio Renderer and want it to work inside WM Player 11 don’t derive it from CBaseRenderer. If you use CBaseRenderer, A/V playback in WM Player may hang. Unfortunately it doesn’t hang all the time. The...
Windows Media and DirectShow tips, gotchas and code bits
WM Format SDK DRM returns NS_E_DRM_LICENSE_NOTACQUIRED when license is delivered
Posted
over 4 years ago
by
James Dailey
I ran into an issue using the WM Format SDK DRM Stub Library the other day. When we were trying to decode and playback some DRM encrypted files we saw a “NS_E_DRM_LICENSE_NOTACQUIRED” error when using the “Audio Player” sample...
Windows Media and DirectShow tips, gotchas and code bits
Windows Media Encoder 9 (SDK) Limitations and Support
Posted
over 4 years ago
by
James Dailey
There are a few limitations to the supportability of the Windows Media Encoder 9 series application and SDK. Microsoft has extended support for this product for the next year or so. Hopefully if you are reading this you are aware of the next generation...
Windows Media and DirectShow tips, gotchas and code bits
Unexpected Windows Media Encoder shutdown / crash while encoding
Posted
over 4 years ago
by
James Dailey
I found an interesting problem when dynamically changing the input format of the WM Encoder while encoding. In other words if you are capturing from a single digital capture card and the card can change the input resolution dynamically then WM Encoder...
Windows Media and DirectShow tips, gotchas and code bits
When playing back a DV encoded AVI file, what does the AVI Splitter do when it detects a zero byte sample (zero byte index) from the Async File Source?
Posted
over 4 years ago
by
James Dailey
Q. When playing back a DV encoded AVI file, what does the AVI Splitter do when it detects a zero byte sample (zero byte index) from the Async File Source? A. From what I see in the code the AVI Splitter doesn’t do anything when it detects a zero...
Windows Media and DirectShow tips, gotchas and code bits
When NTSC (29.97 interlaced) video is being fed to the VMR9 with a custom allocator/presenter, PresentImage is being called 60 times per second. You expect 30 times per second.
Posted
over 4 years ago
by
James Dailey
Q. When NTSC (29.97 interlaced) video is being fed to the VMR9 with a custom allocator/presenter, PresentImage is being called 60 times per second. You expect 30 times per second. A. This is by design depending on the type of deinterlacing that you...
Windows Media and DirectShow tips, gotchas and code bits
Adding CRL data to WMRM SDK 10.1.2 based scripts
Posted
over 4 years ago
by
James Dailey
UPDATE: The code referenced on this page is written in ASP / VB Script. I recently created a complete ASP.net code sample that does everything this code does and more. I would recommend that you check it out by going here: http://blogs.msdn.com/mediasdkstuff...
Windows Media and DirectShow tips, gotchas and code bits
DirectMusic PlaySegmentEx stops working after running for 18 - 20 days
Posted
over 4 years ago
by
James Dailey
I ran into an interesting issue with DirectMusic yesterday. When you use PlaySegmentEx to repeatedly play MIDI content, after about 18 - 20 days of constant playback the API stops playing the content as expected. DirectMusic builds a DirectShow graph...
Page 1 of 2 (26 items)
1
2