Sponsored Content
Full Discussion: To call ffmpeg in a loop
Top Forums Shell Programming and Scripting To call ffmpeg in a loop Post 303012561 by colt on Tuesday 6th of February 2018 04:59:45 AM
Old 02-06-2018
To call ffmpeg in a loop

Hello, I was inquiring myself if it's possible to call ffmpeg in loop, an in each iteration, ffmpeg will pick one of the files in a directory and produce a new with a slightest different name. Can be as simple as a '*' in the beginning of the file name.

I know how to use ffmpeg to do the modifications that I want, my doubts are how to read all files through the loop, and how to tell ffmpeg that the output file name should be the same as the input plus some modification.

Thanks for your time.
 

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how to call shell script from pl/sql loop

Hello, I am doing a shell script which contain a pl/sql loop to search for 3 values, i would like to call another shell script inside this sql loop each time it find the values. so how can i call shell script from pl/sql using its variables, any idea? Here is idea about the code: my... (1 Reply)
Discussion started by: rosalinda
1 Replies

2. Shell Programming and Scripting

Call a infinite loop

Hi All, I need to run an infinite loop. requirement below: function1 --> creates a file file1 function2 ---> need to call if the file creates i am running these both function via a script --> script.sh i need to run the function1 first and if the file file1 creates then need to run the... (3 Replies)
Discussion started by: satyaranjon
3 Replies

3. Shell Programming and Scripting

call a function in for loop

Hi all, I am trying to call a function in for loop in the below format #!/bin/bash abc() { commands } for (( i=0; i<=10; i++ )) do abc done The error i am getting when trying to execute: syntax error: unexpected end of file canany one help me where i am going wrong?? (5 Replies)
Discussion started by: gsr_kashyap
5 Replies

4. UNIX for Advanced & Expert Users

System call failed with 127 .. after 500 times when called in loop

Hi Experts, I have a code like this. ===== #include.... int main() { int count = 0; while(1){ printf("\n Interation number is: %d \n ",count); rv = system(" test.sh > log.txt " ); if (-1 == rv) { printf("Could not generate static log: error... (12 Replies)
Discussion started by: binnyjeshan
12 Replies

5. Shell Programming and Scripting

Running ffmpeg in loop seems to change reading from file

Hi everyone, I am fairly new to shell scripting. I want to read in numbers from a file (one number per line). This works perfectly fine while read CurrentLine do echo $CurrentLine done < myfile and yields the correct output: 272 745 123 If I however run a ffmpeg... (2 Replies)
Discussion started by: Thriceguy
2 Replies

6. Shell Programming and Scripting

How to call a stored procedure inside a loop?

How to call a stored procedure inside a loop export PATH=$ORACLE_HOME/bin:$PATH ORACLE_SID=xxxx; export ORACLE_SID ORAENV_ASK=NO TODAY_DATE=$(date +"%Y%m%d") LOGFILE=/var/opt/gogd/cust/scripts/${TODAY_DATE}_sap_cust_rel.log echo 'Connected' PARCUST=sap_cust_rel.par sqlldr... (1 Reply)
Discussion started by: ashwanth
1 Replies

7. Shell Programming and Scripting

How to call a string by string from a file to use in for loop?

