I tried getting this to work in PPro 7.0 but it wouldn't accept an HD video file. I've downloaded a trial of PPro CS5.5 ( I purchased it as well but will have to wait for the disc to arrive) and now the file is imported but it shows up as an audio with no video. The video does play just fine in Windows Media Player. The following is the GSpot report on the file:
Can anyone tell me any reason I can't import this file?
Thank you,
.....Gord
It doesn't really matter if you have QT installed for this file; it's not going to help either way. Premiere Pro does not support H.264 in an AVI container. We can fix this.
@ECHO OFF
for %%a in (*.avi) do ffmpeg -i "%%a" -vcodec copy -acodec copy -f mp4 -y "%%~na".mp4
It WORKED!!!!!
Thank you so much, Colin! It boggles my mind; how do you learn this stuff?
I have no idea what that code meant but I'm just very happy that it worked.![]()
Stupid question time: I assume that I can use that same .bat file with any video clips I get from this camera in the future?
Thanks again,
.....Gord
It boggles my mind; how do you learn this stuff?
I'd tell ya, but then... well... you know...
I have no idea what that code meant but I'm just very happy that it worked.
Well, it's not really "code" so much as commands. FFmpeg is a program that can do all sorts of video and audio converting, rewrapping, filtering, and other Stupid Video Tricks. The batch file (BAT) is simply a series of commands that tells FFmpeg what to do with a given set of inputs--in this case, it's telling FFmpeg to rewrap the AVI files, without conversion, into MP4 files. Premiere doesn't understand H.264 in an AVI container, but it does understand H.264 in an MP4 container.
In plain English, the batch is saying, "Look in this folder for anything with an AVI extension, copy the video and audio streams without converting them, repackage the streams in an MP4 container, and name the files the same as the input files, minus the original AVI extension." Simple when you know what it says ![]()
I assume that I can use that same .bat file with any video clips I get from this camera in the future?
Indeed, you can. It will actually work with however many clips you have in a folder, not just one. In fact, you may want to put FFmpeg in your C:\Windows\System32 folder, and that way you don't have to move the FFmpeg executable around. Any script/batch you use will know that it's in your "path" and can find it without specifying its location absolutely.
Anyway, glad it worked. Have fun ![]()
Insignia Model #NS-DV111080F
It was on sale at a great price but I should have remembered that sometimes you get what you pay for. I've never looked too closely at what this camcorder can do but now see that you can change the format to MOV. Maybe that would be better as a quick test I just did allowed me to import the file into PPro. I'm very new to this as all I've ever done with PPro before was making DVDs of family events from photos. Is the MOV format as good as AVI?
Thanks for the interest and assistance.
.....Gord
The container is largely irrelevant in the better/worse comparison here. If it records to MOV using H.264, and you can work with those files, you may as well do that. Check, however, that it's not using a different codec or is actually SD instead of HD. Using MediaInfo will give you details of the file.
A quick Google found some information
HD camera at 720p or 1080p using H.264 in either an AVI or MOV container... since I have seen other messages about 1080p problems, stick with 720p
Since AVI doesn't work and MOV does... use MOV (part of the Google results was that the "custom" AVI produced by the camera would not edit in any software other than what came with the camera... another reason to use MOV if that works for you)
Once you have the MOV file on your hard drive, See the 2nd post for NEW ITEM pointer http://forums.adobe.com/thread/770072?tstart=0 to be sure your sequence matches your file
There is also a camera discussion forum
Hi Colin,
This answer of yours re: 20 May,2011 in respose to Gordrocks, on H.264 intrigues me. I still use Premiere Pro 1.5.1 mainly for basic editing from a Canon HDV 20/
30/40 and it does a very good job. But, when I tried to Import a H.264mov clip form a Canon 5D mark II it stopped working.I decided to import the clips into Premiere Elements 4, render and convert to Microsoft avi /Uncompressed and then Import the files into PP and of course it worked.
However, your answer appears to be a more correct/direct way of fixing the issue. Would it work with Premiere Pro 1.5.1 ? I now use a i7 64 bit Quad Core with Windows Xp mode on Virtual PC from Windows Download and apart from the H.264 clips PP runs better than ever.
Regards,
Bob
Message was edited by: Bob Dix Photographer
Great! Thanks! I had to implement a fix for this for a full class of students, so instead of using the batchfile included in your response, I wrote a script that does essentially the same thing, but with a GUI to go along with it.
To use this script, do the following:
1. Download AutoIT from AutoIt Downloads - AutoItScript .
2. Install AutoIT. It includes SciTE, a script editor
3. Open SciTE and paste the script in it
4. Save the script to any accessible folder
5. Download FFMPEG from the link already provided (http://ffmpeg.zeranoe.com/builds/)
6. Use 7zip to unzip FFMPEG.EXE from that download. Place it in the same folder where you saved the script in step 3
7. Open the AutoIT script from step 3 in SciTE and hit F7 to compile to an EXE
8. In the folder from step 3, you should now have a neat EXE that you can run anywhere to convert H.264 AVI files in place to MP4.
The Script------------------------------------------------------
FileInstall('FFMPEG.EXE', @TempDir & '\FFMPEG.EXE', 1)
$ffmpeg_exe = @TempDir & '\FFMPEG.EXE' ;This string must match the FileInstall destination
MsgBox(64, 'H.264 AVI Fixer', 'Select the AVI files you want to convert to MP4.'&@CRLF&'Use CTRL or Shift to select multiple files.')
$dInit = @DesktopDir ;FileOpen dialog initial directory
$iFile = FileOpenDialog('Premiere Elements 10 Project', $dInit, '(*.avi)', 1 + 4)
;Error Checking
If @error Then
MsgBox(4096, "", "No File chosen. Exiting.")
Exit
EndIf
$rFile = StringSplit($iFile, '|') ;Split the input file string to its component parts.
;Results in an array with [0]=count, [1] = directory path, [2+] = filenames
If(StringInStr($iFile, '|')) Then
;Multiple files were selected. Loop through each of them.
For $i=2 To $rFile[0]
$filename_avi = $rFile[1] & '\' & $rFile[$i]
$filename_mp4 = $rFile[1] & '\' & StringReplace($rFile[$i], '.avi', '.mp4')
MsgBox(0, '', $filename_avi, 1)
RunWait($ffmpeg_exe & ' -i "' & $filename_avi & '" -vcodec copy -acodec copy -f mp4 -y "' & $filename_mp4 & '"')
Next
Else
;Single file was selected. Process it.
$filename_avi = $iFile
$filename_mp4 = StringReplace($iFile, '.avi', '.mp4')
MsgBox(0, '', $filename_avi, 1)
RunWait($ffmpeg_exe & ' -i "' & $filename_avi & '" -vcodec copy -acodec copy -f mp4 -y "' & $filename_mp4 & '"')
EndIf
MsgBox(0, 'H.264 Fixer', 'Complete')
Run('c:\windows\system32\explorer.exe ' & $rFile[1])
FileDelete($ffmpeg_exe)
Similarly, if you already have some projects that use AVI-wrapped H.264 files, you can use the below script to fix them. Disclaimer: It's a little sloppy because it opens the project and rewrites every AVI reference to an MP4. That said, it doesn't overwrite the original project. It makes a copy prepended with "FIXED - ".
To use this script, follow the same directions as the last post, but replace the previous script with this one below:
The Script - - - - - - - - - - - - - - - - - - - - - - - - - -
FileInstall('FFMPEG.EXE', @TempDir & '\FFMPEG.EXE', 1)
$ffmpeg_exe = @TempDir & '\FFMPEG.EXE' ;This string must match the FileInstall destination
MsgBox(64, 'H.264 AVI Fixer', 'Select your Adobe Premiere Elements 10 project. Your files will be converted to be more compatible with APE10')
If FileExists('C:\PEScratch10') Then
$dInit = 'c:\pescratch10'
ElseIf FileExists(@MyDocumentsDir & '\Adobe\Premiere Elements\10.0') Then
$dInit = @MyDocumentsDir & '\Adobe\Premiere Elements\10.0'
Else
$dInit = @DesktopDir
EndIf
;$dInit = @DesktopDir ;FileOpen dialog initial directory
$iFile = FileOpenDialog('Premiere Elements 10 Project', $dInit, '(*.prel)', 3)
;Error Checking
If @error Then
MsgBox(4096, "", "No File chosen. Exiting.")
Exit
EndIf
;-----------Get full path, directory name, and file name as individual variables
$fFullPath = $iFile
$fFullPathSplit = StringSplit($fFullPath, '\')
$fName = $fFullPathSPlit[$fFullPathSplit[0]] ;File name only
$fDirPath = '' ;Initialize variable for the Directory Path
For $i = 1 To $fFullPathSplit[0] - 1
if($i > 1) Then
$fDirPath = $fDirPath & '\'
EndIf
$fDirPath = $fDirPath & $fFullPathSplit[$i] ;Directory (without trailing slash) that contains the project
Next
#cs
MsgBox(0, 'Full Path' , $iFile)
MsgBox(0, 'Directory Path', $fDirPath)
MsgBox(0, 'File Name', $fName)
#ce
;----------Find all the AVI media referenced in the project
$hProject = FileOpen($fFullPath, 'R')
$sProject = FileRead($hProject)
;$medialist = StringRegExp($sProject,'(?i)<ActualMediaFilePath>.*\.AvI</ActualMedia FilePath>', 3) ;Get all ActualMediaFilePaths
$medialist = StringRegExp($sProject,'(?i)<FilePath>.*\.AvI</FilePath>', 3) ;Get all FilePaths
$medialist_error = @error
If IsArray($medialist) Then
For $i = 0 To UBound($medialist) - 1
;$filename = StringReplace(StringReplace($medialist[$i], '<ActualMediaFilePath>', ''), '</ActualMediaFilePath>', '')
$filename = StringReplace(StringReplace($medialist[$i], '<FilePath>', ''), '</FilePath>', '')
;Skip Rendered files, and iterate through all media found in the project XML.
If Not StringInStr($filename, 'Rendered') Then
;MsgBox(0, $medialist_error, 'Rewrapping ' & $filename)
$filename_avi = $filename
$filename_mp4 = StringReplace($filename, '.avi', '.mp4')
;Rewrap the AVI H.264 files as MP4 files.
RunWait($ffmpeg_exe & ' -i "' & $filename_avi & '" -vcodec copy -acodec copy -f mp4 -y "' & $filename_mp4 & '"')
EndIf
Next
;Rewrite the project XML to remove AVI references
$sProjectModified = StringReplace($sProject, '.avi', '.mp4')
FileDelete($fDirPath & '\FIXED - ' & $fName)
FileWrite($fDirPath & '\FIXED - ' & $fName, $sProjectModified)
MsgBox(64, 'Complete', 'Your fixed project is available at: ' & @CRLF & $fDirPath & '\FIXED - ' & $fName)
Run('C:\Windows\System32\Explorer.exe ' & $fDirPath)
MsgBox(48, 'Note!', 'When you open this project for the first time, it may complain about missing files.' & @CRLF & @CRLF & 'IF THIS HAPPENS CLICK "SKIP ALL"')
Else
MsgBox(16, 'Error', 'No media was detected in that project file.')
EndIf
Thanks for pointing me to FFMpeg. There's one problem, though. The rewrapped file contains the video, but no audio. How do I remedy this? Actually, what I should say is that premiere won't recongnize the audio in the rewrapped file, but the video is still intact. Even all my media players will play the mp4 with sound.
I have a similar problem with Premiere Pro not reading the video file. It is an AVI file; Gspot reports it to have a codec MP42 with name: S-Mpeg 4 version 2. It plays fine with VLC as well as Media Player. I installed K-Lite codecs because I thought it might help. The file was created from a legally purchased screen capture software. It plays the audio but doesn't sync with the video; moreover, the video is cropped. I am using Premier Pro CS 4 (sorry, but I couldn't get a response to it in the CS4 thread; I figured it should be relevant to most versions). Any help would be most appreciated.
The message you added into http://forums.adobe.com/message/4700297 does have responses to you
Since CS5 and newer are completely different programs (complete rewrite from 32bit to 64bit) you should stick to the CS4 forum, so if you do receive an answer that works, it will work with CS4
Hi Namilo 14,
i had the same issue. 1KB-Files and error in extracting the streams.
Then I tried to extract only the Videostream (and let the Audiostream recompile):
@ECHO OFF
for %%a in (*.avi) do ffmpeg -i "%%a" -vcodec copy -f mp4 -y "%%~na".mp4
this method worked for me
(please notice there is no -acodec copy in my code above in comparison to colins)
-EDIT-
As i see you have mov-files maybe this could work
@ECHO OFF
for %%a in (*.mov) do ffmpeg -i "%%a" -vcodec copy -f mp4 -y "%%~na".mp4
North America
Europe, Middle East and Africa
Asia Pacific