What is the safe and minimal file size to use ?

Locked
huayu
User
Posts:1
Joined:Thu Dec 29, 2011 9:34 pm
Are you a spambot?:no
What is the safe and minimal file size to use ?

Post by huayu » Thu Dec 29, 2011 9:44 pm

James Heinrich : Happy Holiday !
I read the forum and got you answering the question about reading from a remote file (vedio file on remote box in format: mp4/H.264/FFAC.) in the post : viewtopic.php?f=11&t=842

but I need to test remote Mp3 file, to save memory and better performance, what is the minimal size of GETID3_FREAD_BUFFER_SIZE I can use in following code ?

$tmpfname = tempnam("./", "mp4");
$buf = file_get_contents( $_REQUEST['filename'], false, null, 0, GETID3_FREAD_BUFFER_SIZE * 300);
file_put_contents( $tmpfname, $buf);
$info = $getID3->analyze( $tmpfname);
getid3_lib::CopyTagsToComments($info);


Thanks and best regards

-huayu

James Heinrich
getID3() v1 developer
Posts:1477
Joined:Fri May 04, 2001 4:00 pm
Are you a spambot?:no
Location:Northern Ontario, Canada
Contact:

Re: What is the safe and minimal file size to use ?

Post by James Heinrich » Thu Jan 05, 2012 3:17 am

See discussion in this previous thread:

viewtopic.php?t=1184
James Heinrich wrote:As I mentioned in this thread, ID3v2 size is highly variable -- it might be < 1kB, it might be > 1MB, depending on contents (especially embedded pictures). For the actual MP3 data portion, 32kB should be sufficient for any constant-bitrate file, but headerless VBR files, or corrupt files, could require considerably more to give reasonably accurate results.

Ocinka
User
Posts:1
Joined:Sat Jul 06, 2013 8:58 am
Are you a spambot?:no

Re: What is the safe and minimal file size to use ?

Post by Ocinka » Sun Jul 07, 2013 10:06 am

James Heinrich , Thanks for the help. It works..

Locked