Unable to encode due to lack of "Frame Rate info node"
#11
(18.04.2019, 16:17)Selur Wrote: a. do you have one or multiple Avisynth instances system wide installed in your system? (Hybrid does come with it's own portable Avisynth, so other versions might interfere)
Yes. I have Avisynth installed in my Program Files. Uninstalled it, and tested the avs script with Hybrid. Same frame rate info node error.

(18.04.2019, 16:17)Selur Wrote: b. does AvsPmod open the script you wrote without errors?
Yep, it opens the script up with no errors.

(18.04.2019, 16:17)Selur Wrote: c. What happens if you call
"<PATH TO Hybrid>\32bit\avsInfo.exe" "<PATH to your Avisynth script>"
Sorry, I'm unsure how to do that? Are you talking about CMD or do I have to make a new AVS script with the code above?
Reply
#12
Quote:Are you talking about CMD or do I have to make a new AVS script with the code above?
Yes I'm talking about the Windows Command Prompt.
I simply want you to call avsInfo with your Avisynth Script as parameter.

Problem is, I can't reproduce the issue you describe here at all.
AVSMeter might also be able to help debug whats happening.

When you deinstalled Avisynth, did you remove it with all it's settings?
Also: You are using 32bit filters and 32bit AvsPmod right?
Reply
#13
(19.04.2019, 11:15)Selur Wrote: Yes I'm talking about the Windows Command Prompt.
I simply want you to call avsInfo with your Avisynth Script as parameter.
This is what I got in CMD after executing the command:
LoadPlugin: unable to load "C:\Users\User\Desktop\encoding\VSFilter.dll", error=0xc1
(C:\Users\User\Desktop\script.avs, line 2)

(19.04.2019, 11:15)Selur Wrote: When you deinstalled Avisynth, did you remove it with all it's settings?
Also: You are using 32bit filters and 32bit AvsPmod right?
I believe I did remove all settings. And the filters are 32bit.

Oh wait... After writing the above line, I went and redownloaded VSfilter. I put it in the same directory and still got the same error. But I thought to myself, let me just change the location and change the 2nd line of the script. I then tried it again in Hybrid and there was NO ERROR.

I have no idea how it got fixed, but it seems to have worked! Sorry for all the trouble Blush
Reply
#14
(17.04.2019, 17:57)Selur Wrote:
Quote: Actually, I'd much rather let Hybrid do this for me. Could you explain how? How do I load VSFilter and use the Textsub command in Hybrid?
You don't have to tell Hybrid this.

You usually would do the following:
  1. start Hybrid
  2. set the default paths in case you haven't already done that (Config->Paths) and save those as defaults; not needed but usually a good idea. (Config->Defaults->Save->All->Save selected)
  3. load your source video (Base->Open File or simply drag&drop it)
  4. enable subtitle processing (Base->Subtitle)
  5. select your subtitle file (Subtitle->Import->Subtitle Import->Subtitle file->Load external subtitle)
  6. configure Hybrid to embed the subtitle you selected ((Subtitle->Import->Subtitle Import->Embed subtitle in frame)
  7. add the subtitle configuration to the Subtitle-Queue ((Subtitle->Subtitle Queue->add current subtitle stream ...)
  8. do the rest of the configuration you want in Hybrid
Note that Hybrid will only use Avisynth if:
  1. 'Filtering->Support' is set to 'Avisynth'
  2. Hybrid things it's worth to use Avisynth for this. by default it will probably not use Avisynth just to embed some subtitles and simply use ffmpeg on it's own for this. If you want to force Hybrid to use Avisynth (assuming 'Filtering->Support' is set to 'Avisynth') also enable 'Config->Internals->Avisynth->Always use Avisynth'.
----
About your script:
Are using Avisynth+ 32bit, right? If your script used 64bit filters this will not work with Hybrid.

-------------------------
General side note: If you want to see the script Hybrid will use (and 'Filtering->Support' is set to 'Avisynth'), simply click on 'Filtering->Avisynth->Show Avisynth script).

Cu Selur

Hi, I'm just wondering if it's possible to burn/hardcode the SUP subtitle with either a script or Hybird itself.
Reply
#15
Quote:Hi, I'm just wondering if it's possible to burn/hardcode the SUP subtitle with either a script or Hybird itself.
'Embed subtitle in frame' is the what you call 'burn/hardcode' subtitles in a frame.
Reply
#16
Photo 
(04.06.2019, 05:08)Selur Wrote:
Quote:Hi, I'm just wondering if it's possible to burn/hardcode the SUP subtitle with either a script or Hybird itself.
'Embed subtitle in frame' is the what you call 'burn/hardcode' subtitles in a frame.
Hybird doesn't support the sup file and it will automatically convert sup to idx/sub and then burn the sub file into video which you mentioned 6 years ago in another post, but the effect of converted sub is really bad. And I find that you added the SupTitle.dll which make it possible to burn the sup into video in April 16, 2012 , then fixed the detection and another problem in January 21, 2014 and August 4, 2013. Actually, I successfully used a script to burn the sup into video before, though some lines of dialogue were missed or disappear very quickly. Now I don't know how to make it happen again, 'cause everytime I import the AVS file it just says "Didn't find a 'Frame rate' info node! -› stream will be ignored". However, I can't figure out how to write a perfect script even after reading the post on SupTilte created by Zachs , the author of SupTitle.dll.→https://forum.doom9.org/showthread.php?t=148167
Reply
#17
Quote:Hybird doesn't support the sup file and it will automatically convert sup to idx/sub
For clarification:

When using Avisynth and embedding .sup file (assuming .Net is installed), Hybrid should create something along the lines of:
LoadCPlugin("I:\Hybrid\32bit\AVISYN~1\ffms2.dll")
LoadPlugin("I:\Hybrid\32bit\AVISYN~1\SupTitle.dll")
SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
# loading source: F:\TestClips&Co\files\test.avi
#  input color sampling YV12
#  input luminance scale tv
FFVideoSource("F:\TESTCL~1\files\test.avi",cachefile="E:\Temp\avi_078c37f69bb356e7b5fa040c71584c40_853323747_1_0.ffindex",fpsnum=25)
# current resolution: 640x352
# filtering
# embedding subtitles
Preroll(video=10, audio=0)
# Loading subtitle: E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup
SupTitle("E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup")
PreFetch(8)
return last
When using Vapoursynth and embedding .sup file, Hybrid should create something along the lines of:
# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading Plugins
core.std.LoadPlugin(path="I:/Hybrid/64bit/vsfilters/SourceFilter/FFMS2/ffms2k.dll")
# Loading F:\TestClips&Co\files\test.avi using FFMS2K
clip = core.ffms2.Source(source="F:/TESTCL~1/files/test.avi",cachefile="E:/Temp/avi_078c37f69bb356e7b5fa040c71584c40_853323747.ffindex",format=vs.YUV420P8,alpha=False)
# making sure input color matrix is set as unspec
clip = core.resize.Point(clip, matrix_in_s="unspec",range_s="limited")
# making sure frame rate is set to 25/1
clip = core.std.AssumeFPS(clip, fpsnum=25, fpsden=1)
# Setting color range to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# Loading image based subtitle E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup using Subtitle
def rgba(r, g, b, a=255):
  if r < 0 or r > 255 or g < 0 or g > 255 or b < 0 or b > 255 or a < 0 or a > 255:
    raise vs.Error("Colours must be in the range [0, 255].")

  return (a << 24) + (r << 16) + (g << 8) + b

unused = 1 << 42
subs = core.sub.ImageFile(clip=clip, file="E:/Output/00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup", palette=[rgba(0, 0, 0), rgba(255, 255, 255), rgba(0, 0, 0), rgba(0, 0, 0)])
alpha = core.std.PropToClip(subs)
subs = core.resize.Bicubic(subs, width=clip.width, height=clip.height, format=clip.format.id, matrix_s="unspec", matrix_in_s="unspec", range_s="limited")
gray_format = core.register_format(vs.GRAY, clip.format.sample_type, clip.format.bits_per_sample, 0, 0)
alpha = core.resize.Bicubic(alpha, width=clip.width, height=clip.height, format=gray_format.id, range_s="limited")
clip = core.std.MaskedMerge(clip, subs, alpha)
# adjusting output color from: RGB24 to YUV420P8 for x264Model (i420)
clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P8, matrix_s="unspec", range_s="limited")
# Output
clip.set_output()

When neither Avisynth nor Vapoursynth is available Hybrid converts the video to idx/sub since afaik ffmpeg doesn't support embedding .sup-subtitles.

Quote:Now I don't know how to make it happen again, 'cause everytime I import the AVS file it just says "Didn't find a 'Frame rate' info node! -› stream will be ignored".
Not knowing the script you use, I can't really help.

Cu Selur
Reply
#18
(04.06.2019, 16:25)Selur Wrote:
Quote:Hybird doesn't support the sup file and it will automatically convert sup to idx/sub
For clarification:

When using Avisynth and embedding .sup file (assuming .Net is installed), Hybrid should create something along the lines of:
LoadCPlugin("I:\Hybrid\32bit\AVISYN~1\ffms2.dll")
LoadPlugin("I:\Hybrid\32bit\AVISYN~1\SupTitle.dll")
SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
# loading source: F:\TestClips&Co\files\test.avi
#  input color sampling YV12
#  input luminance scale tv
FFVideoSource("F:\TESTCL~1\files\test.avi",cachefile="E:\Temp\avi_078c37f69bb356e7b5fa040c71584c40_853323747_1_0.ffindex",fpsnum=25)
# current resolution: 640x352
# filtering
# embedding subtitles
Preroll(video=10, audio=0)
# Loading subtitle: E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup
SupTitle("E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup")
PreFetch(8)
return last
When using Vapoursynth and embedding .sup file, Hybrid should create something along the lines of:
# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading Plugins
core.std.LoadPlugin(path="I:/Hybrid/64bit/vsfilters/SourceFilter/FFMS2/ffms2k.dll")
# Loading F:\TestClips&Co\files\test.avi using FFMS2K
clip = core.ffms2.Source(source="F:/TESTCL~1/files/test.avi",cachefile="E:/Temp/avi_078c37f69bb356e7b5fa040c71584c40_853323747.ffindex",format=vs.YUV420P8,alpha=False)
# making sure input color matrix is set as unspec
clip = core.resize.Point(clip, matrix_in_s="unspec",range_s="limited")
# making sure frame rate is set to 25/1
clip = core.std.AssumeFPS(clip, fpsnum=25, fpsden=1)
# Setting color range to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# Loading image based subtitle E:\Output\00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup using Subtitle
def rgba(r, g, b, a=255):
 if r < 0 or r > 255 or g < 0 or g > 255 or b < 0 or b > 255 or a < 0 or a > 255:
   raise vs.Error("Colours must be in the range [0, 255].")

 return (a << 24) + (r << 16) + (g << 8) + b

unused = 1 << 42
subs = core.sub.ImageFile(clip=clip, file="E:/Output/00005.track_4608_lang_und.4a3535dbb7070f889ca5f92f88a54966.sup", palette=[rgba(0, 0, 0), rgba(255, 255, 255), rgba(0, 0, 0), rgba(0, 0, 0)])
alpha = core.std.PropToClip(subs)
subs = core.resize.Bicubic(subs, width=clip.width, height=clip.height, format=clip.format.id, matrix_s="unspec", matrix_in_s="unspec", range_s="limited")
gray_format = core.register_format(vs.GRAY, clip.format.sample_type, clip.format.bits_per_sample, 0, 0)
alpha = core.resize.Bicubic(alpha, width=clip.width, height=clip.height, format=gray_format.id, range_s="limited")
clip = core.std.MaskedMerge(clip, subs, alpha)
# adjusting output color from: RGB24 to YUV420P8 for x264Model (i420)
clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P8, matrix_s="unspec", range_s="limited")
# Output
clip.set_output()

When neither Avisynth nor Vapoursynth is available Hybrid converts the video to idx/sub since afaik ffmpeg doesn't support embedding .sup-subtitles.

Quote:Now I don't know how to make it happen again, 'cause everytime I import the AVS file it just says "Didn't find a 'Frame rate' info node! -› stream will be ignored".
Not knowing the script you use, I can't really help.

Cu Selur

I can preview the script of Avisynth only the first time previewing the video. After that, even it displays the .ass subtitle as I expect(.ass file), there will be an error such as "Avisynth preview error: ntent of C:\User\??????\AppData\Local\Temp\tempPreviewAvisynthFile00_07_47_856.avs" all the time and Hybird even shuts itself down sometimes. However, I can still burn the .ass subtitle well with Avisynth. When I import the .sup subtitle, it can't display the subtitle(pictures of .sup file) neither with Avisynth nor with Vapoursynth, so I can only give the script of Vapoursynth below:

# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading Plugins
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/SourceFilter/LSmashSource/vslsmashsource.dll")
# Loading G:\TLOTR3.ts using LWLibavSource
clip = core.lsmas.LWLibavSource(source="G:/TLOTR3.ts", format="YUV420P8", cache=0)
# making sure input color matrix is set as unspec
clip = core.resize.Point(clip, matrix_in_s="unspec",range_s="limited")
# making sure frame rate is set to 24000/1001
clip = core.std.AssumeFPS(clip, fpsnum=24000, fpsden=1001)
# Setting color range to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
original = clip
# Loading image based subtitle G:\TLOTR.The.Return.of.the.King.2003.Extended.BluRay.1080p.DTSES6.1.x264-CHD.sup using Subtitle
def rgba(r, g, b, a=255):
  if r < 0 or r > 255 or g < 0 or g > 255 or b < 0 or b > 255 or a < 0 or a > 255:
    raise vs.Error("Colours must be in the range [0, 255].")

  return (a << 24) + (r << 16) + (g << 8) + b

unused = 1 << 42
subs = core.sub.ImageFile(clip=clip, file="G:/TLOTR.The.Return.of.the.King.2003.Extended.BluRay.1080p.DTSES6.1.x264-CHD.sup", palette=[rgba(0, 0, 0), rgba(255, 255, 255), rgba(0, 0, 0), rgba(0, 0, 0)])
alpha = core.std.PropToClip(subs)
subs = core.resize.Bicubic(subs, width=clip.width, height=clip.height, format=clip.format.id, matrix_s="unspec", matrix_in_s="unspec", range_s="limited")
gray_format = core.register_format(vs.GRAY, clip.format.sample_type, clip.format.bits_per_sample, 0, 0)
alpha = core.resize.Bicubic(alpha, width=clip.width, height=clip.height, format=gray_format.id, range_s="limited")
clip = core.std.MaskedMerge(clip, subs, alpha)
# adjusting output color from: RGB24 to YUV420P8 for x264Model (i420)
clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P8, matrix_s="unspec", range_s="limited")
# adjusting for FilterView
if original.format.id != clip.format.id:
 if (original.format.color_family == vs.RGB and clip.format.color_family != vs.RGB):
   original = core.resize.Bicubic(original, format=clip.format.id, matrix_s="709", range_s="limited")
 elif (original.format.color_family == clip.format.color_family):
   original = core.resize.Bicubic(original, format=clip.format.id, range_s="limited")
 else:
   original = core.resize.Bicubic(original, format=clip.format.id, matrix_in_s="709", range_s="limited")
stacked = core.std.StackHorizontal([original,clip])
# Output
stacked.set_output()

Actually, I can't see a text window of Vapoursynth either, so I just copy the text from the .vpy file. The following script is what I used before:

LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\ffms\ffms2.dll")
FFVideoSource("G:\TLOTR3.ts", fpsnum=24000, fpsden=1001, threads=1, colorspace="YUV420P8")
#deinterlace
#crop
#resize
LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\avisynth_plugin\FluxSmooth.dll")
FluxSmoothST(7,7) # Medium Noise
LoadPlugin("C:\Program Files\Hybrid\32bit\avisynthPlugins\SupTitle.dll")
SupTitle("G:\TLOTR.The.Return.of.the.King.2003.Extended.BluRay.1080p.DTSES6.1.x264-CHD.sup")
Reply
#19
About your script:
LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\ffms\ffms2.dll")
FFVideoSource("G:\TLOTR3.ts", fpsnum=24000, fpsden=1001, threads=1, colorspace="YUV420P8")
#deinterlace
#crop
#resize
LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\avisynth_plugin\FluxSmooth.dll")
FluxSmoothST(7,7) # Medium Noise
LoadPlugin("C:\Program Files\Hybrid\32bit\avisynthPlugins\SupTitle.dll")
SupTitle("G:\TLOTR.The.Return.of.the.King.2003.Extended.BluRay.1080p.DTSES6.1.x264-CHD.sup")
a. mixing Avisynth installations might cause problems, no clue whether MeGui uses a 32bit or 64bit Avisynth installation. Instead of using ffms2 from MeGui, you should use the one from "C:\Program Files\Hybrid\32bit\avisynthPlugins\ffms2.dll", same for FluxSmooth.
b. adding 'return last' to the end of your script, will probably help with the loading of the script.

