Jump to content

The dreaded .ASS files problem.


Recommended Posts

ServerNoob005
Posted

Good evening friends,

I hate to post about what appears to be a nightmare topic from past forum posts, but I just wanted to know if there is any real solution at this point in time? If not, well, not to be dramatic, but it's probably a deal break for me, sadly, simply because my entire home system is Roku ultras for ease of use. =/ In short, is there a way to get ass files to work and not buffer terribly in Emby?

I know in plex it was weird but straight forward with Rokus once you knew how. You needed to go into the Roku settings, set captions to OFF, and then set playback burn-in to automatic. The result is a very slight 2-3 second delay at the start of a video with the % wheel loading rapidly and then it basically runs the ass file perfectly.

In the case of Emby I have done the same process. Using the latest Roku ultra model, I have set captions to off, Emby Roku app settings set to yes for Burn in SSA subtitles, and while this seems to, in generous terms "work", the performance result is unusable. The wheel loads for about a minute, it begins to work with the ass format but stutters and then freezes and buffers back to the wheel. I am unsure what causes this. Is Emby perhaps trying to burn-in via the Roku box and its weak cpu vs using the server's much stronger intel core or something of that nature? Or is there perhaps critical setting I need to tweak in Emby that I have overlooked which wouldn't shock me either? (I have been unable to locate the "Allow subtitle extraction on the fly" setting I have read about not sure if that still exists).

Either way, I would appreciate any info, and if you need anyone from me, I will try to provide it. And worst-case scenario, I guess I will just have to keep my eyes peeled for a future update that fixes the issue for now.

visproduction
Posted

SN,

If you are dealing with MKV files, the subs may easily be extracted and a copy of the media can also be made without any subs at all using mkvtools.  That app may have a way to automatically run through hundreds of media files and do the tasks for pulling out the subs and making a media copy without subs.  FFMpeg full install would probably be able to have a script that does that automatically for however many media you want to do.

Doing one at a time, takes under 4 minutes for even a slow workstation.  You are not reencoding anything, just pulling out the subs and creating copy without subs.  If you have many to do, it would be worth to figure out an automatic script.  Do the math you can see that a script can do perhaps 15 to 20 an hour, on it's own.  Top speed server, that would be 10 times faster.  A script does them all with one click.  It's hard to complain it's too much work.  You just have to learn how to do it.

If you need to convert sup files, typically from blu-rays to .srt, you can do that with an online subtitletools page.  Keeping sup files is really only useful for foreign languages with many special characters.

Use the new media copy with no subs embedded and replace the old version in your emby library. Your new separate subs only need to follow the file naming rules and they will appear, easily on each media page, your delays will be a thing of the past.  Everything should playback and no more subtitle delay issues.

Hope that helps.

marriedman
Posted

In my experience, anytime you are using a streaming dongle, FireStick, or SmartTV app, the embedded subtitles are always burned into the video because the client hardware can't handle it. I made the following bash script to extract text based subtitles from MKV's:

find . -type f -name "*.mkv" | while read mkvname
do
 subname=${mkvname%.*}.en.default
 echo $mkvname
 echo $subname
mkvextract tracks "$mkvname" 2:"$subname.ass"
done

That runs recursively, so be careful where you run it from. It also will only work if the subtitle is ID 2. Also, there is no error checking, so language preference... it is built for speed alone. I manually edit it to a different ID or file extension (SSA, ASS, SRT) whenever necessary. On my laptop, I have used that on TV shows that had episodes that had over 200 episodes and it may have taken 5 minutes. 

If you need something a little beefier, I have used this one upon occasion:

#!/bin/bash

# Function to extract subtitles from video files
extract_subtitles() {
    local video_file="$1"

    # Extract SRT subtitles
    local srt_output_file="${video_file%.*}.srt"
    ffmpeg -i "$video_file" -map 0:s:m:language:eng "$srt_output_file" -y 2>/dev/null

    if [[ $? -eq 0 ]]; then
        echo "SRT subtitles extracted: $srt_output_file"
    else
        echo "No English SRT subtitles found in: $video_file"
    fi

    # Extract SSA subtitles
    local ssa_output_file="${video_file%.*}.ssa"
    ffmpeg -i "$video_file" -map 0:s:m:language:eng "$ssa_output_file" -y 2>/dev/null

    if [[ $? -eq 0 ]]; then
        echo "SSA subtitles extracted: $ssa_output_file"
    else
        echo "No English SSA subtitles found in: $video_file"
    fi
}

