Part 1 of this is here : https://www.experts-exchange.com/Programming/Programming_Languages/Delphi/Q_20604284.html
I suggest you read that question even if you can't answer it, as it provides some background.
Like Part 1, this question is worth 1000 points. I forgot after posting a question that I could up the points, so I'll try to up them to 1000 after this. If that doesn't work, I'll post another 500 point question for the winner when this is over.
To cover the basics, I'm using Delphi 6 and DSPack in a webcam app and want to add video streaming capabilities with TASFWriter; I am open to using something other than TASFWriter if it integrates nicely with what I already have, that will be Part 3.
Question 1 asks how I can disable some of the capabilities of TASFWriter.
I've had no luck coming up with my own profiles for streaming. Nothing I seem to do affects the output over the stream in regards to bitrate or resolution. I know I'm capturing at the proper resolution, as the bitmaps I capture from the samplegrabber are the correct size. The stream though is always some 1/4 size or smaller, at 32kbit/s. I've tried adding a new filter and selecting one of of the existing codecs on my system such as DivX or MPEG, and while they work and generate a compressed stream, it's still the same low bitrate. To answer this question, I'd like to see a working code example of custom profile creation and loading using the ConfigFilterUsingProfile method of the IConfigASFWriter interface of the TASFWriter component, which is available via it's QueryInterface method.
To satisfy my curiosity that this is working properly, the output resolution should (at best) match the resolution of the current device, which I have in my code as a TFilter (DSPack) called "fPreview", and provide a stream bitrate of 384Kbit/s. The stream should be "video only" as I don't want the audio streamed.
I don't have a particular need for those numbers, but the default profiles described by dspack for video only are low-bandwidth only, 28.8 and 56k respectively, and only the 56k one seems to work when assigning a new value to the TASFWriter profile property. I don't want to load a predefined profile, I want to create my own. I have the code implemented to load and edit the profile and I'm pretty sure that much is working properly, It just seems to have no effect when I do : ConfigAsfWriter.ConfigureF
ConfigAsfWriter is an IConfigAsfWriter interface, acquired via the QueryInterface method of the TASFWriter component. Profile is a IWMProfile interface. A short list of the steps I'm performing here:
1) Call WMCreateProfileManager to get an IWMProfileManager.
2) Call ProfileManager.CreateEmpty
Profile) to setup the IWMProfile.
3) Call Profile.CreateNewStream(WM
VIDEO, stream). Stream is an IWMStreamConfig.
At this point I've messed with setting Stream.Bitrate, as well as creating an IWMMediaProps interface and changing the resolution, all to no avail, usually generating an exception.
Thanks for your answers EE people, I know you'll come through for me again. ;)