Any questions? Need some help?
sycor
Posts: 3 Joined: 26 Jan 2025, 20:46
Post
by sycor » 26 Jan 2025, 21:06
I'll start out by saying I have very little knowledge of coding. I had FileBot setup for a few years without issue. Unfortunately after updating Java yesterday and removing old information all of my presets were lost. It's completely on me for not having a backup of my backup.
On to the issue, I've been trying to rebuild my preset but cannot remember how I did part of it. Here is an example of the end result:
Code: Select all
Movie (1985) [640x480] [ENG] [2ch EAC3 224 kbps x264]
I've gotten everything figured out except how to get the $vc to put out x264 instead of AVC. I'd also like to have it show x265 instead of HEVC, all in the same bracket. And yes I know HEVC and x265 are not the same thing, but it's visually easier for me to see.
I've figured out how to do it as a stand alone [ ] but I can't get it to update within the bracket I want. Any help would be greatly appreciated.
Last edited by
sycor on 26 Jan 2025, 21:12, edited 2 times in total.
rednoah
The Source
Posts: 24009 Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:
Post
by rednoah » 27 Jan 2025, 02:41
sycor wrote: ↑ 26 Jan 2025, 21:06
I've gotten everything figured out except how to get the $vc to put out x264 instead of AVC. I'd also like to have it show x265 instead of HEVC, all in the same bracket. And yes I know HEVC and x265 are not the same thing, but it's visually easier for me to see.
{vc} will print
x264 if the file was encoded by
x264 according to the encoder settings embedded in the
MediaInfo properties . If
{vc} prints
AVC the the file was
not encoded by the
x264 encoder, or the metadata was stripped and so it's no longer possible to know with certainty which encoder was used.
What does the
MediaInfo Inspector say for the file at hand? See
[FAQ] How do I share MediaInfo properties? for details.
sycor
Posts: 3 Joined: 26 Jan 2025, 20:46
Post
by sycor » 27 Jan 2025, 15:45
It shows as AVC, which I get. But I know that using
Code: Select all
{vc.matches(/AVC/) ? " [x264]":""}
that I can have it show x264. However that does not work in the bracket with
. Even changing the $vc to vc.matches does not work and breaks the entire bracket. I know I had it setup before somehow but I can't remember and can't figure it out. I know I can just have it in a separate bracket however 90% of my library is named this way already and it's going to annoy me to have newer things different, and I don't want to redo the entire library.
Properties: Select all
# MediaInfoLib - v22.12
[General]
Count : 331
StreamCount : 1
StreamKind : General
StreamKind/String : General
StreamKindID : 0
UniqueID : 256452381310825373465848156796333301223
UniqueID/String : 256452381310825373465848156796333301223 (0xC0EEEE9AABCB28A720C2E693440B9DE7)
VideoCount : 1
AudioCount : 1
TextCount : 1
Video_Format_List : AVC
Video_Format_WithHint_List : AVC
Video_Codec_List : AVC
Audio_Format_List : E-AC-3
Audio_Format_WithHint_List : E-AC-3
Audio_Codec_List : E-AC-3
Audio_Language_List : English
Text_Format_List : UTF-8
Text_Format_WithHint_List : UTF-8
Text_Codec_List : UTF-8
Text_Language_List : English
rednoah
The Source
Posts: 24009 Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:
Post
by rednoah » 27 Jan 2025, 16:26
Note that you didn't post the complete media info table. I was particularly interested in the
Encoded_Library_Name property
(if any) of the
video stream, because
{vc} will yield
x264 if
Encoded_Library_Name looks something like this:
Properties: Select all
Encoded_Library : x264 - core 164
Encoded_Library/String : x264 core 164
Encoded_Library_Name : x264
Encoded_Library_Version : core 164
Encoded_Library_Settings : cabac=0 / ref=1 / deblock=1:-1:-1 / analyse=0:0 / me=dia / subme=5 / psy=0 / mixed_ref=0 / me_range=16 / chroma_me=1 / trellis=0 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=0 / threads=4 / lookahead_threads=1 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=2 / b_pyramid=0 / b_adapt=0 / b_bias=0 / direct=1 / weightb=0 / open_gop=0 / weightp=0 / keyint=24 / keyint_min=13 / scenecut=0 / intra_refresh=0 / rc_lookahead=0 / rc=2pass / mbtree=0 / bitrate=2350 / ratetol=1.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / vbv_maxrate=2350 / vbv_bufsize=2350 / nal_hrd=none / filler=0 / ip_ratio=1.40 / pb_ratio=1.30 / aq=0
If you want to "fake" the
x264 label for any generic
AVC file
(regardless of whether its actually using the x264 encoder or not) then you could do that like so:
You could then combine multiple values like so:
** Learn how {expressions} work and useful Helper Functions
sycor
Posts: 3 Joined: 26 Jan 2025, 20:46
Post
by sycor » 27 Jan 2025, 16:45
Sorry about that, I'm not used to this forum and couldn't figure out to not have it be a giant post. Here is the total one
Properties: Select all
# MediaInfoLib - v22.12
[General]
Count : 331
StreamCount : 1
StreamKind : General
StreamKind/String : General
StreamKindID : 0
UniqueID : 256452381310825373465848156796333301223
UniqueID/String : 256452381310825373465848156796333301223 (0xC0EEEE9AABCB28A720C2E693440B9DE7)
VideoCount : 1
AudioCount : 1
TextCount : 1
Video_Format_List : AVC
Video_Format_WithHint_List : AVC
Video_Codec_List : AVC
Audio_Format_List : E-AC-3
Audio_Format_WithHint_List : E-AC-3
Audio_Codec_List : E-AC-3
Audio_Language_List : English
Text_Format_List : UTF-8
Text_Format_WithHint_List : UTF-8
Text_Codec_List : UTF-8
Text_Language_List : English
CompleteName : E:\Data\Movie Stuff\Streamfab\transfer\Star Trek Section 31 (2025)\MacGyver (1985) s01e01 Pilot [SD] [AP] [640x480] [ENG] [2ch EAC3 224 kbps x264].mkv
FolderName : E:\Data\Movie Stuff\Streamfab\transfer\Star Trek Section 31 (2025)
FileNameExtension : MacGyver (1985) s01e01 Pilot [SD] [AP] [640x480] [ENG] [2ch EAC3 224 kbps x264].mkv
FileName : MacGyver (1985) s01e01 Pilot [SD] [AP] [640x480] [ENG] [2ch EAC3 224 kbps x264]
FileExtension : mkv
Format : Matroska
Format/String : Matroska
Format/Url : https://matroska.org/downloads/windows.html
Format/Extensions : mkv mk3d mka mks
Format_Commercial : Matroska
Format_Version : Version 4
FileSize : 437399757
FileSize/String : 417 MiB
FileSize/String1 : 417 MiB
FileSize/String2 : 417 MiB
FileSize/String3 : 417 MiB
FileSize/String4 : 417.1 MiB
Duration : 2890966
Duration/String : 48 min 10 s
Duration/String1 : 48 min 10 s 966 ms
Duration/String2 : 48 min 10 s
Duration/String3 : 00:48:10.966
Duration/String4 : 00:48:10:27
Duration/String5 : 00:48:10.966 (00:48:10:27)
OverallBitRate : 1210391
OverallBitRate/String : 1 210 kb/s
FrameRate : 30.000
FrameRate/String : 30.000 FPS
FrameCount : 86727
StreamSize : 786883
StreamSize/String : 768 KiB (0%)
StreamSize/String1 : 768 KiB
StreamSize/String2 : 768 KiB
StreamSize/String3 : 768 KiB
StreamSize/String4 : 768.4 KiB
StreamSize/String5 : 768 KiB (0%)
StreamSize_Proportion : 0.00180
IsStreamable : Yes
Encoded_Date : UTC 2021-05-17 19:08:29
File_Created_Date : UTC 2025-01-26 21:01:49.185
File_Created_Date_Local : 2025-01-26 16:01:49.185
File_Modified_Date : UTC 2025-01-26 19:41:26.302
File_Modified_Date_Local : 2025-01-26 14:41:26.302
Encoded_Application : mkvmerge v54.0.0 ('F Maj Pixie') 64-bit
Encoded_Application/String : mkvmerge v54.0.0 ('F Maj Pixie') 64-bit
Encoded_Library : libebml v1.4.2 + libmatroska v1.6.3
Encoded_Library/String : libebml v1.4.2 + libmatroska v1.6.3
[Video]
Count : 381
StreamCount : 1
StreamKind : Video
StreamKind/String : Video
StreamKindID : 0
StreamOrder : 0
ID : 1
ID/String : 1
UniqueID : 11365697534489493696
Format : AVC
Format/String : AVC
Format/Info : Advanced Video Codec
Format/Url : http://developers.videolan.org/x264.html
Format_Commercial : AVC
Format_Profile : Main@L3
Format_Settings : CABAC / 5 Ref Frames
Format_Settings_CABAC : Yes
Format_Settings_CABAC/String : Yes
Format_Settings_RefFrames : 5
Format_Settings_RefFrames/String : 5 frames
InternetMediaType : video/H264
CodecID : V_MPEG4/ISO/AVC
CodecID/Url : http://ffdshow-tryout.sourceforge.net/
Duration : 2890899.000000
Duration/String : 48 min 10 s
Duration/String1 : 48 min 10 s 899 ms
Duration/String2 : 48 min 10 s
Duration/String3 : 00:48:10.899
Duration/String4 : 00:48:10:27
Duration/String5 : 00:48:10.899 (00:48:10:27)
BitRate : 984176
BitRate/String : 984 kb/s
Width : 640
Width/String : 640 pixels
Height : 480
Height/String : 480 pixels
Sampled_Width : 640
Sampled_Height : 480
PixelAspectRatio : 1.000
DisplayAspectRatio : 1.333
DisplayAspectRatio/String : 4:3
FrameRate_Mode : CFR
FrameRate_Mode/String : Constant
FrameRate : 30.000
FrameRate/String : 30.000 FPS
FrameRate_Num : 30
FrameRate_Den : 1
FrameCount : 86727
ColorSpace : YUV
ChromaSubsampling : 4:2:0
ChromaSubsampling/String : 4:2:0
BitDepth : 8
BitDepth/String : 8 bits
ScanType : Progressive
ScanType/String : Progressive
Bits-(Pixel*Frame) : 0.107
Delay : 67
Delay/String : 67 ms
Delay/String1 : 67 ms
Delay/String2 : 67 ms
Delay/String3 : 00:00:00.067
Delay/String4 : 00:00:00:02
Delay/String5 : 00:00:00.067 (00:00:00:02)
Delay_Source : Container
Delay_Source/String : Container
StreamSize : 355644308
StreamSize/String : 339 MiB (81%)
StreamSize/String1 : 339 MiB
StreamSize/String2 : 339 MiB
StreamSize/String3 : 339 MiB
StreamSize/String4 : 339.2 MiB
StreamSize/String5 : 339 MiB (81%)
StreamSize_Proportion : 0.81309
Default : Yes
Default/String : Yes
Forced : No
Forced/String : No
colour_description_present : Yes
colour_description_present_Source : Stream
colour_range : Limited
colour_range_Source : Stream
colour_primaries : BT.709
colour_primaries_Source : Stream
transfer_characteristics : BT.709
transfer_characteristics_Source : Stream
matrix_coefficients : BT.709
matrix_coefficients_Source : Stream
[Audio]
Count : 301
StreamCount : 1
StreamKind : Audio
StreamKind/String : Audio
StreamKindID : 0
StreamOrder : 1
ID : 2
ID/String : 2
UniqueID : 17446476437416675934
Format : E-AC-3
Format/String : E-AC-3
Format/Info : Enhanced AC-3
Format/Url : https://en.wikipedia.org/wiki/Dolby_Digital_Plus
Format_Commercial : Dolby Digital Plus
Format_Commercial_IfAny : Dolby Digital Plus
Format_Settings_Endianness : Big
InternetMediaType : audio/eac3
CodecID : A_EAC3
Duration : 2890912.000000
Duration/String : 48 min 10 s
Duration/String1 : 48 min 10 s 912 ms
Duration/String2 : 48 min 10 s
Duration/String3 : 00:48:10.912
Duration/String5 : 00:48:10.912
BitRate_Mode : CBR
BitRate_Mode/String : Constant
BitRate : 224000
BitRate/String : 224 kb/s
Channel(s) : 2
Channel(s)/String : 2 channels
ChannelPositions : Front: L R
ChannelPositions/String2 : 2/0/0
ChannelLayout : L R
SamplesPerFrame : 1536
SamplingRate : 48000
SamplingRate/String : 48.0 kHz
SamplingCount : 138763776
FrameRate : 31.250
FrameRate/String : 31.250 FPS (1536 SPF)
FrameCount : 90341
Compression_Mode : Lossy
Compression_Mode/String : Lossy
Delay : 0
Delay/String3 : 00:00:00.000
Delay/String5 : 00:00:00.000
Delay_Source : Container
Delay_Source/String : Container
Video_Delay : -67
Video_Delay/String : -67 ms
Video_Delay/String1 : -67 ms
Video_Delay/String2 : -67 ms
Video_Delay/String3 : -00:00:00.067
Video_Delay/String5 : -00:00:00.067
StreamSize : 80945536
StreamSize/String : 77.2 MiB (19%)
StreamSize/String1 : 77 MiB
StreamSize/String2 : 77 MiB
StreamSize/String3 : 77.2 MiB
StreamSize/String4 : 77.20 MiB
StreamSize/String5 : 77.2 MiB (19%)
StreamSize_Proportion : 0.18506
Language : en
Language/String : English
Language/String1 : English
Language/String2 : en
Language/String3 : eng
Language/String4 : en
ServiceKind : CM
ServiceKind/String : Complete Main
Default : Yes
Default/String : Yes
Forced : No
Forced/String : No
bsid : 16
dialnorm : -31
dialnorm/String : -31 dB
compr : -0.28
compr/String : -0.28 dB
dsurmod : 1
dsurmod/String : Not Dolby Surround encoded
acmod : 2
lfeon : 0
dialnorm_Average : -31
dialnorm_Average/String : -31 dB
dialnorm_Minimum : -31
dialnorm_Minimum/String : -31 dB
dialnorm_Maximum : -31
dialnorm_Maximum/String : -31 dB
dialnorm_Count : 785
[Text]
Count : 304
StreamCount : 1
StreamKind : Text
StreamKind/String : Text
StreamKindID : 0
StreamOrder : 2
ID : 3
ID/String : 3
UniqueID : 17864801373940337499
Format : UTF-8
Format/String : UTF-8
Format_Commercial : UTF-8
CodecID : S_TEXT/UTF8
CodecID/Info : UTF-8 Plain Text
Duration : 2804724.000000
Duration/String : 46 min 44 s
Duration/String1 : 46 min 44 s 724 ms
Duration/String2 : 46 min 44 s
Duration/String3 : 00:46:44.724
Duration/String5 : 00:46:44.724
BitRate : 65
BitRate/String : 65 b/s
FrameRate : 0.280
FrameRate/String : 0.280 FPS
FrameCount : 785
ElementCount : 785
StreamSize : 23030
StreamSize/String : 22.5 KiB (0%)
StreamSize/String1 : 22 KiB
StreamSize/String2 : 22 KiB
StreamSize/String3 : 22.5 KiB
StreamSize/String4 : 22.49 KiB
StreamSize/String5 : 22.5 KiB (0%)
StreamSize_Proportion : 0.00005
Language : en
Language/String : English
Language/String1 : English
Language/String2 : en
Language/String3 : eng
Language/String4 : en
Default : No
Default/String : No
Forced : No
Forced/String : No
This is definitely not how I had it set up before, however this absolutely works. Thank you so much! I've been banging my head against my desk trying to get this figured out.