[FFmpeg-devel] [PATCH] Allow window caption to be set for ffplay

Robert Krüger krueger
Wed Mar 17 08:01:05 CET 2010


On 16.03.2010, at 22:43, M?ns Rullg?rd wrote:

> Michael Niedermayer <michaelni at gmx.at> writes:
> 
>> On Tue, Mar 16, 2010 at 11:35:10AM +0100, Robert Kr?ger wrote:
>>> 
>>> this patch adds an option to set the window caption. Provided this
>>> is deemed useful, one could argue if a reasonable default for this
>>> would be the input filename and not "FFplay".
>> 
>> a default of the filename + length in hh:mm as well as % of current position
>> seems even better
> 
> Agreed.  At least the filename, maybe not the dynamic information.
> 
>> btw, isnt there some standard way to set the caption of a program without
>> having to modify the program?
> 
> xterm uses -title, but not all the usual X tools support this.  Either
> way, title is the usual term for this, not caption.
> 

Attached is a patch with stefano's comments addressed, the default window title set to input filename, documentation (not sure if this is supposed to be part of main or advanced options, your call) and the parameter renamed to window_title to make it foolproof/self-describing but I don't care and will change it if someone sees this differently (btw I had called it caption because SDL seems to call it that but I agree that title is better).

@michael: I am not aware of a standard way to set the window title and thought SDL was my best bet to ensure it runs on all platforms and scripts using it are as portable across platforms as possible.

Regards,

Robert 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: ffplay_window_title.patch
Type: application/octet-stream
Size: 1942 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20100317/d0ad9485/attachment.obj>
-------------- next part --------------





More information about the ffmpeg-devel mailing list