save the streamed video

Samuel Hocevar sam at zoy.org
Sat Aug 10 16:17:55 CEST 2002


On Sat, Aug 10, 2002, Harshad Bhutada wrote:

> What I meant was this. I am sorry, if I did not put it correclty in the
> earlier post. I hope now I am clear.
> So coming back to the problem statement, I want to save_the_mpeg2 file on
> the other_end_of_the_network, so that I can then compare the original mpeg2
> and the saved one. Better still, if I could save it in YUV format.

   If there are network losses, both VLC's input layer and video decoder
will detect errors and simply skip the corresponding images. I don't
think VLC will help much more than a simple application sending indexed
packets.

> In the mean time, I am looking at the code, and I think, to save it in the
> YUV format, I'll have to look into the SDL_Overlay structure, and the
> pointers there in. Am I on the correct path ?

   You may use this structure, yes. But if you just want to save frames,
maybe the dummy plugin (activated using "--vout dummy") will be easier
to understand. Just edit plugins/dummy/vout_dummy.c and put anything you
want in the vout_Render() function. YUV data can be retrieved in the
following buffers:

    p_pic->p[0].p_pixels  - Y data
    p_pic->p[0].i_lines   - Y lines
    p_pic->p[0].i_pitch   - Y line length in bytes

    p_pic->p[1] ...       - same for U

    p_pic->p[2] ...       - same for V

Regards,
-- 
Sam.

-- 
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://www.videolan.org/lists.html
If you are in trouble, please contact <postmaster at videolan.org>



More information about the vlc-devel mailing list