Jump to content

Joining Large Video Files


Recommended Posts

Hi

Using Latest Beta.

In the process of using autoit to join some MPG video files

together, but hitting a problem on reading Larger files.

Seems ok with files with a combined size of < 100mb

but when i attempt the big stuff (ie 2x 550mb+) Autoit throws an

AutoIt ,Error Allocating Memory

errors out during the reading of the first large file.

Am i correct in assuming that the Beta DOES now support

binaryfile read + write.

Maybe I am missing some parameters to access binary files.

Below is a small portion of code where it is breaking down.

Just attempts to read one large video file but doesnt complete.

The only limitation i could find referenced was a max string

size of 2gig, which exceeds my current needs.

I have commented the line causing the error.

;$Filename = array stores the filenames of files to combine. element[1] contains the path. 
    For $x = 2 to UBound($FileName)-1
       $FileH   = FileOpen($Path & $FileName[$x], 0); open readonly.
        If $FileH = -1 Then
                MsgBox(0, "Error", "Unable to open file.")
            Exit
        EndIf
            
          $Data = FileRead($FileH);  This is where it crapping out, am i missing parameters?
    
    FileClose($FileH)
    Next

I know I can work around this by using the console copy commands to append the files, but i would like to do it in autoit.

Thanks for any assistance

HardCopy

ps My System Has 1gig ram

Contributions: UDF _DateYearFirstChildren are like Farts, you can just about stand your own.Why am I not a Vegetarian?...Well...my ancestors didn't fight & evolve to the Top of the food chain for me to survive on Salad

Link to comment
Share on other sites

$Data = FileRead($FileH); This is where it crapping out, am i missing parameters?

Maybe you could read and write it in smaller chunks, but be aware of partial chunks at the end of the file.

Are you sure that simple concatenation will merge video files?

Edited by Confuzzled
Link to comment
Share on other sites

Are you sure that simple concatenation will merge video files?

version1 MPG files definately ok.

It's not the joining that is the problem, its the reading of the larger files.

Reading in chunks is a workaround, but i'm interested to know why its puking on big binary file read.

Regards

HardCopy

Contributions: UDF _DateYearFirstChildren are like Farts, you can just about stand your own.Why am I not a Vegetarian?...Well...my ancestors didn't fight & evolve to the Top of the food chain for me to survive on Salad

Link to comment
Share on other sites

version1 MPG files definately ok.

It's not the joining that is the problem, its the reading of the larger files.

Reading in chunks is a workaround, but i'm interested to know why its puking on big binary file read.

Regards

HardCopy

I use a program called simple file Joiner http://www.peretek.com/sfj.php to do this.

The basic version is free.

2015 - Still no flying cars, instead blankets with sleeves.

Link to comment
Share on other sites

i have a newer 8mm video camera... can i play this to a file (how?) and attach a second similar file

i want to put it on a CD to give the the people for their wedding

8)

Valuator, I highly recommend you use scenalyzer live to pull DV files via the firewire port from your video camera onto your PC. (Not Free, but very cheap + worth every dollar)

Although before putting on to cd you will have to encode them first to mpegs, nero can do this, but be prepared for a wait while the files are encoded.

Anyhow, back to the original topic, yes i know programs are around to do what i want, but i like to re-invent the wheel!!!

Regards

HardCopy

Contributions: UDF _DateYearFirstChildren are like Farts, you can just about stand your own.Why am I not a Vegetarian?...Well...my ancestors didn't fight & evolve to the Top of the food chain for me to survive on Salad

Link to comment
Share on other sites

  • Moderators

Valuator, I highly recommend you use scenalyzer live to pull DV files via the firewire port from your video camera onto your PC. (Not Free, but very cheap + worth every dollar)

Although before putting on to cd you will have to encode them first to mpegs, nero can do this, but be prepared for a wait while the files are encoded.

Anyhow, back to the original topic, yes i know programs are around to do what i want, but i like to re-invent the wheel!!!

Regards

HardCopy

If I'm not mistaken HC... someone made a file splitter not to long ago an put it in the scripts and scraps forum... I think it was blademonkey (I'll see if I can find the thread).

Don't know if this helps, but maybe it will give you some ideas: http://www.autoitscript.com/forum/index.ph...ndpost&p=145171

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

i have a newer 8mm video camera... can i play this to a file (how?) and attach a second similar file

i want to put it on a CD to give the the people for their wedding

8)

@Valuater,

If you want ot PM me, I'll try to answer your video questions.

Link to comment
Share on other sites

If I'm not mistaken HC... someone made a file splitter not to long ago an put it in the scripts and scraps forum... I think it was blademonkey (I'll see if I can find the thread).

Thanks Smoke, Did see this in my searches and passed it off as it was dealing with purely text.

But you got me to rethink about the splitting concept. :think:

Sure enough Binary files can be handled same way, so now i just read in 1meg chunks, and append write

to the newfile. Seems to be working.

Thanks for idea.

HardCopy

This thread got like a chinese whisper... started about problem merging files, ended discussing valuators New Camera!!

:(

Contributions: UDF _DateYearFirstChildren are like Farts, you can just about stand your own.Why am I not a Vegetarian?...Well...my ancestors didn't fight & evolve to the Top of the food chain for me to survive on Salad

Link to comment
Share on other sites

  • Moderators

Thanks Smoke, Did see this in my searches and passed it off as it was dealing with purely text.

But you got me to rethink about the splitting concept. :(

Sure enough Binary files can be handled same way, so now i just read in 1meg chunks, and append write

to the newfile. Seems to be working.

Thanks for idea.

HardCopy

This thread got like a chinese whisper... started about problem merging files, ended discussing valuators New Camera!!

:)

Good deal!!

P.S. I need a new camera :think:

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Good deal!!

P.S. I need a new camera :(

DV is the only way to go. If you shoot indoors a lot, spend the extra $$ and get one with low light compensation features. Your videos will be much smoother (unless you use a light). I also would not buy one that shoots directly to dvd.

Just my $.02 worth... :think:

Edited by billmez
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...