# Main script
main() {
    # Get the current directory
    local search_dir="$(pwd)"

    echo "Scanning for video files in directory: $search_dir"

    # Find video files and extract subtitles
    find "$search_dir" -type f \( -iname "*.mp4" -o -iname "*.mkv" -o -iname "*.avi" \) | while read -r video_file; do
        extract_subtitles "$video_file"
    done

    echo "Subtitle extraction completed."
}

# Execute the main function
main

Honestly though, I just use the first one because of it's simplicity.

  • Like 1
ServerNoob005
Posted (edited)

Alright friends,

Well- back from making myself a fool in another forum post. I will look into this later this week. See about getting the logs. Basically to streamline my post. The problem is not that the ASS files can’t be burned in— it’s that they run like crap. Stutter and take ages to load. I’ll check these post out but my goal is NOT to get rid of the ass format files. I know srt will work, but that’s punishing your quality, imo.

Edited by ServerNoob005
pwhodges
Posted

Logs taken while playing such a file would enable us to identify where the problem lies.

Burning-in adds appreciably to the work of transcoding, so if your system doesn't have much performance leeway, that could be the issue. 

In the subtitle options which appear with the diagnostic settings (plugin not loaded by default, and kind-of unsupported if you make changes without discussing it) there is a setting which selects whether the subs are generated for burning in at the full frame rate or slower - this just might help if performance is the issue.  Don't touch anything else - it's easy to make a mess of it!

Paul

image.jpeg.924bdd3b414e4c171ddbd90cc1896b0e.jpeg

Posted
2 hours ago, ServerNoob005 said:

Alright friends,

Well- back from making myself a fool in another forum post. I will look into this later this week. See about getting the logs. Basically to streamline my post. The problem is not that the ASS files can’t be burned in— it’s that they run like crap. Stutter and take ages to load. I’ll check these post out but my goal is NOT to get rid of the ass format files. I know srt will work, but that’s punishing your quality, imo.

Can you please provide the information that I requested above? Thanks.

ServerNoob005
Posted (edited)

@Luke@pwhodgesLet me know if this is the wrong log but I'm pretty sure it's the one. The file did not play in this case.

And as an aside pwhodges, this was after adding the diagnostic plugin and adding/saving the settings you showed.

Also, as mentioned before, the server is run on an Intel NUC 11 NUC11PAHi7. The players are roku ultras.

ffmpeg-transcode-621cb006-0c6d-4191-b13f-4da9f07b4e0a_1.txt

Edited by ServerNoob005
marriedman
Posted
On 7/21/2025 at 2:01 PM, ServerNoob005 said:

I’ll check these post out but my goal is NOT to get rid of the ass format files.

Just as info, ASS/SSA format is just text. The scripts I posted won't change anything except copying them from the video file.

pwhodges
Posted
52 minutes ago, marriedman said:

Just as info, ASS/SSA format is just text.

And typically some fonts.  If you extract the text, and the fonts (which are attachments in the video file) are not in the playback computer, then the display may be incorrect.

Paul

ServerNoob005
Posted

Morning Friends.

I will just add as an aside. I am very curious how emby transcodes. I have noticed for instance that the web version of emby on my PC in edge with chrome cannot play files with ass subtitles (surprising since I the machine is a 4070, and 7800x3d). Well, to be specific, it can but the subtitles will be missing. However, the emby app on the same PC plays them without any issue. Unclear if it’s a settings thing or just transcoding being transcoding. I just find the differences in performance on two different methods on the same hardware interesting. Same Nuc, feeding the same PC over the same Wi-Fi, and yet one runs perfectly and the other doesn’t. Doesn’t help the roku situation, it’s just a bit of musing.

@LukeI know you have a lot on your plate— please let me know if/when you have any updates and/or thoughts regarding the issue. Likewise if more info is needed, let me know.

@marriedmanI might give that a try, but, I’d rather not have to use what is essentially a work around. The files work fine on my other server solution, so either my settings are somehow wrong (praying it’s not more tomfoolery on my end), or emby has an issue. I am curious to see what your code results with. Not great with Linux, despite my server being run on it, but I can probably give it a whirl.

