- Node.js version 12 or later
- NPM
- Typescript
- FFmpeg installed on your system
- A video file and a watermark image file
- Clone or download the repository to your local machine
- In the terminal, navigate to the root directory of the repository
- Run the following command to install the dependencies:
$ npm install
The tool takes three arguments: the input video file, the output video file, and the watermark image file. To run the tool, open the terminal, navigate to the root directory of the repository, and run the following command:
$ tsc index.ts watermarker.ts
$ node index.js input.mp4 output.mp4 watermark.png
The tool will add the watermark image to the center of the input video file and save the result as the output video file. The output file will have the same format as the input file.
If the arguments are not passed, you will get an error message:
Open the demo folder to view a demo video and its added watermark
PR's / Reviews are welcome here. I'm always open to learning!.