No clue about your issues in Hybrid. Would need a debug output level 6 or higher to debug. Read the sticky about the necessary steps needed to provide proper info so I can reproduce the issue.

Did a few tests with different .sup-Subtitles and video files and embedding worked fine for me with Avisynth.

Cu Selur

Ps.: Also try deinstalling MeGui and all Avisynth installations on your system.
Reply
#20
(04.06.2019, 20:19)Selur Wrote: About your script:
LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\ffms\ffms2.dll")
FFVideoSource("G:\TLOTR3.ts", fpsnum=24000, fpsden=1001, threads=1, colorspace="YUV420P8")
#deinterlace
#crop
#resize
LoadPlugin("D:\BaiduNetdiskDownload\MeGUI_r2905\MeGUI\tools\avisynth_plugin\FluxSmooth.dll")
FluxSmoothST(7,7) # Medium Noise
LoadPlugin("C:\Program Files\Hybrid\32bit\avisynthPlugins\SupTitle.dll")
SupTitle("G:\TLOTR.The.Return.of.the.King.2003.Extended.BluRay.1080p.DTSES6.1.x264-CHD.sup")
a. mixing Avisynth installations might cause problems, no clue whether MeGui uses a 32bit or 64bit Avisynth installation. Instead of using ffms2 from MeGui, you should use the one from "C:\Program Files\Hybrid\32bit\avisynthPlugins\ffms2.dll", same for FluxSmooth.
b. adding 'return last' to the end of your script, will probably help with the loading of the script.

