IBasicVideo2.GetVideoPaletteEntries
Microsoft DirectShow 9.0 |
IBasicVideo2.GetVideoPaletteEntries
- Note This topic is deprecated. It applies to Visual Basic 6.0. DirectShow is not supported for Visual Basic .NET or C#.
The GetVideoPaletteEntries method retrieves the palette colors for the video.
Syntax
objVideo .GetVideoPaletteEntries( StartIndex As Long, Entries As Long, ByRef Retrieved As Long, ByRef Palette As Long)
Parameters
StartIndex
Start index for the palette.
Entries
Number of palette entries to retrieve.
Retrieved
Variable that receives the number of entries returned in Palette.
Palette
Variable that receives the palette entries. Set this parameter equal to the first element in an array of type Long. Treat the returned values as PALETTEENTRY structures.
Return Values
This method does not return a value.
Remarks
The method fails if no palette is available. This can occur if the bit depth of the display is too high.
Example Code
Dim Retrieved As Long, Palette(16) As Long Dim blue As Byte, red As Byte, green As Byte iVideo.GetVideoPaletteEntries 0, 16, Retrieved, Palette(0) For i = 0 To Retrieved - 1 red = Palette(i) And &HFF green = (Palette(i) And &HFF00&) / 256 blue = (Palette(i) And &HFF0000) / 65536 Next
Requirements
Reference: Add a reference to ActiveMovie control type library.
Library: Quartz.dll.
See Also