Sponsored Content
Full Discussion: Pipeing Individual Echos
Top Forums UNIX for Dummies Questions & Answers Pipeing Individual Echos Post 302398841 by binlib on Thursday 25th of February 2010 06:26:33 PM
Old 02-25-2010
Your shoutout function (executed by the shell) actually flushs each line. To simulate the frame rendering program, I will use perl which can be told to do line flushing or not:
Code:
~$ cmd='print scalar localtime;sleep(5);print scalar localtime'
~$ perl -le"$cmd" 
Thu Feb 25 18:16:45 2010
Thu Feb 25 18:16:50 2010
~$ perl -le"$cmd" |while read x;do date "+%T $x";done
18:17:01 Thu Feb 25 18:16:56 2010
18:17:01 Thu Feb 25 18:17:01 2010
~$ perl -le"\$|=1;$cmd" |while read x;do date "+%T $x";done
18:17:05 Thu Feb 25 18:17:05 2010
18:17:10 Thu Feb 25 18:17:10 2010
~$ ssh -t localhost "perl -le'$cmd'" |while read x;do date "+%T $x";done
18:17:21 Thu Feb 25 18:17:21 2010
18:17:26 Thu Feb 25 18:17:26 2010

 

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Multiple echos and cuts too slow

Hi guys, hopefully this hasn't been asked before - couldn't see the question anywhere. I have a large number of timestamps (hh-mm-ss-millisecond) that I need to find the difference between e.g.: 14-11-07-513 14-11-07-644 Now the script that I have just knocked up is horrifically slow,... (4 Replies)
Discussion started by: dlam
4 Replies

2. Shell Programming and Scripting

Adding the individual columns of a matrix.

I have a huge matrix file containing some 1.5 million rows and 6000 columns. The matrix looks something like this: 1 2 3 4 5 6 7 8 9 3 4 5 I want to add all the numbers in the columns of this matrix and display the result to my stdout. This means that the numbers in the first column are: ... (2 Replies)
Discussion started by: shoaibjameel123
2 Replies

3. UNIX for Dummies Questions & Answers

Print individual rows.

Hi all, I have a file im reading with a for loop using: for i in $(cat filename) do etc. done the original file is 3 columns, this method prints it out into 3 rows, and i would like to just assign the first to rows (originally first two columns) to separate variables. What would be... (3 Replies)
Discussion started by: jgrosecl
3 Replies

4. HP-UX

Individual file size limit on HP-UX

I got a question on ulimit on HP-UX. I have a log file that gets more than 2 GB and the application crashes because it can not write to log. I browsed through the forum and found one very similar post on ulimit but that was not concluded. Did some analysis and below is some output. >getconf... (6 Replies)
Discussion started by: asutoshch
6 Replies

5. Shell Programming and Scripting

Unpack individual files from tarball

Say you don't want to unpack the whole thing, just individual files or directories within a .tgz. How to do this? (1 Reply)
Discussion started by: stevensw
1 Replies

6. Solaris

Auditing Individual Files

I have some Solaris 9 systems and I'm interested in using the "fm" audit class to track changes to sensitive files but it's too verbose for it to be auditing to that level for EVERY file, so I was wondering if there were a way of restricting the audit of those events to particular files. I... (0 Replies)
Discussion started by: thmnetwork
0 Replies

7. UNIX for Dummies Questions & Answers

Terminal telnet echos garbage

i am trying to make powerterm not echo back this charactor. ≥ When I press control-C I get it that telnet charactor/garbage echos back. how to turn off? where? what config? is there something in powerterm to switch on/off? I do not see it. Redhats offical statement is: "I... (10 Replies)
Discussion started by: olyanderson
10 Replies

8. Solaris

Individual usernames for the same login account

Hi There is an application installed on a server, that has a unique login account, but many users are using it with the same login name! How can we overcame this by creating individual accounts for the same application login account? (11 Replies)
Discussion started by: fretagi
11 Replies
yuvfps(1)							MJPEG tools manual							 yuvfps(1)

NAME
yuvfps - Converts to a different frame rate SYNOPSIS
yuvfps [-r Num:Den] [-s Num:Den] [-i Interlacing] [-I Interlacing] [-c] [-n] [-w] [-v 0-2] [-h] DESCRIPTION
yuvfps is a general (UP or DOWN) resampling utility that is provided to allow the generation of video streams with the frame rates required for each standard video format. yuvfps reads a YUV4MPEG stream from the standard input and outputs a YUV4MPEG stream to the standard output in which frames from the original ones are skipped (downsampling) or duplicated (upsampling). This allows for other mjpegtools that require a specific frame rate to process the stream. yuvfps uses by default Bresenham's algorithm to do the resampling so that the new video stream is similar to the original one. Note, how- ever, that downscaling is a non-reversible operation because frames are dropped. Moreover, the resulting video stream may not have the exact same duration as the original one if the new frame rate is not a whole multiple of the original rate. As an alternative to simply dropping or duplicating frames each output frame/field can be produced as a weighted average of the two tempo- rally closest input frames/fields. In this mode, yuvfps can also change the interlacing mode of the stream. yuvfps also can "fix" the framerate specified in the YUV4MPEG header. This allows for the generation of effects (fast-forwarding, slow motion) and also when the source stream has some framerate that is very close, but not exactly, the rate required for some standard video (for example, 24.9 vs 25). OPTIONS
-r Num:Den Specifies the resulting stream frame rate. -s Num:Den Ignores the frame rate in the input stream and assumes this frame rate for the input stream. -i Interlacing Specifies the interlacing mode of the resulting stream. The interlacing mode can be changed only when using the weighted average resampling mode (the -w option). p - progressive (non-interlaced) t - top-field first b - bottom-field first -I Interlacing Ignores the interlacing mode information in the input stream and assumes this interlacing mode for the input stream. The possible values are the same as for the -i option. -c Changes the stream header frame rate and interlacing mode in the output stream but copies frames from the original stream without changes. The -r and -i options specify the frame rate and interlacing mode for the output stream header. -n By default yuvfps tries to find a normalized framerate. Some programs create framerates like: 29969909:1000000 which is actually th typical NTSC framerate of 30000:1001. yuvfps prints out the normalizes values and the original when it starts. If you think the nor- malized value is not correct and want yuvfps to use the original given number you have to add that option. So yuvfps does not try to normalize the values. -w Produce each output frame/field as a weighted average of the two temporally closest input frames/fields instead of simply dropping or duplicating frames. The blending of two adjacent frames/fields reduces visible stepping compared to the default drop/duplicate algorithm but as a drawback it makes fast moving objects appear blurred and is much slower. -v [0,1,2] Set verbosity level. 0 = warnings and error messages only. 1 = add informative messages, like the framerate conversation information. 2 = add chatty debugging message, too. AUTHOR
This man page was written by Alfonso Garcia-Patino Barbolani. Johannes Lehtinen added information about the weighted average resampling mode and the related options. If you have questions, remarks, problems or you just want to contact the developers, the main mailing list for the MJPEG-tools is: mjpeg-users@lists.sourceforge.net For more info, see our website at http://mjpeg.sourceforge.net/ SEE ALSO
yuvscaler(1), mjpegtools(1), lavpipe(1), lav2yuv(1) mpeg2enc(1) MJPEG Linux Square 8 Jan 2006 yuvfps(1)
All times are GMT -4. The time now is 03:50 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy