- Operating System: Windows 10
- Python 3.8.2
- Python Libraries:
- numpy – version 1.22.0
- opencv_python – version 4.5.5.62
- Pillow – version 9.0.1
- tqdm – version 4.62.3
- VLC Media Player 2.2.4
- Install Python 3.8.2 (including pip) if it is not already installed.
- Place all the provided .py Python files in an empty directory.
- Place the ‘requirements.txt’ file in the same directory.
- Open a command line terminal in the same directory.
- Run the following command to install the required Python libraries: pip install -r requirements.txt
- Video files used with the program must be .avi format. Other video formats will not work.
- Cover videos must be at least 8 times the resolution of the secret video. Example:
- Cover Video Resolution: 1920x1080 = 2,073,600 pixels
- Secret Video Resolution: 480×360 = 172,800 pixels
- 2,073,600 ÷ 127,800 ≈ 16. Cover video is 16 times the resolution of the secret video. They are compatible.
- Cover videos must not be longer than the secret video.
- Open a command line terminal in the directory containing the .py Python files.
- Place a cover video and a secret video in the same directory.
- cover_test.avi and secret_test.avi located in the test_files directory are example files that can be used for testing.
- Run the following command with the inputs replaced with your desired parameters:
python main.py encode
Parameters:
- - name of the cover video file that you wish to encode. Example: cover_test.avi
- - name of the secret video file that you wish to hide. Example: secret_test.avi
- - number 1-255 that you want to use for encryption. Example: 1
- - name for the program to use for the output encoded video file. Example encoded.avi
- Encoded file should be playable in VLC Media Player.
- Open a command line terminal in the directory containing the .py Python files.
- Place a previously encoded video file in the same directory.
- Run the following command with the inputs replaced with your desired parameters:
python main.py decode
Parameters:
- - name of the encoded video file that you wish to decode. Example: encoded.avi
- - number 1-255 that you want to use for decryption. Example: 1
- - name for the program to use for the output decoded video file. Example decoded.avi
- Decoded file should be playable in VLC Media Player.
- Follow the installation instructions on two separate computers that are on the same local network.
- Choose which computer you want to use as the receiver and the other will be the sender.
- Find the local “IPv4 Address” of the receiver computer by running the ipconfig command in a terminal window on the chosen receiver computer.
- Open a command line terminal in the directory containing the .py Python files.
- Run the following command with the inputs replaced with your desired parameters:
python main.py receive
Parameter:
- - TCP destination port (a number from 1 to 65535) that you wish to use. Example: 8407
- Open a command line terminal in the directory containing the .py Python files.
- Place a previously encoded video file in the same directory.
- Run the following command with the inputs replaced with your desired parameters:
python main.py send
Parameters:
- - name of the encoded video file that you wish to send. Example: encoded.avi
- - IPv4 address of the receiver. Example: 192.168.1.14
- - TCP destination port (a number from 1 to 65535) that you wish to use. Example: 8407
- Follow the installation instructions on two separate computers that are on the same local network.
- Choose which computer you want to use as the receiver and the other will be the sender.
- Find the local “IPv4 Address” of the receiver computer by running the ipconfig command in a terminal window on the chosen receiver computer.
- Open a command line terminal in the directory containing the .py Python files.
- Run the following command with the inputs replaced with your desired parameters:
python main.py receive_stream
Parameters:
- - TCP destination port (a number from 1 to 65535) that you wish to use. Example: 8407
- - number 1-255 that you want to use for encryption. Example: 1
- The program will now start waiting for a connection from the sender.
- Start the script on the sender’s side.
- Once a connection is made, the decoding process will start.
- The video display will start when 85% of the total frames have been received and decoded.
- Open a command line terminal in the directory containing the .py Python files.
- Place a cover video and a secret video in the same directory.
- cover_480p.avi and secret_144p2.avi located in the test_files directory are example files that can be used for testing.
- Run the following command with the inputs replaced with your desired parameters:
python main.py transmit_stream
Parameters:
- - name of the secret video file that you wish to hide. Example: secret_test.avi
- - name of the cover video file that you wish to encode. Example: cover_test.avi
- - IPv4 address of the receiver. Example: 192.168.1.14
- - TCP destination port (a number from 1 to 65535) that you wish to use. Example: 8407
- - number 1-255 that you want to use for decryption. Example: 1
- A connection will be made with the receiver.
- The video stream will begin and complete once all the frames have been sent.