ffmpeg problem

krasymir

Joined: 2010-05-26
Posts: 5
Posted: Wed, 2010-05-26 13:18

как да се определи кои от секунда от видео файл за извличане на картинка с FFmpeg

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2010-05-26 14:17
Quote:
how to determine which of the second of the video file to extract the image with FFmpeg

Edit Movie -> Thumbnail -> Select the time offset to use for this item's thumbnail

Редактиране на филм -> Миникартинка -> Изберете време компенсира да използва за тази позиция на картинка
http://translate.google.com/#en|bg|Edit%20Movie%20-%3E%20Thumbnail%20-%3E%20Select%20the%20time%20offset%20to%20use%20for%20this%20item%27s%20thumbnail

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
krasymir

Joined: 2010-05-26
Posts: 5
Posted: Wed, 2010-05-26 18:47

"Искам всички миниатюри от видео файлове, които се подават от FFmpeg например в двадесет секунди автоматично.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2010-05-26 19:42

gallery2/modules/ffmpeg/classes/FfmpegToolkit.class:

switch ($operationName) {
    function performOperation($mimeType, $operationName, $sourceFilename, $destFilename, $parameters, $context = array()) {
    ...
    ...
            case 'convert-to-image/jpeg':
                $args = array('-f', 'mjpeg', '-t', '0.001', '-y', $tmpFilename);
                if (isset($context['ffmpeg.offset'])) {
                    array_unshift($args, '-ss', $context['ffmpeg.offset']);
                    unset($context['ffmpeg.offset']);
                }

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
krasymir

Joined: 2010-05-26
Posts: 5
Posted: Fri, 2010-05-28 04:23

Bulgarian to English translation

why in the same format Video Thumbnail some have some do not. Edit Movie => Thumbnail in 20sek. already have. how
determined all of 20sek. I want this to happen automatically 20sek. and not manually for each.
switch ($ operationName) (
function performOperation ($ mimeType, $ operationName, $ sourceFilename, $ destFilename, $ parameters, $ context = array ()) (
...
...
case 'convert-to-image/jpeg':
$ Args = array ('-f', 'mjpeg', '-t', '0 .001 ','-y ', $ tmpFilename);
if (isset ($ context ['ffmpeg.offset'])) (
array_unshift ($ args, '-ss', $ context ['ffmpeg.offset']);
unset ($ context ['ffmpeg.offset']);
)
where and what to do.

защо при един и същ формат видео някои имат миникартинки някои не. Edit Movie =>Thumbnail при 20сек. вече имат. как
се определя всички на 20сек. аз искам това да става автоматично на 20сек. а не ръчно за всеки един.
switch ($operationName) {
function performOperation($mimeType, $operationName, $sourceFilename, $destFilename, $parameters, $context = array()) {
...
...
case 'convert-to-image/jpeg':
$args = array('-f', 'mjpeg', '-t', '0.001', '-y', $tmpFilename);
if (isset($context['ffmpeg.offset'])) {
array_unshift($args, '-ss', $context['ffmpeg.offset']);
unset($context['ffmpeg.offset']);
}
къде и какво трябва да направя.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-05-28 12:43

in $ Args = array ('-f', 'mjpeg', '-t', '0.001 ','-y ', $ tmpFilename);
the 0.001 is offset in seconds - change that to 20.000

в $ Args = array ('-f', 'mjpeg', '-t', '0.001 ','-y ', $ tmpFilename);
на 0.001 се компенсира в секунда - промяна, която да 20.000

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
krasymir

Joined: 2010-05-26
Posts: 5
Posted: Wed, 2010-06-02 05:43

Does not work. If you do Edit Movie-Select the time offset to use for this item's thumbnail 20 works. What to do.