[MPlayer-dev-eng] [PATCH] vf_screenshot, output filename corresponding to the played file

Ruslan Savchenko ruslan.savchenko at gmail.com
Sun Nov 23 17:59:26 CET 2008


On Sat, Nov 22, 2008 at 12:56 AM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Fri, Nov 21, 2008 at 02:17:32PM +0300, Ruslan Savchenko wrote:
>> On Mon, Nov 17, 2008 at 9:10 PM, Ruslan Savchenko
>> <ruslan.savchenko at gmail.com> wrote:
>> > 2008/11/15 Michael Niedermayer <michaelni at gmx.at>:
>> >> On Sat, Nov 15, 2008 at 03:03:41AM +0300, Ruslan Savchenko wrote:
>> >>> On Sat, Nov 15, 2008 at 2:47 AM, Michael Niedermayer <michaelni at gmx.at> wrote:
>> >>> > On Sat, Nov 15, 2008 at 02:28:03AM +0300, Ruslan Savchenko wrote:
>> >>> >> On Sat, Nov 15, 2008 at 1:16 AM, Michael Niedermayer <michaelni at gmx.at> wrote:
>> >>> >> > On Fri, Nov 14, 2008 at 10:24:47PM +0300, Ruslan Savchenko wrote:
>> >>
>> >> both attached patches look ok IMHO
>> >>
>> >
>> > Any news?
>> > I think I should wait until those will be applied/rejected before
>> > proposing next patches. Right?
>>
>> Since I get no response, I send the whole updated patch once again.
>
> well and i have to reject it as it contains changes that should be seperate
> patches. And actually are but the patch now contains them too.
> Do you think if noone applied a 2 line patch that someone will apply a much
> larger patch that contains these 2 lines as well ...
>
> Actually i would suggest that you split the filename and timestamp in name
> things in 2 patches as well.

I split the patch into 8 parts. I hope this is what you want. Also,
"fnametype" from previous patches is now "style" and "famebase" is
"basename".
All attached patches except of 0001 and 0008 refer to vf_screenshot.c.
Here is a brief explanation about each patch:

 0001-Move-filename-variable-to-global-in-mencoder.c.patch
    Move 'filename' variable outside main() to global in mencoder.c.
In mplayer.c 'filename' is already global.

0002-Replace-magic-number-102-by-SHOT_FNAME_LENGTH-macro.patch
    Define SHOT_FNAME_LENGTH and use it instead of magic numbers.

0003-Change-priv-fname-allocation-from-static-to-dynamic.patch
    Allocate priv->fname dynamically in gen_fname() and free it in
put_image(). Dynamic allocation is required by further patches.

0004-Add-m_option-structure-for-new-options-in-further-patches.patch
    Initialize options parser. Options will be introduced in further patches

0005-Added-a-style-option-to-print-timestamp-in-screens.patch
    If style is 0, then old-style screenshots "shotXXXX.png" are
emited. If style is 1, then screenshot file name will be like
"shot.[hh:mm:ss.ms].png", and if style is 2, screenshot name will be
like "shot.[hh-mm-ss.ms].png"

0006-cosmetics-in-gen_fname.patch
     Move old code to appropriate indentation inside switch.

0007-Added-a-basename-option-to-use-instead-of-shot-whe.patch
    Added a basename option to use instead of "shot" when style is 1
or 2 and mplayer's playing a file. If mplayer's playing a stream,
still "shot" will be used.

0008-Update-screenshot-section-in-man-page.patch
    Describe "style" and "basename" options to vf_screenshot in man page.

-- 
Regards,
savrus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Move-filename-variable-to-global-in-mencoder.c.patch
Type: application/octet-stream
Size: 534 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Replace-magic-number-102-by-SHOT_FNAME_LENGTH-macro.patch
Type: application/octet-stream
Size: 918 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-Change-priv-fname-allocation-from-static-to-dynamic.patch
Type: application/octet-stream
Size: 1822 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0004-Add-m_option-structure-for-new-options-in-further-patches.patch
Type: application/octet-stream
Size: 1606 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0003.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0005-Added-a-style-option-to-print-timestamp-in-screens.patch
Type: application/octet-stream
Size: 2710 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0004.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0006-cosmetics-in-gen_fname.patch
Type: application/octet-stream
Size: 1369 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0005.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0007-Added-a-basename-option-to-use-instead-of-shot-whe.patch
Type: application/octet-stream
Size: 2017 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0006.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0008-Update-screenshot-section-in-man-page.patch
Type: application/octet-stream
Size: 1304 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20081123/52c3006c/attachment-0007.obj>


More information about the MPlayer-dev-eng mailing list