No clue about your issues in Hybrid. Would need a debug output level 6 or higher to debug. Read the sticky about the necessary steps needed to provide proper info so I can reproduce the issue.

Did a few tests with different .sup-Subtitles and video files and embedding worked fine for me with Avisynth.

Cu Selur

Ps.: Also try deinstalling MeGui and all Avisynth installations on your system.
Hybird still can't work. Here is my script:

LoadCPlugin("C:\Program Files\Hybrid\32bit\avisynthPlugins\ffms2.dll")
LoadPlugin("C:\Program Files\Hybrid\32bit\avisynthPlugins\SupTitle.dll")
FFVideoSource("D:\Aquaman.mkv", fpsnum=24000, fpsden=1001, threads=1, colorspace="YUV420P10")
SupTitle("D:\Aquaman.sup")
return last

And when I use avsInfo, it says:

C:\Users\刘晓东>"C:\Program Files\Hybrid\32bit\avsInfo.exe" "D:\BaiduNetdiskDownload\Aquaman.avs"
Import: unable to locate "鈲讓}" (try specifying a path), error=0x2

C:\Users\刘晓东>"C:\Program Files\Hybrid\32bit\avsInfo.exe" "D:\Aquaman.avs"
System.Exception: Not expecting more than one bitmap per descriptor!

   在 SupCore.BluraySubtitleLoader.GetBlurayBitmapData(Stream fs, SupData curSubData, Int32& bmpPart, Int32& bmpIndex)
   在 SupCore.BluraySubtitleLoader.Load(Stream fs)
   在 SupCore.SubtitleFile.Load(String filename, Boolean forcedOnly, Boolean swapCbCr, SubtitleType& fileType)
   在 SupCore.SupCoreMain..ctor(String filename, Double fps, Boolean forcedOnly, Boolean swapCbCr, Boolean relocate, String relocOffset)
   在 SupTitle.{ctor}(SupTitle* , PClip* child, String filename, Boolean forcedOnly, Boolean swapCbCr, Boolean relocate, String relocOffset, IScriptEnvironment* env)
   在 SupTitle.Create(AVSValue* , AVSValue* args, Void* user_data, IScriptEnvironment* env)
(D:\Aquaman.avs, line 4)
刘晓东 is my Chinese user name,  means "in" in Chinese, but "鈲讓}" means nothing specific. Actually, I saw the same error when I import the .avs file to MeGUI before. And I use a portable version of MeGUI so I don't need to uninstall it. I'm wondering the exact meaning of "Not expecting more than one bitmap per descriptor!".
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)