Hi, I have a below sql query. select * from table where name in ('${name}); I have a requirement to automate this as here i need to pass the string value name from txt file. The text file contains the differnet special characters and i have some 200 names in the text file as follows. 3"... (3 Replies)
Discussion started by: Samah
3 Replies

8. Windows & DOS: Issues & Discussions

Ffmpeg

Hello everyone, I am new here so forgive me if this is in the wrong place. I am new to shell script and am trying to write a script to use with a program called ffmpeg. Would this be something I could get help with here? set /p VIDEO=Enter full name of video file on desktop: md... (7 Replies)
Discussion started by: junorich
7 Replies
transcode(export)						 3th February 2008						 transcode(export)

NAME
transcode - export modules collection SYNOPSIS
transcode -y module[,module[,module]] [other options] COPYRIGHT
transcode is Copyright (C) 2001-2003 by Thomas Oestreich, 2003-2004 Tilmann Bitterberg, 2004-2010 Transcode Team ENCODER PARAMETERS STRING
Module-dependent parameters can be passed to encoder using the -F transcode(1) option: transcode -F codec_string Those parameters tune the general behaviour of the export module. More specific settings can fine-tune the export settings. Those settings are passed to export modules through module options or through the module configuration file; both configuration file and options can be present at same time: in that case, the options overrides the configuration file. Passing option strings to export modules is done like to pass options to filter modules: The syntax is: transcode -y vmod=options,amod=options see transcode_filter(1) for full reference and examples. The -F parameter has different meanings for different export modules, as documented on section below. ENCODER MODULES PARAMETERS
ffmpeg: The codec String for the codec you want to encode. Example values are -F mpeg4 or -F mpeg1video or -F huffyuv. To get a list of valid codecs, use -F list im: The name of the image format you want to export. Example values are '-F jpg' (default) or '-F png' or -F 'gif'. With -F jpg, -w gives quality in percent. With -F png, the first digit of -w gives compression level, the second one gives quality, so -w 95 selects best compression level (9) and 5 means PNG adaptive filtering. jpg: The quality of the JPEG encode in percent. Example values are '-F 75' (default) or '-F 100' mov: Syntax: -F "<vcodec>,<acodec>[,<parameters>]" <vcodec> = Videocodec to encode with. Default: "mjpa" <acodec> = Audiocodec to encode with. Default: "ima4" <parameters> = A comma seperated list of parameters to be passed to the codec. Note: You can use "list" instead of a video/audiocodec or parameter to get a list of supported options. mpeg: Syntax: -F "<base-profile>[,<resizer-mode>[,user-profile]]" <base-profile> can be one of '1' = MPEG 1 (default) 'b' = big MPEG 1 (experimental) 'v' = VCD 's' = SVCD '2' = MPEG2 'd' = DVD compliant <resizer-mode> can be one of 0 = disable resizer (default) 1 = 352x288 2 = 480x480 3 = 480x576 4 = 352x240 <user-profile> is a filename of the profile file. You can either specify the absolute path to the file or if you transcode will look for it in the directory where you started transcode. mpeg2enc: Syntax: -F "<base-profile>[,<options_string>]" <base-profile> can be one of '0' = Generic MPEG1 (default) '1' = Standard VCD '2' = User VCD '3' = Generic MPEG2 '4' = Standard SVCD '5' = User SVCD '6' = Manual parameter mode '8' = DVD <options_string> will be passed down to mpeg2enc untouched by transcode. Have a look at the manpage for mpeg2enc. raw: The name of the image format to use for uncompressed video. Examples are I420 (YUV 4:2:0 planar), YV12 (the same thing with U and V reversed), or UYVY (YUV 4:2:2 packed). Use "-F help" to get a list of formats. EXPORT MODULES
If no module is specified through the -y option, transcode will use the null module for both audio and video export. If a multiplex module is given, by giving three export module names instead the usual two, transcode will use the new-style encode/multiplex modules (still under development, see the encode and multiplex directories); if no multiplex module is given, the traditional export modules will be used. To see what export modules are avalaible for your transcode installation, do a ls -1 $( tcmodinfo -p )/export*.so A complete transcode installation has the following export modules: ac3 - (video) null | (audio) ac3 This module has no compile-time dependencies. At run-time ffmpeg must be present. Support for this module is good. Encodes audio (raw PCM) to AC3 via the ffmpeg binary. Supported processing formats: audio - PCM, video - none af6 - (video) Win32 dll | (audio) MPEG/AC3/PCM At compile-time libavifile must be available. At run-time libavifile and win32codecs must be present. Support for this module is good. Interface to the avifile library which allows the use of win32codec on the linux-x86 platform. Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RGB YUV divx5 - (video) DivX 5.xx | (audio) MPEG/AC3/PCM At compile-time libmp3lame (only for MPEG audio layer III) must be available. At run-time divx4linux (new) and libdivxencore.so must be present. Support for this module is good. Encodes MPEG4 video using the closed-source binaries from divx.com to an AVI container. Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RGB YUV dv - (video) Digital Video | (audio) MPEG/AC3/PCM At compile-time libdv and libmp3lame (only for MPEG audio layer III) must be available. At run-time libdv must be present. Support for this module is good. Encodes DV into an AVI container. DV is a codec developed by Sony and is often used in digital camcorders. Supported processing formats: audio - PCM AC3, video - RGB YUV dvraw - (video) Digital Video | (audio) PCM At compile-time libdv must be available. At run-time libdv must be present. Support for this module is good. Encodes DV into a DV file. DV is a codec developed by Sony and is often used in digital camcorders. A raw DV file can be played back into the camcorder. Supported processing formats: audio - PCM, video - RAW (pass-through) RGB YUV YUV422 ffmpeg - (video) * | (audio) MPEG/AC3/PCM At compile-time libmp3lame (only for MPEG audio layer III) must be available. This module has no run-time dependencies. Sup- port for this module is good. Encodes many different formats to both AVI and raw. Supported are mpeg1video, mpeg2video, mpeg4, mjpeg, h263, h263p, wmv1, wmv2, rv10, msmpeg4, msmpeg4v2, huffyuv and dvvideo. Supported processing formats: audio RAW (pass-through) PCM AC3, video - RGB YUV YUV422 im - (video) * | (audio) MPEG/AC3/PCM At compile-time libImageMagick must be available. This module has no run-time dependencies. Support for this module is good. Encodes image sequences by using the ImageMagick library. ImageMagick is able to handle a lot of different image formats such as png, jpg, miff, tiff, etc. Use -F to select the desired format. Supported processing formats: audio - RAW (pass-through) PCM, video - RGB YUV jpg - (video) * | (audio) MPEG/AC3/PCM At compile-time libjpeg must be available. This module has no run-time dependencies. Support for this module is good. Encodes jpg image sequences using libjpeg. Faster than ImageMagick. Use -F to select the compression quality. Supported processing formats: audio - RAW (pass-through) PCM, video - RGB YUV lame - (audio) MPEG 1/2 At compile-time libmp3lame (only for MPEG audio layer III) must be available. At run-time lame and sox must be present. Sup- port for this module is good. An audio-only encoder which drives the lame binary. The tool sox is used to do resampling if required. Encodes to a MP3 file. Supported processing formats: audio - PCM, video - none lzo - (video) LZO real-time compression | (audio) MPEG/AC3/PCM At compile-time liblzo and libmp3lame (only for MPEG audio layer III) must be available. This module has no run-time dependen- cies. Support for this module is good. Encodes video using a loss-less real-time LZO codec. This codec is a homegrown invention of transcode and is intended as an intermediate storage format. MPlayer can playback LZO-based AVI files as well. Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RAW (pass-through) RGB YUV DV mov - (video) * | (audio) * At compile-time libquicktime must be available. At run-time libquicktime must be present. Support for this module is fair. Interface to the quicktime library. Supported processing formats: audio - PCM, video - RAW (pass-through) RGB YUV YUV422 YUY2 mp2 - (video) null | (audio) MPEG 1/2 This module has no compile-time dependencies. At run-time ffmpeg and sox must be present. Support for this module is good. Encodes audio (raw PCM) to MPEG 1 Layer 2 audio aka mp2. Additionaly it can change the speed of the audio stream by a factor you can specify. See docs/export_mp2.txt. Supported processing formats: audio - PCM, video - none mp2enc - (audio) MPEG 1/2 At compile-time mjpegtools must be available. At run-time mp2enc must be present. Support for this module is good. Drives the mp2enc binary and writes an MP2 (MPEG1-Layer2) file. Useful for when encoding to SVCD to be multiplexed with mplex after encoding. Supported processing formats: audio - PCM, video - none mpeg2enc - (video) MPEG 1/2 At compile-time mjpegtools must be available. At run-time mpeg2enc must be present. Support for this module is good. Drives the mpeg2enc binary. mpeg2enc is a very feature rich MPEG encoder, have a look at its manpage. Encodes generic mpeg1, VCD, SVCD, MPEG2 and DVD type video. Supported processing formats: audio - none, video - RGB YUV null - (video) null | (audio) null This module has no compile-time dependencies. This module has no run-time dependencies. Support for this module is good. Data sink. Does nothing else than discarding data. Supported processing formats: audio - none, video - none ogg - (video) null | (audio) ogg This module has no compile-time dependencies. At run-time oggenc must be present. Support for this module is good. Drives the oggenc binary. Encodes an Ogg/Vorbis file. Resamples. Supported processing formats: audio - PCM, video - none ppm - (video) PPM/PGM | (audio) MPEG/AC3/PCM This module has no compile-time dependencies. This module has no run-time dependencies. Support for this module is good. Writes an image sequence of PGM or PPM files. PPM is an old format and there are several tools around to manipulate such files. Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RGB YUV pvm - (video) * | (audio) * At compile-time libpvm3 must be available. At run-time pvm must be present. Support for this module is good. Meta module. It allows transcode to be used in a PVM cluster. See docs/export_pvm.txt Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RAW (pass-through) RGB YUV DV YUV422 YUY2 raw - (video) * | (audio) MPEG/AC3/PCM This module has no compile-time dependencies. This module has no run-time dependencies. Support for this module is good. Can write uncompressed streams to an AVI file as well as raw mpeg2 files in pass-through mode. The image format for uncom- pressed streams can be selected with -F (use -F help to see available formats). Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RAW (pass-through) RGB YUV DV YUV422 toolame - (audio) MPEG 1/2 This module has no compile-time dependencies. At run-time toolame and sox must be present. Support for this module is good. Drives the toolame binary to create MP2 audio tracks. Sox is used for resampling if requested. Supported processing formats: audio - PCM, video - none wav - (audio) WAVE PCM This module has no compile-time dependencies. This module has no run-time dependencies. Support for this module is good. Creates WAVE PCM files with interleaved audio for stereo. Supported processing formats: audio - PCM, video - RAW (pass-through) RGB YUV xvid4 - (video) XviD 1.0.x series (aka API 4.0) | (audio) MPEG/AC3/PCM At compile-time libmp3lame (only for MPEG audio layer III) must be available. At run-time libxvidcore.so.4 must be present. Support for this module is good. Encodes MPEG4 video using the library available from xvid.org. Check out the library from xvidcvs using cvs -d :pserver:anonymous@cvs.xvid.org:/xvid co -rdev-api-4 xvidcore. There is also a tool available to create configuration files for this xvid version at http://zebra.fh-weingarten.de/transcode/xvid4conf. The output can either be an AVI file or a MPEG4 elementary stream (with -F raw). Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RGB YUV YUV422 yuv4mpeg - (video) YUV4MPEG2 | (audio) MPEG/AC3/PCM At compile-time mjpegtools must be available. This module has no run-time dependencies. Support for this module is good. Writes the uncompressed raw YUV data in a YUV4MPEG format as used by the lav* and mjpeg* tools. Supported processing formats: audio - RAW (pass-through) PCM AC3, video - RGB YUV AUTHORS
transcode was written by Thomas Oestreich <ostreich@theorie.physik.uni-goettingen.de> with contributions from many others. See AUTHORS for details. SEE ALSO
transcode(1), tcmodinfo(1), transcode_import(1), transcode_filter(1), 1 modules transcode(export)
All times are GMT -4. The time now is 02:01 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy