Please someone help me with this one.

I'm running DirectShow on Windows Mobile 2005. While my code runs fine
on many devices, I just tried it on the HTC Mteor which we got today.

Enumerating the video modes lists two modes available:
320x240 YUV12 15fps and 160x120 YUV12 15fps.

While the 160x120 mode works as expected, I have problems with the
320x240 mode, because the image in there is 160x120 too.

IMediaSample::GetSize() returns 115200 (which corresponds to
320x240y12bits), but the image in the pixel buffer is only 160x120
pixels large (the rest of the buffer is just unused...)!

Any ideas on what could be going wrong here?

thanks a lot,
Daniel

Re: Data in IMediaSample half res of what it should be... by Sai

Sai
Mon Nov 27 11:29:54 CST 2006

Did you check GetActualDataLength()?


Sai



Daniel wrote:
> Please someone help me with this one.
>
> I'm running DirectShow on Windows Mobile 2005. While my code runs fine
> on many devices, I just tried it on the HTC Mteor which we got today.
>
> Enumerating the video modes lists two modes available:
> 320x240 YUV12 15fps and 160x120 YUV12 15fps.
>
> While the 160x120 mode works as expected, I have problems with the
> 320x240 mode, because the image in there is 160x120 too.
>
> IMediaSample::GetSize() returns 115200 (which corresponds to
> 320x240y12bits), but the image in the pixel buffer is only 160x120
> pixels large (the rest of the buffer is just unused...)!
>
> Any ideas on what could be going wrong here?
>
> thanks a lot,
> Daniel


Re: Data in IMediaSample half res of what it should be... by Daniel

Daniel
Wed Dec 06 07:11:43 CST 2006

On 27 Nov 2006 09:29:54 -0800, "Sai" <asai_76@yahoo.com> wrote:

>Did you check GetActualDataLength()?

No, but how would that help?
The image in that memory block is half of the size it should be, no
doubt about that.

I just want to know if there's something I could have done wrong (e.g.
during setting up the DirectShow graph) or if this is a bug in the
DirectShow driver of that device...

Daniel

Re: Data in IMediaSample half res of what it should be... by Sai

Sai
Mon Dec 11 10:39:05 CST 2006

Is SetFormat on the video stream succeeding? If yes and you are still
getting a default size then there could be a bug in the driver that
gives you a spurious TRUE when you call SetFormat.


-Sai


Daniel wrote:
> On 27 Nov 2006 09:29:54 -0800, "Sai" <asai_76@yahoo.com> wrote:
>
> >Did you check GetActualDataLength()?
>
> No, but how would that help?
> The image in that memory block is half of the size it should be, no
> doubt about that.
>
> I just want to know if there's something I could have done wrong (e.g.
> during setting up the DirectShow graph) or if this is a bug in the
> DirectShow driver of that device...
>
> Daniel