Posted
On 7/21/2025 at 8:46 PM, ServerNoob005 said:

@Luke@pwhodgesLet me know if this is the wrong log but I'm pretty sure it's the one. The file did not play in this case.

And as an aside pwhodges, this was after adding the diagnostic plugin and adding/saving the settings you showed.

Also, as mentioned before, the server is run on an Intel NUC 11 NUC11PAHi7. The players are roku ultras.

ffmpeg-transcode-621cb006-0c6d-4191-b13f-4da9f07b4e0a_1.txt 14.44 kB · 4 downloads

HI, can you please attach a new emby server log and ffmpeg log with the diagnostics changes reverted and the plugin uninstalled? Thanks.

  • 2 months later...
ServerNoob005
Posted

@LukeBack from the dead- sorry for the long, long wait. Here is what you requested those months ago. I uninstalled the plugin as requested. Just to reiterate the issue in the emby report format you provided:

  1. Problem: Roku Ultra 2024 cannot handle ASS files with a lot of modifications in anime. Specific show is Yuru Camp. The file loads slowly then plays a split second and buffers. I am trying to play any episode of Yuru Camp which adds English words in the same font and colors to books, text messages, sound effects, and signs in a lot of places. I am including this detail given another anime with ASS format "A Place Further than the Universe" does run properly albeit with a bad load time and a bit of chop at first, but it adds far less to frames beyond subtitles.
  2. Steps: I use the same strategy I use for plex: in the Roku unit settings, set captions to OFF and set playback burn-in to automatic. Then in the Emby roku app, settings burn-in is set to yes. The result is that the file loads to around 33%, stalls for 10-20 seconds, maybe starts loading again, then plays for maybe 2 seconds in a very choppy state and then freezes and returns to loading.
  3.  There are no error messages- just lack of function.
  4. See attached logs. What is included (server log when running yuru camp, Yuru Camp trying to run ffmpeg, A Place Further than the Universe running ffmpeg.
  5. Debug Options logs: I can't seem to provide this because of what I think might be an app error. If I go to advanced settings -> debug -> and to turn it on, it says "App Will Reset" and then you press "Ok". However, it does not reset when I press it ok, though it changes from "Off" to "On" on the page. There is no change to the home page to send a log however. Likewise, after doing this, if I leave the app via exiting properly in the app or hitting the home button on the remote it does not save my change to turning Debug to "On" and reverts back to "Off". Let me know if its user error or an app error you can reproduce.

I hope this helps.

embyserver (1).txt ffmpeg-transcode-85f9ece8-cef7-4480-a6e1-6cd64d7251a1_1.txt ffmpeg-transcode-9b8bb44b-c286-49a6-bbcf-45ac10bfeecd_1.txt

Posted (edited)


>>>>>>  Hardware Decoders for hevc
        [X] VAAPI TigerLake-LP GT2 Iris Xe Graphics - H.265 (HEVC)
        [X] QuickSync TigerLake-LP GT2 Iris Xe Graphics - H.265 (HEVC)

>>>>>>  Hardware Encoders for h264
        [X] VAAPI TigerLake-LP GT2 Iris Xe Graphics - H.264 (AVC)
        [X] QuickSync TigerLake-LP GT2 Iris Xe Graphics - H.264 (AVC)

Encoder VAAPI TigerLake-LP GT2 Iris Xe Graphics - H.264 (AVC)
        Adapter #0: 'TigerLake-LP GT2 Iris Xe Graphics' Id:39497 (Driver: Intel iHD driver for Intel(R) Gen Graphics - 23.1.4 (12e141dc2), Vendor: Intel Corporation)
        Max Bitrate: 234 Mbit/s - Frame Sizes: 32x32...4096x4096
        Color Formats: NV12 - Bit Depths: 8
        Profiles: Main Profile (Level 6), High Profile (Level 6), Constrained Baseline Profile (Level 6)

----

@ServerNoob005What happens if you uncheck VAAPI and just use QuickSync for hardware transcoding? Does it give any better result?

Edited by speechles
Posted
Quote

Warning: Hardware-accelerated subtitle-overlay is disabled due to diagnostic option

@ServerNoob005Are you using the diagnostic plugin?

 

ServerNoob005
Posted (edited)

@speechles

I had installed it per pwhodges advice and put in the following settings. I then uninstalled it as per @Luke's request. Is it still lingering and I need to reinstall and revert something then uninstall?

On 7/21/2025 at 11:54 AM, pwhodges said:

Logs taken while playing such a file would enable us to identify where the problem lies.

Burning-in adds appreciably to the work of transcoding, so if your system doesn't have much performance leeway, that could be the issue. 

In the subtitle options which appear with the diagnostic settings (plugin not loaded by default, and kind-of unsupported if you make changes without discussing it) there is a setting which selects whether the subs are generated for burning in at the full frame rate or slower - this just might help if performance is the issue.  Don't touch anything else - it's easy to make a mess of it!

Paul

image.jpeg.924bdd3b414e4c171ddbd90cc1896b0e.jpeg

 

Edited by ServerNoob005
Posted
10 hours ago, ServerNoob005 said:

Is it still lingering and I need to reinstall and revert something then uninstall?

Did you restart your server after you removed it?

ServerNoob005
Posted (edited)

@ebrI cannot say with absolute certainty after so many hours, but I am 90% sure I restarted immediately after uninstall because the “subtitle options” was still there, so I restarted the server and it disappeared, which reassured me it was uninstalled.

Let me know what you would like me to do. I can reinstall, tweak, uninstall, and restart if that is what you need.

Edited by ServerNoob005
  • 2 weeks later...
Posted

Hi, are you still having an issue with this?

ServerNoob005
Posted

@Luke Indeed, I am. My last comment to ebr is where things lay. Anime with heavily detailed ASS files like Yuru Camp fail to run on a Roku for me. Server has been restarted a few times to my knowledge.

Also as previously mentioned:  I can't seem to provide the Debug Logs because of what I think might be an app error. If I go to advanced settings -> debug -> and to turn it on, it says "App Will Reset" and then you press "Ok". However, it does not reset when I press it, though it changes from "Off" to "On" on the page. There is no change to the home page to send a log however. Likewise, after doing this, if I leave the app via exiting properly in the app or hitting the home button on the remote it does not save my change to turning Debug to "On" and reverts back to "Off".

Posted
On 10/11/2025 at 12:29 AM, ServerNoob005 said:

if I leave the app via exiting properly in the app or hitting the home button on the remote it does not save my change to turning Debug to "On" and reverts back to "Off".

Hi. I've never heard of this being a problem before but be sure and back out of the app properly instead of using home. The send log option should then appear on your user menu.

ServerNoob005
Posted (edited)

@ebrReplugged in the device today and it now it is marked as yes, so I was able to send the Log. No clue about before.

What I have attached:

  1. Image of the cycle I have talked about: 33% wheel stall, wheel disappears during 8:18 (not show), wheel returns 8:19 and finishes, plays for 2 seconds bit choppy and freezes (didn't even get to the subtitles). 
  2. Server Logs after running it this morning
  3. Logs were sent from the Roku at what should be around 11:19am for you. Do not look at the first log as it was sent before anything was done. The second log was sent after the test and failure of the Yuru camp episode. The user was Server Tech1. Unclear where I see that log file to send it or if it goes directly to you.

Other notes:

  • Server has been restarted and the diagnostic plugin was uninstalled as requested.
  • VAAPI and QuickSync have both been check marked again (default). Undid speechles' suggestion as it did not yield improvement.
  • In the Roku, unit settings captions are set to OFF. In the Emby roku app settings, burn-in is set to yes.

I hope any of this info is useful.

2025-10-14 08_23_44-IMG_4656.jpg.png

embyserver (1).txt ffmpeg-transcode-4f863ea4-467f-4a3b-912e-fb30372821cd_1.txt

Edited by ServerNoob005
Posted

There is something wrong with the HLS manifest the server is sending it appears.

Player error.  Error Code: -5 Message: no valid bitrates

 

  • 2 weeks later...
Posted
Quote

have noticed for instance that the web version of emby on my PC in edge with chrome cannot play files with ass subtitles (surprising since I the machine is a 4070, and 7800x3d). Well, to be specific, it can but the subtitles will be missing.

hi, can we please look at an example of this? Thanks.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...