How do i change the screen resolution of a video while recording in directshow? because I have a 8 Mega-pixel web camera, which I use for video recording but after the video
You need to use IAMStreamConfig
interface. Some MSDN leads for you:
Configure the Video Output Format (Windows):
To configure a capture device's output format, an application should use the AM_MEDIA_TYPE structure returned by IAMStreamConfig::GetFormat in the pmt parameter.
IAMStreamConfig::GetFormat method (Windows):
If the pin is connected, this method returns the format that the pin is currently using. Otherwise, the method returns the pin's preferred format for the next pin connection. If you have already called the IAMStreamConfig::SetFormat method to set the format, GetFormat returns the same format. If not, it returns the first format in the pin's list of preferred formats, as determined by the IPin::EnumMediaTypes method.
More:
Also, your webcam might have lower resolution for video streaming, and high for taking still thanks to post-processing capabilities.