Quantcast KVCD: AVS File Size Predicting Stuff? - digitalFAQ.com Forums [Archives]
  #1  
10-27-2002, 10:30 PM
twobit326 twobit326 is offline
Free Member
 
Join Date: May 2002
Location: Chattanooga. Tennessee
Posts: 89
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to twobit326
Hiyas, Um, when I load the file size thing into FitCD. I load TMPEG. And when I load John Q's FitCD file it says the following:

Script Error. THere is no function named "selectRangeEvery"
(C:\John Q\film.avs,line 14.

Here's my Fitcd script:

LoadPlugin("C:\Program Files\NimoCodec Pack\Mpeg2dec\MPEG2DEC.dll")
mpeg2source("C:\John Q\DVD2AVI Output.d2v")
#TemporalSmoother(2,2)
AddBorders(16,64,16,64)
#Trim(0,167009).FadeOut(150)
#ConvertToRGB24 # For TMPGEnc or VFAPI
#ResampleAudio(44100) # CCE 2.5 'crashfix' for Athlons
#== If you want this 'fix' permanently, edit the INI-file:
#== Under [AVSscript] set CCEcrashfix=1
###------------------- Start Of File Size Prediction -------------------###
#
IL = Framecount / 100 # interval length in frames.
SL = round(Framerate) # sample length in frames.
SelectRangeEvery(IL,SL)
### Final MPEG size = ( ( Total frames / Framerate) / 100 ) * (MPEG sample file size * .95) ###
#
###-----------------------End File Size Prediction----------------------###



****Note, I also tried the other 2 ways of writing the file size prediction thing. (The one linked to on VCDHelper and the updated one on the forums.)


Any help would be greatly appreciated.

Thanx,
Twobit326
Reply With Quote
Someday, 12:01 PM
admin's Avatar
Site Staff / Ad Manager
 
Join Date: Dec 2002
Posts: 42
Thanks: ∞
Thanked 42 Times in 42 Posts
  #2  
10-27-2002, 11:16 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Hi Twobit326,

Get a newer version of MPEG2DEC.dll. If you download DVD2SVCD, you'll get it in the package.

-kwag
Reply With Quote
  #3  
10-28-2002, 07:59 AM
twobit326 twobit326 is offline
Free Member
 
Join Date: May 2002
Location: Chattanooga. Tennessee
Posts: 89
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to twobit326
One more question. How much do I encode to get the file size prediction thing? It looked like 1 minuet but I might be wrong.

Thanx,
Twobit326
Reply With Quote
  #4  
10-28-2002, 09:35 AM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
The script is set up to take 100 snapshots of 1 second each.

-kwag
Reply With Quote
  #5  
10-28-2002, 04:54 PM
reman reman is offline
Free Member
 
Join Date: May 2002
Posts: 174
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
The script is set up to take 100 snapshots of 1 second each.-kwag
I have started to select a range so that the output is ~60 seconds and try to leave out the intro and credits. Works great! I have found it to be very close to actual file size.
__________________
Thanks!
reman
Reply With Quote
  #6  
10-29-2002, 07:26 AM
twobit326 twobit326 is offline
Free Member
 
Join Date: May 2002
Location: Chattanooga. Tennessee
Posts: 89
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to twobit326
thanx for the help.
Reply With Quote
  #7  
10-29-2002, 08:06 AM
reman reman is offline
Free Member
 
Join Date: May 2002
Posts: 174
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by kwag
The script is set up to take 100 snapshots of 1 second each.-kwag
Any way to make it take 60 snapshots of 1 second each and skip area at the beg. and end?
__________________
Thanks!
reman
Reply With Quote
  #8  
10-29-2002, 10:29 PM
muaddib muaddib is offline
Free Member
 
Join Date: Jun 2002
Location: São Paulo - Brasil
Posts: 879
Thanks: 0
Thanked 0 Times in 0 Posts
Hi reman,

I think that this script will do what you want:

Trim(Framerate*120, Framecount-(Framerate*600))
IL = Framecount / 60
SL = round(Framerate)
SelectRangeEvery(IL,SL)

It will discard the first 2 min of the beg. and 5 min of the end.
I haven't tried it... but I think it will work.
Reply With Quote
  #9  
10-30-2002, 01:37 AM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
muaddib,

Isn't "Framecount-(Framerate*600)) " trimming the last 10 minutes
Shouldn't it be: Trim(Framerate*120, Framecount-(Framerate*300))


-kwag
Reply With Quote
  #10  
10-30-2002, 03:26 PM
muaddib muaddib is offline
Free Member
 
Join Date: Jun 2002
Location: São Paulo - Brasil
Posts: 879
Thanks: 0
Thanked 0 Times in 0 Posts
Yep... you're absolutely right!

5*60 = 300 ... not 600
That should be the beer of last night...
Reply With Quote
  #11  
10-30-2002, 06:29 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Don't drink and post.
Only read if you drink
( That's why I don't post after 2:00 AM )

Salud!
-kwag
Reply With Quote
  #12  
10-31-2002, 12:58 AM
muaddib muaddib is offline
Free Member
 
Join Date: Jun 2002
Location: São Paulo - Brasil
Posts: 879
Thanks: 0
Thanked 0 Times in 0 Posts
Good advice! I'll try to follow it.
Ops... It's 3:00AM!!
Too late now...
Reply With Quote
  #13  
11-01-2002, 06:18 PM
reman reman is offline
Free Member
 
Join Date: May 2002
Posts: 174
Thanks: 0
Thanked 0 Times in 0 Posts
I really want to thank everyone! Great stuff! Might I suggest that you add a commented section that allows users to uncomment the 1 minute code with the trimming and then delete the original code?

__________________
Thanks!
reman
Reply With Quote
  #14  
11-01-2002, 08:52 PM
reman reman is offline
Free Member
 
Join Date: May 2002
Posts: 174
Thanks: 0
Thanked 0 Times in 0 Posts
Hello!

This produces an error when loading into TMPGenc. My guess is that the
Quote:
Trim(Framerate*120, Framecount-(Framerate*300))
line is not right. Should it not be a result type of line? Framecount = Trim(Framerate... OR Framerate = Trim(Framerate...?

Quote:
LoadPlugin("C:\Program Files\VCDEasy\FitCD_v104\mpeg2dec_dll\MPEG2DEC.dll ")
mpeg2source("G:\Video Files\movie\movie.d2v")
BilinearResize(480,320,0,0,720,480)
#TemporalSmoother(2,2)
AddBorders(32,80,32,80)
#Trim(0,160504).FadeOut(150)
#ConvertToRGB24 # For TMPGEnc or VFAPI
#ResampleAudio(44100) # CCE 2.5 'crashfix' for Athlons
#== If you want this 'fix' permanently, edit the INI-file:
#== Under [AVSscript] set CCEcrashfix=1

###--------------------- Start Of File Size Prediction ----------------------###

Trim(Framerate*120, Framecount-(Framerate*300))
IL = Framecount / 60 # interval length in frames
SL = round(Framerate) # sample length in frames
SelectRangeEvery(IL,SL)
## MPEG size = ((Total frames/Framerate)/100) * (MPEG sample file size * .95) ##

###------------------------End File Size Prediction--------------------------###
__________________
Thanks!
reman
Reply With Quote
  #15  
11-01-2002, 09:28 PM
kwag kwag is offline
Free Member
 
Join Date: Apr 2002
Location: Puerto Rico, USA
Posts: 13,537
Thanks: 0
Thanked 0 Times in 0 Posts
Hi reman,

I think this is what you're looking for

SF = round(FrameRate * 120) # Find start Frame
EF = round(Framecount - ( Framerate * 300 )) # Find end frame
TotalFrames = EF - SF # This is the new total number of frames
Trim(SF,EF) # Now trim it

IL = TotalFrames / 60 # interval length in frames # And do our stuff
SL = round(Framerate) # sample length in frames
SelectRangeEvery(IL,SL)

-kwag
Reply With Quote
Reply




Similar Threads
Thread Thread Starter Forum Replies Last Post
kvcd: set bitrate in TMPGenc, instead of file predicting? maikeru Video Encoding and Conversion 7 06-15-2003 08:42 PM
Avisynth: Predicting File Size for VBR ..... black prince Avisynth Scripting 73 03-11-2003 05:21 PM
Having trouble predicting actual finished file TCC Avisynth Scripting 12 02-23-2003 12:58 AM
DVD2SVCD: Predicting audio file size black prince Video Encoding and Conversion 9 11-15-2002 12:26 PM
KVCD: file predicting DVD to 1 cd-r disc? 2COOL Video Encoding and Conversion 0 10-14-2002 07:17 PM

Thread Tools



 
All times are GMT -5. The time now is 10:44 AM  —  vBulletin © Jelsoft Enterprises Ltd