D
D
Dark192015-05-22 13:03:58
PHP
Dark19, 2015-05-22 13:03:58

How to split video file into parts in php for SHA256 hashing?

Good afternoon. Actually the question is: how to split a video file into parts in php for SHA256 hashing?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
2
2vtlk, 2015-05-22
@2vtlk

Something like this3NVMnB

system('ffmpeg -i in.avi -f segment -segment_time 1 -vcodec copy -acodec copy out%03d.avi',$return);

This is a breakdown of one second

L
latteo, 2015-05-23
@latteo

You don't need to break it into pieces - php.net/manual/ru/function.hash-file.php
If you implement the algorithm yourself, then php calculates SHA256 very, very slowly.
The best thing in terms of speed is to find a system utility that can hash the entire file and call it via exec, system, etc

D
Dark19, 2015-05-24
@Dark19

1.pngHere is the diagram

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question