#include "ltmm.h"
C Syntax |
HRESULT IltmmSampleTarget_put_TargetFormat(pSampleTarget, newVal); |
C++ Syntax |
HRESULT put_TargetFormat(newVal); |
IltmmSampleTarget *pSampleTarget; |
pointer to an interface |
long newVal; |
target format |
Sets the target format accepted by the sample target object.
Parameter |
Description |
pSampleTarget |
Pointer to an IltmmSampleTarget interface. |
newVal |
The target format. Can be set to any value from the ltmmSampleTarget_TargetFormat enumeration. |
S_OK |
The function was successful. |
<> S_OK |
An error occurred. Refer to the Error Codes or the HRESULT error codes in the DirectShow documentation. |
By default, the value of this property is ltmmSampleTarget_TargetFormat_Undefined. If you assign a value to the TargetFormat property that matches your expected final output format, then only media types that are accepted by the assigned format will be allowed. The AcceptedMediaType values are still honored, however, only the parts of the AcceptedMediaType that are not specified (GUID_NULL) are compared with the TargetFormat. So, you can still force a pin to only accept a major type of Video, and have the rest depend on the target format, by simply assigning an AcceptedMediaType with only the major type of video defined.
Required DLLs and Libraries
LTMM For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
Win32, x64
For a C example, refer to Splitting an AVI File into Multiple Bitmaps Using ltmmSampleTarget for C.
For a C++ example, refer to Splitting an AVI File into Multiple Bitmaps Using ltmmSampleTarget for C++.
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET