Image Processing software by command line - OfficinaTurini

Go to content
otIP
Image processing software by command line
This small program, executable from the command line, performs image processing functions with extreme ease.
You can convert a video (AVI) into a distinct series of images in the format you want, or you can stabilize, edit and apply various functions to it.
The program does not require installation but you can download it in any directory of your hard disk and run it from there ...
Chances are that if it doesn't work for you, you need the C ++ libraries listed below ....

If this application is to your liking and you want to contribute to its development and improvement, you can make a donation .... Thanks!
Questo piccolo programma, eseguibile dalla linea di comando, esegue funzioni di elaborazione dell'immagine con una estrema facilitá.
Puoi convertire un video (AVI) in una distinta serie di immagini nel formato che desideri, oppure lo puoi stabilizzare, editare e applicarvi funzioni varie.
Il programma non necessita di istallazione ma lo puoi scaricare in una qualunque directory del tuo hard disk e da lí eseguirlo ...
É probabile che se non ti funziona tu abbia bisogno delle librerie C++ di cui sotto trovi il link ....

Se questa applicazione é di tuo gradimento e vuoi contribuire al suo sviluppo e miglioramento puoi fare una donazione .... Grazie!
Try: otIP -help to show this ... and below a batch example
hlp.txt     otIP :: Command line image processing software
    Rev. 0.0.1 alpha
    (C) 2021 Officina Turini - All Rights Reserved
    Latest updates:
https://www.officinaturini.com/

*** otIP Help ****************************************************************
******************************************************************************

| General syntax: otIP -command parameter [param:value]                      |
| COMMANDS-+--------------------[ DESCRIPTION ]------------------------------+
| avi2pix  | Convert an AVI video into a series of images                    |
|          +- Parameters -------+- Description ------------------------------+
|          | file.avi           | First parameter specify an AVI file that   |
|          |                    | include its path. Not all AVI can be       |
|          |                    | loaded but only DIVX or compatible         |
+----------+--------------------+--------------------------------------------+
|          | [end:nnnn]         | Where nnnn is the last frame to read.      |
|          |                    | Default: Last available frame              |
+----------+--------------------+--------------------------------------------+
|          | [ext:format]       | Where format is the desired file format.   |
|          |                    | Default: jpg                               |
|          |                    | File formats are supported:                |
|          |                    | Windows bitmaps - *.bmp, *.dib             |
|          |                    | JPEG files - *.jpeg, *.jpg, *.jpe          |
|          |                    | JPEG 2000 files - *.jp2                    |
|          |                    | Portable Network Graphics - *.png          |
|          |                    | WebP - *.webp                              |
|          |                    | Portable - *.pbm, *.pgm, *.ppm *.pxm, *.pnm|
|          |                    | PFM files - *.pfm                          |
|          |                    | Sun rasters - *.sr, *.ras                  |
|          |                    | TIFF files - *.tiff, *.tif                 |
|          |                    | OpenEXR Image files - *.exr                |
|          |                    | Radiance HDR - *.hdr, *.pic                |
+----------+--------------------+--------------------------------------------+
|          | [inc:nnnn]         | Where nnnn is the frame increment to be    |
|          |                    | performed. Default: 1                      |
+----------+--------------------+--------------------------------------------+
|          | [name:text]        | Where text is the prefix used to create the|
|          |                    | file name. Default: img                    |
+----------+--------------------+--------------------------------------------+
|          | [output:path]      | Where path indicates the path where to save|
|          |                    | the files. Default: .\output\              |
+----------+--------------------+--------------------------------------------+
|          | [start:nnnn]       | Where nnnn is the first frame to read.     |
|          |                    | Default: 0                                 |
+----------+--------------------+--------------------------------------------+
|          | [ipSwitch]         | See image process switch                   |
+----------+--------------------+--------------------------------------------+
| aviedit  | Video editing                                                   |
|          +- Parameters -------+- Description ------------------------------+
|          | src.avi            | Video to edit                              |
+----------+--------------------+--------------------------------------------+
|          | dst.avi            | Final video file                           |
+----------+--------------------+--------------------------------------------+
|          | [end:nnnn]         | Where nnnn is the last frame to read.      |
|          |                    | Default: Last available frame              |
+----------+--------------------+--------------------------------------------+
|          | [start:nnnn]       | Where nnnn is the number of frames to skip |
|          |                    | from begin. Default: 0                     |
+----------+--------------------+--------------------------------------------+
|          | [ipSwitch]         | See image process switch                   |
+----------+--------------------+--------------------------------------------+
| aviinfo  | Show AVI informations                                           |
+----------+--------------------+--------------------------------------------+
| aviplay  | Video viewing                                                   |
|          +- Parameters -------+- Description ------------------------------+
|          | file.avi           | Video to view                              |
+----------+--------------------+--------------------------------------------+
|          | [ipSwitch]         | See image process switch                   |
+----------+--------------------+--------------------------------------------+
| avistab  | Video stabilization                                             |
|          +- Parameters -------+- Description ------------------------------+
|          | file.avi           | First parameter specify a video file that  |
|          |                    | must be stabilized.                        |
+----------+--------------------+--------------------------------------------+
|          | dst.avi            | Name of stabilized video file              |
+----------+--------------------+--------------------------------------------+
| convert  | Converts the contents of a directory from one image file format |
|          | to another, it require at least 3 params in the following order.|
|          +- Parameters -------+- Description ------------------------------+
|     1    | folder             | Folder path name where to search           |
+----------+--------------------+--------------------------------------------+
|     2    | wildString         | Wild char string, used to search file      |
+----------+--------------------+--------------------------------------------+
|     3    | extension          | Used extension for converted files.        |
+----------+-----------------------------------------------------------------+
|    ...   | [ipSwitch]         | See image process switch                   |
+----------+-----------------------------------------------------------------+
| help     | Show this help page                                             |
+----------+--------------------+--------------------------------------------+
| grab     | Video capturing from cameras                                    |
|          +- Parameters -------+- Description ------------------------------+
|          | filepath.avi       | path name of the AVI file                  |
+----------+--------------------+--------------------------------------------+
| pix2avi  | Convert all images within a directory to AVI video.             |
|          | It require at least 3 params in the following order.            |
|          +- Parameters -------+- Description ------------------------------+
|     1    | folder             | Folder path name where to search           |
+----------+--------------------+--------------------------------------------+
|     2    | wildString         | Wild char string, used to search file      |
+----------+--------------------+--------------------------------------------+
|     3    | out.avi            | Path name output video.                    |
+----------+-----------------------------------------------------------------+
|    ...   | [ipSwitch]         | See image process switch                   |
+----------+--------------------+--------------------------------------------+
|
IMAGE PROCESS SWITCH ***************************************************** |
| ************************************************************************** |
|
Warning the image processing functions are performed in the order of params|
+----------+--------------------+--------------------------------------------+

|          | [blur:n.nn]        | Blurs an image using a Gaussian filter.    |
|          |                    | n.nn is kernel standard deviation          |
|          |                    | Suggested n.nn 2,3,4,5,...                 |
+----------+--------------------+--------------------------------------------+
|          | [clahe:n.nn]       | Contrast Limited Adaptive Histogram        |
|          |                    | Equalization.                              |
|          |                    | n.nn is threshold for contrast limiting.   |
|          |                    | Suggested n.nn 4                           |
+----------+--------------------+--------------------------------------------+
|          | [comp:nnn]         | Where nnn is the compression factor used   |
|          |                    | in JPEG. Default: 80                       |
+----------+--------------------+--------------------------------------------+
|          | [denoise:h,tw,sw]  | Image denoising using Non-local Means      |
|          |                    | Denoising algorithm                        |
|          |                    | h =  Filter strength, suggested 3          |
|          |                    | tw = Template patch, suggested 7           |
|          |                    | sw = Weighted average, suggested 21        |
+----------+--------------------+--------------------------------------------+
|          | [flip:n]           | Where n specify flip mode:                 |
|          |                    | 0 means flipping around the x-axis         |
|          |                    | 1 means flipping around the y-axis         |
|          |                    | -1 means flipping around the xy-axis       |
|          |                    | performed. Default: disabled               |
+----------+--------------------+--------------------------------------------+
|          | [kelvin:]          | Instagram Filter! (^.^)                    |
+----------+--------------------+--------------------------------------------+
|          | [not:]             | Negate the image                           |
+----------+--------------------+--------------------------------------------+
|          | [pencil:]          | Image "pencil".                            |
|          |                    | Default: Not set                           |
+----------+--------------------+--------------------------------------------+
|          | [roi:sx,sy,dx,dy]  | Extract from the frame specified ROI.      |
|          |                    | sx,sy Start of ROI                         |
|          |                    | dx,dy Width and height of ROI              |
+----------+--------------------+--------------------------------------------+
|          | [rot:n.nn]         | Image rotation. Centered and clipped       |
|          |                    | rotation.                                  |
|          |                    | n.nn is the angle rotation.                |
+----------+--------------------+--------------------------------------------+
|          | [sharp:]           | Increase image details.                    |
+----------+--------------------+--------------------------------------------+
|          | [show:]            | When specified show saved frames.          |
|          |                    | Default: Not set                           |
+----------+--------------------+--------------------------------------------+
|          | [tobw:]            | When specified it converts color images to |
|          |                    | BW. Default: Not set                       |
+----------+--------------------+--------------------------------------------+
|          | [zoom:nnn]         | Where nnn specifies the enlargement or     |
|          |                    | reduction percentage of the images produced|
|          |                    | Default: 100                               |
+----------+--------------------+--------------------------------------------+
| EXAMPLES                                                                   |
+----------+--------------------+--------------------------------------------+

| otIP -avi2pix film.avi output:./pixmap/ show: tobw:                        |
| otIP -avi2pix film.avi output:./pixmap/ start:1000 end:10000 inc:25        |
| otIP -avi2pix film.avi output:./pixmap/                                    |
| otIP -avistab src.avi dst.avi                                              |
| otIP -convert .\output\ *.png jpg                                          |
| otIP -convert .\output\ *.png jpg denoise:3,7,21                           |
| otIP -help 50                                                              |
| otIP -aviedit video.avi out.avi start:1500 end:50000 not:                  |
| otIP -grab test.avi                                                        |
******************************************************************************
test.bat

rem *** Convert video 2.avi in a series of pictures.
rem ***     They are saved into OUTPUT (default) directory with the format JPEG (default)
otIP -avi2pix 2.avi

rem *** Noise remove for the video 2.avi, the function denoise is very slow!
otIp -aviedit 2.avi out.avi not: denoise:3,7,21

rem *** Get all images specified in the directory output to compose the video out.avi,
rem *** kelvin function is applied.

otIP -pix2avi output *.jpg out.avi kelvin:

rem *** Try to stabilize a video where there is a typical movement caused by an instability of
rem *** the camera.

otIP -avistab vs.avi vss.avi

rem *** Convert all JPEG images in the OUTPUT directory to PNG format,
rem *** also applies the PENCIL function.

otIP -convert output *.jpg png pencil:

Updated version: 2.0.0 - 18 November 2023, as x86 and x64
The program does not require installation, it is sufficient to unpack the archive and run the executable.
It may be that your system does not have the necessary libraries, therefore below you will find two Microsoft installations necessary for the relevant codes.
Tested on Win7/Win10 32 and 64 bit


System libraries you may need ....

Revision History:
  • 0.0.1 2021/12/24 : Libraries update
  • 2.0.0 2023/11/18 : Libraries update and full rebuild with 32bit a 64bit code
Free counters!
VAT: IT 02230330504
(C) 2016-2024 Officina Turini, Tutti i diritti riservati
Back to content