; PureBasic Visual Designer v3.95 build 1485 (PB4Code) Global ver.s,comboheight.l If OSVersion()=1200 : comboheight.l=25 : EndIf If OSVersion()<>1200 : comboheight.l=20 : EndIf ver.s="v.0.19."+Str(#pb_editor_buildcount)+"."+Str(#pb_editor_compilecount) ;- Window Constants ; Enumeration #Window_0 EndEnumeration ;- Gadget Constants ; Enumeration #buttonopenfile #inputfilepath #Frame3D_0 #Text_0 #Text_1 #Text_2 #risoluzione #framerate #lenght #Text_4 #Text_5 #Text_6 #aspectratio #start #frames #dar #Frame3D_1 #Text_7 #topcrop #detectcrop #leftcrop #Text_8 #Text_9 #rightcrop #Text_11 #bottomcrop #preview #TrackBarres #arerror #Text_12 #width #Text_13 #height #Text_14 #Text_15 #Frame3D_3 #Panel_0 #outputfile #outputfilepath #paypal #String_20 #keyint #String_24 #vbitrate #Frame3D_4 #Frame3D_5 #String_26 #String_27 #String_28 #String_29 #Frame3D_6 #String_37 #abitrate #String_39 #channels #deinterlace #subspid #Frame3D_8 #addtoqueue #removequeuejob #startqueue #queue #Frame3D_9 #audiopid #mencoderbutton #turbo #mencoderpath #pass1 #pass2 #decoding #saveprofile #passcrf #audioaac #savepath #nero #neroquality #p8x8 #b8x8 #bframes #preset #mp3mode #i8x8 #set #copyvideo #dct8x8 #muxmkv #i4x4 #vbvmaxrate #novideo #vbvbufsize #nocabac #deletetempfile #mdeint #allpartition #normalize #me #filter #weightb #badapt #nochromame #mixedrefs #direct #itu #subme #p4x4 #dss #samplerate #resizer #aspectratioforced #audioenc #merange #manualbitrate #ffmpegsource #priority #denoise #refframes #keyintmin #deblockalpha #vbvinit #ffmpegpathbutton #ffmpegpath #ratetol #deblockbeta #trellis #pysstrenght #bpyramid #qpmin #scenecut #qpmax #aqmode #level #aqstrenght #qcomp #changefpsto #mvdegrain #encodeac3 #qmf #freeavs #nofastpskip #statusbar #cplxblur #qblur #mplayerpathbutton #mplayerpath #lavf #mkvcreatorpathbutton #mkvcreatorpath #mp4creatorpathbutton #mp4creatorpath #browsesubs #muxer #flac #subtitlepath #encrustsubs #nerobitrate #Frame3D_10 #neroq #muxsubs #nodctdecimate #showinfo #preset1 #analizer #analyzewith #bbias #ipratio #pbratio #chromaqpoffset #direct8x8 #mvrange #colormatrix #greyscale #eac3tocodec #mvrangethread #r8brain #deadzoneinter #deadzoneintra #enceac3to #aud #slowdown #speedup EndEnumeration ;- Image Plugins UsePNGImageDecoder() ;- Image Globals Global Image0 ;- Catch Images Image0 = CatchImage(0, ?Image0) ;- Images DataSection Image0: IncludeBinary "paypal_logo.png" EndDataSection If OSVersion()=1200 Global FontID1 FontID1=LoadFont(1,"Curier New",7) SetGadgetFont(#PB_Default,FontID1) EndIf Procedure Open_Window_0() If OpenWindow(#Window_0, 216, 0, 490, 515, "AutoX264 "+ver.s, #PB_Window_SystemMenu | #PB_Window_TitleBar|#PB_Window_MinimizeGadget) CreateStatusBar(#statusbar,WindowID(#Window_0)) ButtonGadget(#buttonopenfile, 20, 10, 90, comboheight.l, "Open File ...",#PB_Button_Default) StringGadget(#inputfilepath, 120, 10, 350, comboheight.l, "") Frame3DGadget(#Frame3D_0, 10, 60, 225, 110, "") TextGadget(#Text_0, 20, 80, 90, comboheight.l, "Resolution", #PB_Text_Center | #PB_Text_Border) TextGadget(#Text_1, 20, 110, 90, comboheight.l, "Frame Rate", #PB_Text_Center | #PB_Text_Border) StringGadget(#risoluzione, 120, 80, 110,comboheight.l, "") StringGadget(#framerate, 120, 110, 110, comboheight.l, "") TextGadget(#Text_4, 20, 140, 45, 20, "AR", #PB_Text_Center | #PB_Text_Border) StringGadget(#aspectratio, 70,140, 50, 20, "") TextGadget(#Text_6, 130, 140, 45, 20, "DAR", #PB_Text_Center | #PB_Text_Border) StringGadget(#dar, 180, 140, 50, 20, "") TextGadget(#Text_5, 255, 80, 45, comboheight.l, "Frames",#PB_Text_Center | #PB_Text_Border) StringGadget(#frames, 305, 80, 50, comboheight.l, "") TextGadget(#Text_2, 365, 80, 45, comboheight.l, "Lenght (sec)", #PB_Text_Center | #PB_Text_Border) StringGadget(#lenght, 415, 80, 50, comboheight.l, "") ButtonGadget(#analizer, 255, 110,100, comboheight.l, "Analyze with...") ComboBoxGadget(#analyzewith,365,110,100,comboheight.l) ButtonGadget(#showinfo, 255, 140,80, comboheight.l, "About Input") CheckBoxGadget(#lavf,345,140,120,comboheight.l,"Force Lavf Demuxer") TrackBarGadget(#TrackBarres, 182, 210, 295, 20, 0, 1000) TextGadget(#Text_12, 10, 180, 70, comboheight.l, "Width", #PB_Text_Center | #PB_Text_Border) StringGadget(#width, 10, 210, 70, comboheight.l, "") TextGadget(#Text_13, 100, 180, 70, comboheight.l, "Height",#PB_Text_Center | #PB_Text_Border) StringGadget(#height, 100, 210, 70, comboheight.l, "") TextGadget(#Text_14, 190, 180, 280, comboheight.l, "Set Resolution", #PB_Text_Center | #PB_Text_Border) TextGadget(#Text_15, 10, 465, 370, 20, "Buzzqw's AutoX264 GUI", #PB_Text_Center | #PB_Text_Border) Frame3DGadget(#Frame3D_3, 245, 60, 225, 110, "") ButtonGadget(#outputfile, 20, 40, 90,comboheight, "Save File ...") StringGadget(#outputfilepath, 120, 40, 350, comboheight, "") ImageGadget(#paypal, 390, 460, 85, 26, Image0) ;- Resize && Crop PanelGadget(#Panel_0, 10, 250, 470, 205) AddGadgetItem(#Panel_0, -1, "Resize && Crop") Frame3DGadget(#Frame3D_1, 8, 8, 330, 130, "Crop Values") TextGadget(#Text_7, 18, 38, 80, 20, "Top Crop ->", #PB_Text_Center | #PB_Text_Border) StringGadget(#topcrop, 108, 38, 70, 20, "") ButtonGadget(#detectcrop, 188, 28, 130, 30, "Detect Crop") StringGadget(#leftcrop, 18, 68, 70, 20, "") TextGadget(#Text_8, 98, 68, 70, 20, "<- Left Crop", #PB_Text_Center | #PB_Text_Border) TextGadget(#Text_9, 178, 68, 70, 20, "Right Crop->", #PB_Text_Center | #PB_Text_Border) StringGadget(#rightcrop, 258, 68, 60, 20, "") TextGadget(#Text_11, 18, 98, 80, 20, "Bottom Crop ->", #PB_Text_Center | #PB_Text_Border) StringGadget(#bottomcrop, 108, 98, 60, 20, "") TextGadget(#PB_Any, 178, 98, 70, 20, " AR Error" ,#PB_Text_Center | #PB_Text_Border) StringGadget(#arerror, 258, 98, 60, 20, "",#PB_String_ReadOnly) ButtonGadget(#preview, 348, 13, 110,55, "Preview") ButtonGadget(#start,348,78,110,55,"Start") TextGadget(#preset1,10, 146,90, comboheight, "Preset",#PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#preset,108,146,340,comboheight) AddGadgetItem(#preset,-1,"NONE") SetGadgetState(#preset,0) GadgetToolTip(#preset1,"Select a x264 MeGui profile. Remember to check "+Chr(34)+"Final MB/CRF"+Chr(34)+" for set final size") GadgetToolTip(#preset,"Select a x264 MeGui profile. Remember to check "+Chr(34)+"Final MB/CRF"+Chr(34)+" for set final size") ;-Basic X264 options AddGadgetItem(#Panel_0, -1, "Basic X264 options") OptionGadget(#pass1, 8, 8, 70, 20, "1 abr pass") OptionGadget(#pass2,90, 8, 50, 20, "2 pass") OptionGadget(#passcrf,155, 8, 75, 20, "1 crf pass") OptionGadget(#copyvideo, 248, 8, 80, 20, "Copy Video") OptionGadget(#novideo, 338, 8, 80, 20, "No Video") SetGadgetState(#passcrf,1) TextGadget(#PB_Any, 18, 78, 100, 20, "B frames", #PB_Text_Center | #PB_Text_Border) SpinGadget(#bframes, 128, 78, 70, 20,0,16,#PB_Spin_Numeric) SetGadgetState(#bframes,3) TextGadget(#String_24, 18, 48, 100, 20, "Final MB (or CRF)", #PB_Text_Center | #PB_Text_Border) StringGadget(#vbitrate, 128, 48, 70, 20, "", #PB_String_Numeric) SetGadgetText(#vbitrate,"18") CheckBoxGadget(#p8x8,18,108,50,20,"p8x8") CheckBoxGadget(#b8x8,70,108,50,20,"b8x8") CheckBoxGadget(#i8x8,120,108,50,20,"i8x8") CheckBoxGadget(#i4x4,170,108,50,20,"i4x4") CheckBoxGadget(#dct8x8,18,138,57,20,"8x8dct") CheckBoxGadget(#allpartition,80,138,110,20,"All partitions") Frame3DGadget(#Frame3D_4, 8, 28, 210, 140, "X264 Options") Frame3DGadget(#Frame3D_5, 238, 28, 210, 140, "X264 Options") StringGadget(#String_26, 248, 48, 80, comboheight, "Direct MV prediction mode", #PB_String_ReadOnly) StringGadget(#String_27, 248, 78, 80, comboheight, "Integer pixel motion estimation method", #PB_String_ReadOnly) StringGadget(#String_28, 248, 108, 80, comboheight, "Subpixel motion estimation and mode decision", #PB_String_ReadOnly) StringGadget(#String_29, 248, 138, 80, comboheight, "Adaptive B-frame decision method", #PB_String_ReadOnly) ComboBoxGadget(#direct, 338, 48, 100, comboheight.l) AddGadgetItem(#direct,-1,"none") AddGadgetItem(#direct,-1,"spatial") AddGadgetItem(#direct,-1,"temporal") AddGadgetItem(#direct,-1,"auto") SetGadgetState(#direct,3) ComboBoxGadget(#me, 338, 78, 100, comboheight.l) AddGadgetItem(#me,-1,"dia") AddGadgetItem(#me,-1,"hex") AddGadgetItem(#me,-1,"umh") AddGadgetItem(#me,-1,"esa") AddGadgetItem(#me,-1,"tesa") SetGadgetState(#me,1) ComboBoxGadget(#subme, 338, 108, 100, comboheight.l) AddGadgetItem(#subme,-1,"1: SAD mode decision, one qpel iteration") AddGadgetItem(#subme,-1,"2: SATD mode decision") AddGadgetItem(#subme,-1,"3: Progressively more qpel") AddGadgetItem(#subme,-1,"4: Progressively more qpel") AddGadgetItem(#subme,-1,"5: Progressively more qpel") AddGadgetItem(#subme,-1,"6: RD mode decision for I/P-frames") AddGadgetItem(#subme,-1,"7: RD mode decision for all frames") AddGadgetItem(#subme,-1,"8: RD refinement for I/P-frames") AddGadgetItem(#subme,-1,"9: RD refinement for all frames") SetGadgetState(#subme,5) ComboBoxGadget(#badapt, 338, 138,100, comboheight.l) AddGadgetItem(#badapt,-1,"0: Disabled") AddGadgetItem(#badapt,-1,"1: Fast") AddGadgetItem(#badapt,-1,"2: Optimal (slow with high --bframes)") SetGadgetState(#badapt,1) ;-Audio output options AddGadgetItem(#Panel_0, -1, "Audio output options") Frame3DGadget(#Frame3D_6, 8, 5, 220, 170, "General Audio Options") TextGadget(#PB_Any,18,20 ,110,20,"Encode audio to",#PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#audioenc,138,20,80,comboheight.l) AddGadgetItem(#audioenc,-1,"MP3 Audio") AddGadgetItem(#audioenc,-1,"AAC Audio") AddGadgetItem(#audioenc,-1,"Copy Audio") AddGadgetItem(#audioenc,-1,"No Audio") SetGadgetText(#audioenc,"AAC Audio") TextGadget(#String_37, 18, 50, 110, comboheight, "Audio Bitrate", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#abitrate, 138, 50, 80,comboheight.l,#PB_ComboBox_Editable) AddGadgetItem(#abitrate,-1,"320") AddGadgetItem(#abitrate,-1,"288") AddGadgetItem(#abitrate,-1,"256") AddGadgetItem(#abitrate,-1,"224") AddGadgetItem(#abitrate,-1,"192") AddGadgetItem(#abitrate,-1,"160") AddGadgetItem(#abitrate,-1,"128") AddGadgetItem(#abitrate,-1,"96") AddGadgetItem(#abitrate,-1,"64") AddGadgetItem(#abitrate,-1,"32") SetGadgetState(#abitrate,7) TextGadget(#String_39, 18, 80, 110,comboheight, "Audio Channels", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#channels, 138, 78, 80, comboheight.l) AddGadgetItem(#channels,-1,"1") AddGadgetItem(#channels,-1,"2") AddGadgetItem(#channels,-1,"6") SetGadgetState(#channels,1) TextGadget(#PB_Any,18,110,110,comboheight,"SampleRate (Hz)",#PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#samplerate,138,110,80,comboheight.l,#PB_ComboBox_Editable) AddGadgetItem(#samplerate,-1,"AUTO") AddGadgetItem(#samplerate,-1,"48000") AddGadgetItem(#samplerate,-1,"44100") AddGadgetItem(#samplerate,-1,"32000") AddGadgetItem(#samplerate,-1,"22050") SetGadgetState(#samplerate,0) TextGadget(#PB_Any,18,140,110,comboheight,"MP3 Mode",#PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#mp3mode,140,138,80,comboheight.l) AddGadgetItem(#mp3mode,-1,"cbr") AddGadgetItem(#mp3mode,-1,"abr") AddGadgetItem(#mp3mode,-1,"vbr") SetGadgetState(#mp3mode,1) CheckBoxGadget(#neroq,245,20,105, comboheight,"Encode with Nero") SpinGadget(#neroquality,355,20,60,comboheight,0,100,#PB_Spin_Numeric) SetGadgetState(#neroquality,35) TextGadget(#PB_Any,420,22,35,20,"Quality") CheckBoxGadget(#normalize,245,153,95,20,"Normalize Audio") SetGadgetState(#normalize,1) ;- Audio and subs selection AddGadgetItem(#Panel_0, -1, "Select Audio and Subs") ListIconGadget(#audiopid,8,18,215,155,"Audio PID", 130, #PB_ListIcon_CheckBoxes|#PB_ListIcon_GridLines) AddGadgetColumn(#audiopid,1,"Audio Codec Information",200) ListIconGadget(#subspid,243,18,215,155,"Subtitle. Use eac3to (mkv/vob/m2(ts) file)", 210, #PB_ListIcon_CheckBoxes|#PB_ListIcon_GridLines) ;-Video Filters AddGadgetItem(#Panel_0, -1, "Video Filters") Frame3DGadget(#PB_Any, 8, 8, 210, 130, "Mencoder Options") Frame3DGadget(#PB_Any, 238, 8, 210, 130, "Mencoder Options") TextGadget(#PB_Any, 18, 28, 100, comboheight, "Resizers", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#resizer, 128, 28, 80, comboheight.l) AddGadgetItem(#resizer,-1,"0 fast bilinear") AddGadgetItem(#resizer,-1,"1 bilinear") AddGadgetItem(#resizer,-1,"2 bicubic") AddGadgetItem(#resizer,-1,"3 experimental") AddGadgetItem(#resizer,-1,"4 nearest neighbor") AddGadgetItem(#resizer,-1,"5 area") AddGadgetItem(#resizer,-1,"6 luma bicubic / chroma bilinear") AddGadgetItem(#resizer,-1,"7 gauss") AddGadgetItem(#resizer,-1,"8 sincR") AddGadgetItem(#resizer,-1,"9 lanczos") AddGadgetItem(#resizer,-1,"10 natural bicubic spline") SetGadgetState(#resizer,2) TextGadget(#PB_Any, 18, 58, 100, comboheight, "Priority", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#priority, 128, 58, 80, comboheight.l) AddGadgetItem(#priority,-1,"idle") AddGadgetItem(#priority,-1,"belownormal") AddGadgetItem(#priority,-1,"normal") AddGadgetItem(#priority,-1,"abovenormal") AddGadgetItem(#priority,-1,"high") AddGadgetItem(#priority,-1,"realtime") SetGadgetState(#priority,0) TextGadget(#PB_Any, 18, 88, 100, comboheight, "Denoise", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#denoise, 128, 88, 80, comboheight.l) AddGadgetItem(#denoise,-1,"None") AddGadgetItem(#denoise,-1,"Light") AddGadgetItem(#denoise,-1,"Normal") AddGadgetItem(#denoise,-1,"Severe") SetGadgetState(#denoise,1) TextGadget(#PB_Any, 248, 58, 100, comboheight, "Aspect Ratio", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#aspectratioforced, 358, 58, 80, comboheight.l,#PB_ComboBox_Editable) AddGadgetItem(#aspectratioforced,-1,"Automatic") AddGadgetItem(#aspectratioforced,-1,"1") AddGadgetItem(#aspectratioforced,-1,"1.3333") AddGadgetItem(#aspectratioforced,-1,"1.7777") AddGadgetItem(#aspectratioforced,-1,"2.35") SetGadgetState(#aspectratioforced,0) TextGadget(#PB_Any,248, 28, 100, 20, "Manual Bitrate", #PB_Text_Center | #PB_Text_Border) StringGadget(#manualbitrate,358, 28, 80, comboheight.l,"",#PB_String_Numeric) TextGadget(#PB_Any,8, 148, 100, comboheight, "Deinterlace", #PB_Text_Center | #PB_Text_Border) ComboBoxGadget(#mdeint,118, 148, 330, comboheight.l) AddGadgetItem(#mdeint,-1,"none") AddGadgetItem(#mdeint,-1,"Progressive NTSC (29.97->23.976)") AddGadgetItem(#mdeint,-1,"Interlaced") AddGadgetItem(#mdeint,-1,"Telecine") AddGadgetItem(#mdeint,-1,"Mixed progressive and telecine") AddGadgetItem(#mdeint,-1,"Mixed progressive and interlaced") AddGadgetItem(#mdeint,-1,"Change framerate to 23.976") AddGadgetItem(#mdeint,-1,"Change framerate to 25") AddGadgetItem(#mdeint,-1,"Change framerate to 29.97") AddGadgetItem(#mdeint,-1,"Half Framerate") SetGadgetState(#mdeint,0) ;-More X264 options AddGadgetItem(#Panel_0, -1, "More X264 options") Frame3DGadget(#Frame3D_8, 8, 8, 230, 160, "More X264 options") CheckBoxGadget(#nocabac, 18, 25, 110, 20, " Disable CABAC") CheckBoxGadget(#turbo,138,25,95,20,"Turbo first pass") SetGadgetState(#turbo,1) StringGadget(#PB_Any, 18, 50, 110, 20, "Number of reference frames",#PB_String_ReadOnly) SpinGadget(#refframes,138,50,90,20,1,16,#PB_Spin_Numeric) SetGadgetState(#refframes,3) StringGadget(#PB_Any, 18, 80, 110, 20, "Deblock Alpha/Beta parameters",#PB_String_ReadOnly) StringGadget(#deblockalpha, 138, 80, 40, 20, "") StringGadget(#deblockbeta, 188, 80, 40, 20, "") StringGadget(#PB_Any, 18, 110,50, comboheight, "AQ method",#PB_String_ReadOnly) ComboBoxGadget(#aqmode,73,110,60,comboheight.l) AddGadgetItem(#aqmode,-1,"0: Disabled") AddGadgetItem(#aqmode,-1,"1: Avoid moving bits between frames") AddGadgetItem(#aqmode,-1,"2: Move bits between frames (by default)") SetGadgetState(#aqmode,2) StringGadget(#PB_Any, 138, 110,55, comboheight, "AQ strength",#PB_String_ReadOnly) StringGadget(#aqstrenght,198,110,35,comboheight,"1.0") StringGadget(#PB_Any, 18, 140,110, 20, "Psy-RD",#PB_String_ReadOnly) StringGadget(#pysstrenght,138,140,60,20,"1.0:0.0") Frame3DGadget(#Frame3D_9, 248, 8, 210, 160, "") CheckBoxGadget(#weightb,258,25,180,20,"Weighted prediction for B-frames") StringGadget(#PB_Any, 258,50,110, comboheight, "Maximum motion vector search range",#PB_String_ReadOnly) ComboBoxGadget(#merange,373,50,80,comboheight.l,#PB_ComboBox_Editable) AddGadgetItem(#merange,-1,"4") AddGadgetItem(#merange,-1,"8") AddGadgetItem(#merange,-1,"12") AddGadgetItem(#merange,-1,"16") AddGadgetItem(#merange,-1,"32") AddGadgetItem(#merange,-1,"64") SetGadgetState(#merange,3) StringGadget(#PB_Any, 258,80,110, comboheight, "Trellis RD quantization. Requires CABAC",#PB_String_ReadOnly) ComboBoxGadget(#trellis,373,80,80,comboheight.l) AddGadgetItem(#trellis,-1,"0: disabled") AddGadgetItem(#trellis,-1,"1: enabled only on the final encode of a MB") AddGadgetItem(#trellis,-1,"2: enabled on all mode decisions") SetGadgetState(#trellis,0) CheckBoxGadget(#nochromame,258,110,110,20,"no-chroma-me") CheckBoxGadget(#mixedrefs,373,110,80,20,"mixed-refs") CheckBoxGadget(#nodctdecimate,258,140,110,20,"no-dct-decimate") CheckBoxGadget(#nofastpskip,373,140,82,20,"no-fast-pskip") ;-More X264 Options (2) AddGadgetItem(#Panel_0, -1, "More X264 Options (2)") Frame3DGadget(#PB_Any, 8, 8, 230, 160, "More X264 options") Frame3DGadget(#PB_Any, 248, 8, 210, 160, "More X264 options") CheckBoxGadget(#bpyramid,18,25,180,20,"Keep some B-frames as references") StringGadget(#PB_Any,18,50,60, 20, "Maximum GOP size",#PB_String_ReadOnly) StringGadget(#keyint,83,50,35, 20, "250") StringGadget(#PB_Any,128,50,60, 20, "KeyInt min interval",#PB_String_ReadOnly) StringGadget(#keyintmin,193,50,35, 20, "126") StringGadget(#PB_Any,18,80,110, 20, "Specify level (as defined by Annex A)",#PB_String_ReadOnly) ComboBoxGadget(#level,133,80,90,comboheight.l) AddGadgetItem(#level,-1,"AUTO") AddGadgetItem(#level,-1,"5.1") AddGadgetItem(#level,-1,"5") AddGadgetItem(#level,-1,"4.2") AddGadgetItem(#level,-1,"4.1") AddGadgetItem(#level,-1,"4") AddGadgetItem(#level,-1,"3.2") AddGadgetItem(#level,-1,"3.1") AddGadgetItem(#level,-1,"3") AddGadgetItem(#level,-1,"2.2") AddGadgetItem(#level,-1,"2.1") AddGadgetItem(#level,-1,"2") AddGadgetItem(#level,-1,"1.3") AddGadgetItem(#level,-1,"1.2") AddGadgetItem(#level,-1,"1.1") AddGadgetItem(#level,-1,"1") SetGadgetState(#level,0) StringGadget(#PB_Any,18,110,110, 20, "Max local bitrate (kbit/s)",#PB_String_ReadOnly) StringGadget(#vbvmaxrate,133,110,90,20,"") StringGadget(#PB_Any,18,140,110, 20, "Enable CBR and set size of the VBV buffer (kbit)",#PB_String_ReadOnly) StringGadget(#vbvbufsize,133,140,90,20,"") StringGadget(#PB_Any,258,25,110, 20, "Initial VBV buffer occupancy",#PB_String_ReadOnly) StringGadget(#vbvinit,373,25,70,20,"") StringGadget(#PB_Any,258,50,110, 20, "QP curve compression: 0.0 => CBR, 1.0 => CQP",#PB_String_ReadOnly) StringGadget(#qcomp,373,50,70,20,"") StringGadget(#PB_Any,258,80,60, 20, "Min QP [10]",#PB_String_ReadOnly) StringGadget(#qpmin,323,80,30,20,"10") StringGadget(#PB_Any,358,80,60, 20, "Max QP [51]",#PB_String_ReadOnly) StringGadget(#qpmax,423,80,30,20,"51") StringGadget(#PB_Any,258,110,60, 20, "Ratetol",#PB_String_ReadOnly) StringGadget(#ratetol,323,110,30,20,"1") StringGadget(#PB_Any,358,110,60, 20, "Scenecut",#PB_String_ReadOnly) StringGadget(#scenecut,423,110,30,20,"40") StringGadget(#PB_Any,258,140,60, 20, "Temporal blur of the estimated frame complexity",#PB_String_ReadOnly) StringGadget(#cplxblur,323,140,30,20,"20") StringGadget(#PB_Any,358,140,60, 20, "Temporal blur of the quantization parameter",#PB_String_ReadOnly) StringGadget(#qblur,423,140,30,20,"0.5") ;-More X264 Options (3) AddGadgetItem(#Panel_0, -1, "More X264 Options (3)") Frame3DGadget(#PB_Any, 8, 8, 230, 140, "More X264 options") Frame3DGadget(#PB_Any, 248, 8, 210, 160, "More X264 options") StringGadget(#PB_Any,18,25,110, 20, "B frames bias",#PB_String_ReadOnly) StringGadget(#bbias,133,25,90,20,"0") StringGadget(#PB_Any,18,55,110, 20, "QP factor between I And P",#PB_String_ReadOnly) StringGadget(#ipratio,133,55,90,20,"1.40") StringGadget(#PB_Any,18,85,110, 20, "QP factor between P And B",#PB_String_ReadOnly) StringGadget(#pbratio,133,85,90,20,"1.30") StringGadget(#PB_Any,18,115,110, 20, "QP difference between chroma And luma",#PB_String_ReadOnly) StringGadget(#chromaqpoffset,133,115,90,20,"0") ButtonGadget(#saveprofile,8,155,120,comboheight.l,"Save X264 options") ;StringGadget(#PB_Any,18,145,110, 20, "Direct prediction size",#PB_String_ReadOnly) ;SpinGadget(#direct8x8,133,145,90,20,-1,1,#PB_Spin_Numeric) ;SetGadgetState(#direct8x8,1) StringGadget(#PB_Any,258,25,110, 20, "Maximum motion vector length",#PB_String_ReadOnly) StringGadget(#mvrange,373,25,70,20,"-1") StringGadget(#PB_Any,258,55,110, 20, "Maximum motion vector length",#PB_String_ReadOnly) StringGadget(#mvrangethread,373,55,70,20,"-1") StringGadget(#PB_Any,258,85,110, 20, "Set the size of the inter luma quantization deadzone",#PB_String_ReadOnly) StringGadget(#deadzoneinter,373,85,70,20,"21") StringGadget(#PB_Any,258,115,110, 20, "Set the size of the intra luma quantization deadzone",#PB_String_ReadOnly) StringGadget(#deadzoneintra,373,115,70,20,"11") CheckBoxGadget(#aud,258,145,150,20,"Use access unit delimiters") SetGadgetState(#aud,1) ;-Subtitles && Muxing && Encoding AddGadgetItem(#Panel_0, -1, "Subtitles && Muxing && Encoding") Frame3DGadget(#PB_Any, 8, 8, 445, 75, "Subtitle Options") ButtonGadget(#browsesubs,18,28,95,comboheight,"Browse Subtitle ...") StringGadget(#subtitlepath,128,28,300,comboheight,"") OptionGadget(#encrustsubs,18,58,180,comboheight,"Encrust Subtitle in Video file") OptionGadget(#muxsubs,218,58,180,comboheight,"Mux Subtitle in MP4/MKV file") SetGadgetState(#muxsubs,1) Frame3DGadget(#PB_Any, 8, 83, 445, 50, "Muxing Options") StringGadget(#PB_Any,18,103,100,comboheight,"Mux to ...",#PB_String_ReadOnly) ComboBoxGadget(#muxer,128,103,90,comboheight) CheckBoxGadget(#deletetempfile,238,103,120,comboheight,"Delete temporary files") Frame3DGadget(#PB_Any, 8,135, 445, 38, "Decoding Options") StringGadget(#PB_Any,18,150,120,comboheight,"Use CoDec ...",#PB_String_ReadOnly) ComboBoxGadget(#decoding,150,150,180,comboheight) AddGadgetItem(#decoding,-1,"Use MEncoder") SetGadgetState(#decoding,0) CheckBoxGadget(#itu, 350, 150,80,comboheight.l,"Follow ITU") SetGadgetState(#itu,0) ;-Queue AddGadgetItem(#Panel_0, -1, "Queue") Frame3DGadget(#PB_Any, 8,5, 450, 163, "") EditorGadget(#queue,18,18,430,110) ButtonGadget(#addtoqueue,18,140,80,comboheight,"Add to Queue") ButtonGadget(#removequeuejob,150,140,120,comboheight,"Remove selected job") ButtonGadget(#startqueue,320,140,80,comboheight,"Start Queue") ;-Program path AddGadgetItem(#Panel_0, -1, "Program Path") If OSVersion()=1200 : ButtonGadget(#mplayerpathbutton, 10, 18, 100, comboheight, "mplayer ...") : EndIf If OSVersion()=1200 : ButtonGadget(#mencoderbutton, 10, 48, 100, comboheight, "mencoder ...") : EndIf If OSVersion()=1200 : ButtonGadget(#mp4creatorpathbutton, 10, 78, 100, comboheight, "MP4Box ...") : EndIf If OSVersion()=1200 : ButtonGadget(#mkvcreatorpathbutton, 10, 108, 100, comboheight, "mkvmerge ...") : EndIf If OSVersion()=1200 : ButtonGadget(#ffmpegpathbutton, 10, 138, 100, comboheight, "ffmpeg ...") : EndIf If OSVersion()<>1200 : ButtonGadget(#mplayerpathbutton, 10, 18, 100, comboheight, "mplayer.exe ...") : EndIf If OSVersion()<>1200 : ButtonGadget(#mencoderbutton, 10, 48, 100, comboheight, "mencoder.exe ...") : EndIf If OSVersion()<>1200 : ButtonGadget(#mp4creatorpathbutton, 10, 78, 100, comboheight, "mp4box.exe ...") : EndIf If OSVersion()<>1200 : ButtonGadget(#mkvcreatorpathbutton, 10,108, 100, comboheight, "mkvmerge.exe ...") : EndIf If OSVersion()<>1200 : ButtonGadget(#ffmpegpathbutton, 10,138, 100, comboheight, "ffmpeg.exe ...") : EndIf StringGadget(#mplayerpath,128,18,300,comboheight,"") StringGadget(#mencoderpath,128,48,300,comboheight,"") StringGadget(#mp4creatorpath,128,78,300,comboheight,"") StringGadget(#mkvcreatorpath,128,108,300,comboheight,"") StringGadget(#ffmpegpath,128,138,300,comboheight,"") ButtonGadget(#savepath,150,158,180,comboheight,"Save programs path and settings") DisableGadget(#savepath,0) GadgetToolTip(#Frame3D_10,"This options override General Audio Options") GadgetToolTip(#enceac3to,"Use EAC3TO. Convert audio to those format") GadgetToolTip(#speedup,"Use EAC3TO. Convert 23.976 and 24.000 content to 25.000 fps") GadgetToolTip(#slowdown,"Use EAC3TO. Convert 25.000 and 24.000 content to 23.976 fps") GadgetToolTip(#r8brain,"Use EAC3TO. Use r8brain resampler instead of SSRC") GadgetToolTip(#changefpsto,"Use EAC3TO. Change FPS of audio file. Please note that this option will work only if you select Encode with Nero or Encode to FLAC or Encode to AC3") GadgetToolTip(#neroq,"Use EAC3TO. Encode Audio with neroAacEnc.exe. Nero AAC encoding quality (0 = lowest; 100 = highest)") GadgetToolTip(#neroquality,"Put NeroAacEnc.exe into applications folder") GadgetToolTip(#inputfilepath,"Select input file (video or audio files are ok)") GadgetToolTip(#risoluzione,"Width and Height of movie. You must first click on "+Chr(34)+"Analyze with..."+Chr(34)+" button") GadgetToolTip(#framerate,"Framerate of file") GadgetToolTip(#aspectratio,"Aspect Ratio before cropping. This value is used for computing correct height given width. You can read it on DVD back cover") GadgetToolTip(#dar,"Display Aspect Ratio. The Aspect Ratio after cropping") GadgetToolTip(#frames,"Number of frames. This value is used for computing bitrate") GadgetToolTip(#lenght,"Lenght, in seconds of movie. This value is used for computing bitrate") GadgetToolTip(#analizer,"You MUST click here for analyze file.") GadgetToolTip(#analyzewith,"Select your analyzer. Mplayer is good and detect also crop values. Mediainfo is excellent, but you must hit also "+Chr(34)+"Detect Crop"+Chr(34)+" for determining crop values") GadgetToolTip(#showinfo,"Click here for showing information about input file. AutoX264 will also suggest the decoder to use") GadgetToolTip(#lavf,"Force Mencoder to use Lavf demuxer. Usefull for M2TS") GadgetToolTip(#TrackBarres,"Move the slide for resize. You must first Analyze File") GadgetToolTip(#width,"Actual resized WIDTH") GadgetToolTip(#height,"Actual resized HEIGHT") GadgetToolTip(#outputfilepath,"Select output file. If you don't select output file name, AutoX264 will create one for you.. so .. yes, you can leave this blank") GadgetToolTip(#paypal,"Please click here. Any Donation is appreciated and will support my freeware applications :) ") GadgetToolTip(#topcrop,"Number of pixel cropped from TOP") GadgetToolTip(#leftcrop,"Number of pixel cropped from LEFT") GadgetToolTip(#rightcrop,"Number of pixel cropped from RIGHT") GadgetToolTip(#bottomcrop,"Number of pixel cropped from BOTTOM") GadgetToolTip(#detectcrop,"Click here for forcing Automatic Crop Detection") GadgetToolTip(#arerror,"This is the AR Error as given by resize and crop") GadgetToolTip(#preview,"Click here for a resized preview (with audio) of movie") GadgetToolTip(#start,"Click here for starting encoding!") GadgetToolTip(#preset,"These are MeGui X264 profiles. Select one's you prefer, BUT remember to check "+Chr(34)+"Final MB/CRF"+Chr(34)+" before encoding") GadgetToolTip(#pass1,"This option will force a 1 pass only encoding with average bitrate computed with "+Chr(34)+"Final MB (or CRF)"+Chr(34)+" value. Or specified in "+Chr(34)+"Manual Bitrate"+Chr(34)) GadgetToolTip(#pass2,"This option will force a 2 pass encoding with average bitrate computed with "+Chr(34)+"Final MB (or CRF)"+Chr(34)+" value. Or specified in "+Chr(34)+"Manual Bitrate"+Chr(34)) GadgetToolTip(#passcrf,"This option will force a 1 pass CRF encoding with a CRF specified by "+Chr(34)+"Final MB (or CRF)"+Chr(34)+" value.") GadgetToolTip(#copyvideo,"This will copy video as is, without encoding") GadgetToolTip(#novideo,"This will force AutoX264 to NOT encode video, but only audio") GadgetToolTip(#bframes,"Maximum number of consecutive B-frames between I- and P-frames (default: 0). Suggested 3") GadgetToolTip(#vbitrate,"This value is the final MB size of video. In CRF encoding this value is the CRF value to use") GadgetToolTip(#p8x8,"Enable types p16x8, p8x16, p8x8") GadgetToolTip(#b8x8,"Enable types b16x8, b8x16, b8x8") GadgetToolTip(#i8x8,"Enable type i8x8. i8x8 has no effect unless 8x8dct is enabled") GadgetToolTip(#i4x4,"Enable type i4x4") GadgetToolTip(#dct8x8,"Adaptive spatial transform size: allows macroblocks to choose between 4x4 and 8x8 DCT. Also allows the i8x8 macroblock type. Without this option, only 4x4 DCT is used") GadgetToolTip(#allpartition,"Enable all of the above types") GadgetToolTip(#direct,"Determines the type of motion prediction used for direct macroblocks in B-frames") GadgetToolTip(#me,"Select fullpixel motion estimation algorithm") GadgetToolTip(#subme,"Adjust subpel refinement quality. This parameter controls quality versus speed tradeoffs involved in the motion estimation decision process. subq=5 can compress up to 10% better than subq=1") GadgetToolTip(#badapt,"Automatically decides when to use B-frames and how many, up to the maximum specified above (default: on). If this option is disabled, then the maximum number of B-frames is used") GadgetToolTip(#normalize,"Normalize to 100% the audio file") GadgetToolTip(#abitrate,"Select the audio bitrate") GadgetToolTip(#channels,"Select audio channels of output audio") GadgetToolTip(#audiopid,"Select the audio to encode. You can hit the Preview button to see and ear the audio selected") GadgetToolTip(#samplerate,"Select sample rate of output file. Usually is better to leave it Auto") GadgetToolTip(#mp3mode,"Select the MP3 encoding mode. Can be Costant, Average or Variable bitrate") GadgetToolTip(#resizer,"Select resizer, from blur to sharpest one's") GadgetToolTip(#priority,"Select encoding priority. Only for windows and with Mencoder") GadgetToolTip(#denoise,"Apply HQDN3D denoise") GadgetToolTip(#aspectratioforced,"Force Aspect Ration in Mencoder option") GadgetToolTip(#manualbitrate,"Force bitrate to use. This value override the computed by AutoX264") GadgetToolTip(#mdeint,"Select Deinterlacer filters") GadgetToolTip(#nocabac,"Disable CABAC. You should NOT CHECK IT. CABAC will slightly slows down encoding and decoding, but should save 10-15% bitrate. Unless you are looking for decoding speed, you should not disable it.") GadgetToolTip(#turbo,"Fast first pass mode. During the first pass of a two or more pass encode it is possible to gain speed by disabling some options with negligible or even no impact on the final pass output quality.") GadgetToolTip(#refframes,"Number of previous frames used as predictors in B- and P-frames (default: 1). This is effective in anime, but in live-action material the improvements usually drop off very rapidly above 6 or so reference frames. This has no effect on decoding speed, but does increase the memory needed for decoding. Some decoders can only handle a maximum of 15 reference frames.") GadgetToolTip(#deblockalpha,"This adjusts thresholds for the H.264 in-loop deblocking filter. First, this parameter adjusts the maximum amount of change that the filter is allowed to cause on any one pixel. Secondly, this parameter affects the threshold for difference across the edge being filtered. A positive value reduces blocking artifacts more, but will also smear details.") GadgetToolTip(#deblockbeta,"This affects the detail threshold. Very detailed blocks are not filtered, since the smoothing caused by the filter would be more noticeable than the original blocking.") GadgetToolTip(#aqmode,"Defines how adaptive quantization (AQ) distributes bits") GadgetToolTip(#aqstrenght,"Controls how much adaptive quantization (AQ) reduces blocking and blurring in flat and textured areas (default: 1.0). A value of 0.5 will lead to weak AQ and less details, when a value of 1.5 will lead to strong AQ and more details.") GadgetToolTip(#pysstrenght,"Sets the strength of the psychovisua optimization.") GadgetToolTip(#weightb,"Use weighted prediction in B-frames. Without this option, bidirectionally predicted macroblocks give equal weight to each reference frame. With this option, the weights are determined by the temporal position of the B-frame relative to the references. Requires bframes > 1.") GadgetToolTip(#merange,"radius of exhaustive or multi-hexagon motion search (default: 16)") GadgetToolTip(#trellis,"rate-distortion optimal quantization") GadgetToolTip(#nochromame,"Takes into account chroma information during subpixel motion search (default: not checked). Requires subq>=5.") GadgetToolTip(#mixedrefs,"Allows each 8x8 or 16x8 motion partition to independently select a reference frame. Without this option, a whole macroblock must use the same reference. Requires frameref>1.") GadgetToolTip(#nodctdecimate,"Eliminate dct blocks in P-frames containing only a small single coefficient (default: not checked). This will remove some details, so it will save bits that can be spent again on other frames, hopefully raising overall subjective quality. If you are compressing non-anime content with a high target bitrate, you may want to disable this to preserve as much detail as possible.") GadgetToolTip(#nofastpskip,"Performs early skip detection in P-frames (default: not checked). This usually improves speed at no cost, but it can sometimes produce artifacts in areas with no details, like sky.") GadgetToolTip(#bpyramid,"Allows B-frames to be used as references for predicting other frames. For example, consider 3 consecutive B-frames: I0 B1 B2 B3 P4. Without this option, B-frames follow the same pattern as MPEG-[124]. So they are coded in the order I0 P4 B1 B2 B3, and all the B-frames are predicted from I0 and P4. With this option, they are coded as I0 P4 B2 B1 B3. B2 is the same as above, but B1 is predicted from I0 and B2, and B3 is predicted from B2 and P4. This usually results in slightly improved compression, at almost no speed cost. However, this is an experimental option: it is not fully tuned and may not always help. Requires bframes >= 2. Disadvantage: increases decoding delay to 2 frames.") GadgetToolTip(#keyint,"Sets maximum interval between IDR-frames (default: 250). Larger values save bits, thus improve quality, at the cost of seeking precision. Unlike MPEG-1/2/4, H.264 does not suffer from DCT drift with large values of keyint.") GadgetToolTip(#keyintmin,"Sets minimum interval between IDR-frames (default: 25). If scenecuts appear within this interval, they are still encoded as I-frames, but do not start a new GOP. In H.264, I-frames do not necessarily bound a closed GOP because it is allowable for a P-frame to be predicted from more frames than just the one frame before it (also see frameref). Therefore, I-frames are not necessarily seekable. IDR-frames restrict subsequent P-frames from referring to any frame prior to the IDR-frame.") GadgetToolTip(#level,"Set the bitstream’s level as defined by annex A of the H.264 standard (default: 51 - level 5.1). This is used for telling the decoder what capabilities it needs to support. Use this parameter only if you know what it means, and you have a need to set it.") GadgetToolTip(#vbvmaxrate,"maximum local bitrate, in kbits/second (default: disabled)") GadgetToolTip(#vbvbufsize,"averaging period for vbv_maxrate, in kbits (default: none, must be specified if vbv_maxrate is enabled)") GadgetToolTip(#vbvinit,"initial buffer occupancy, as a fraction of vbv_bufsize (default: 0.9)") GadgetToolTip(#qcomp,"quantizer compression (default: 0.6). A lower value makes the bitrate more constant, while a higher value makes the quantization parameter more constant.") GadgetToolTip(#qpmin,"Minimum quantizer, 10-30 seems to be a useful range (default: 10).") GadgetToolTip(#qpmax,"maximum quantizer (default: 51)") GadgetToolTip(#ratetol,"allowed variance in average bitrate (no particular units) (default: 1.0)") GadgetToolTip(#scenecut,"Controls how aggressively to insert extra I-frames (default: 40). With small values of scenecut, the codec often has to force an I-frame when it would exceed keyint. Good values of scenecut may find a better location for the I-frame. Large values use more I-frames than necessary, thus wasting bits. -1 disables scene-cut detection, so I-frames are inserted only once every other keyint frames, even if a scene-cut occurs earlier. This is not recommended and wastes bitrate as scenecuts encoded as P-frames are just as big as I-frames, but do not reset the keyint counter.") GadgetToolTip(#cplxblur,"Temporal blur of the estimated frame complexity, before curve compression (default: 20). Lower values allow the quantizer value to jump around more, higher values force it to vary more smoothly. cplx_blur ensures that each I-frame has quality comparable to the following P-frames, and ensures that alternating high and low complexity frames (e.g. low fps animation) do not waste bits on fluctuating quantizer.") GadgetToolTip(#qblur,"Temporal blur of the quantization parameter, after curve compression (default: 0.5). Lower values allow the quantizer value to jump around more, higher values force it to vary more smoothly.") GadgetToolTip(#bbias,"Controls the decision performed by b_adapt. A higher b_bias produces more B-frames (default: 0).") GadgetToolTip(#ipratio,"quantizer factor between I- and P-frames (default: 1.4)") GadgetToolTip(#pbratio,"quantizer factor between P- and B-frames (default: 1.3)") GadgetToolTip(#chromaqpoffset,"Use a different quantizer for chroma as compared to luma. Useful values are in the range <-2-2> (default: 0).") GadgetToolTip(#mvrange,"Maximum motion vector length [-1 (auto)]") GadgetToolTip(#mvrangethread,"Minimum buffer between threads [-1 (auto)]") GadgetToolTip(#deadzoneinter,"Set the size of the inter luma quantization deadzone for non-trellis quantization (default: 21). Lower values help to preserve fine details and film grain (typically useful for high bitrate/quality encode), while higher values help filter out these details to save bits that can be spent again on other macroblocks and frames (typically useful for bitrate-starved encodes). It is recommended that you start by tweaking deadzone_intra before changing this parameter.") GadgetToolTip(#deadzoneintra,"Set the size of the intra luma quantization deadzone for non-trellis quantization (default: 11). This option has the same effect as deadzone_inter except that it affects intra frames. It is recommended that you start by tweaking this parameter before changing deadzone_inter.") GadgetToolTip(#aud,"Use access unit delimiters") GadgetToolTip(#subtitlepath,"Browse for subtitle. Mencoder could handle SRT subtiles. Using AviSynth you can use any kind of subtitles (graphicalo or textual") GadgetToolTip(#encrustsubs,"Encrust subtile in video. You will always see the subtitle while playing video") GadgetToolTip(#muxsubs,"Mux subtitle in final video. You can enable or disable subtitles during playing") GadgetToolTip(#deletetempfile,"Delete temporay files created during encoding") GadgetToolTip(#muxer,"Select muxing type") GadgetToolTip(#decoding,"Select type of encoding/decoding. For using AviSynth based decoding you need installed AviSynth 2.58 installed") GadgetToolTip(#itu,"Compute resize following ITU standard. The WIDTH will be HEIGH*DAR*53.3333/52") GadgetToolTip(#filter,"Select a filter to use") GadgetToolTip(#qmf,"Apply a dynamic filtering based on motion analisys") GadgetToolTip(#mvdegrain,"Apply MVDegrain") GadgetToolTip(#colormatrix,"Apply ColorMatrix filter") GadgetToolTip(#greyscale,"Encode to GreyScale") GadgetToolTip(#addtoqueue,"Add current work to job list") GadgetToolTip(#removequeuejob,"Remove last job from queue") GadgetToolTip(#startqueue,"Start ALL queue listed") GadgetToolTip(#mplayerpathbutton,"Select the Mplayer to use") GadgetToolTip(#mencoderbutton,"Select the Mencoder to use") GadgetToolTip(#mp4creatorpathbutton,"Select the MP4Box to use") GadgetToolTip(#mkvcreatorpathbutton,"Select the MKVMerge to use") GadgetToolTip(#ffmpegpathbutton,"Select FFmpeg to use") GadgetToolTip(#savepath,"Save path of selected applications") GadgetToolTip(#freeavs,"This string will be written as last line of AviSynth Script") EndIf EndProcedure ; IDE Options = PureBasic 4.30 (Linux - x86) ; CursorPosition = 613 ; FirstLine = 580 ; Folding = - ; EnableXP ; EnableUser ; EnableOnError ; Executable = autox264.exe ; DisableDebugger ; CompileSourceDirectory ; EnableCompileCount = 47 ; EnableBuildCount = 3 ; EnableExeConstant ; EnableExeConstantxeConstant