Rafostar / clapper

Level up your video experience with a modern and user-friendly media player.
https://rafostar.github.io/clapper/
GNU General Public License v3.0
711 stars 34 forks source link

Add more customizability #460

Closed dougg0k closed 2 weeks ago

dougg0k commented 2 weeks ago

Hi,

As last request after trying out your player.

It would be good to have more options available through the UI and conf file, to backup.

It's the last part that seem to be currently lacking in the player, at least I didnt quickly find anything about it, there are many options in other players, would be good to be able to increase or decrease quality from the video, font and audio by having different tweak options, where you can make best use of the hardware available.

I have to mention MPV again as they where they lack in parts of the UI, they have the best customizability available in their config. e.g., https://github.com/noelsimbolon/mpv-config/blob/windows/mpv.conf

CharoSW commented 2 weeks ago

There is a config file of sorts, it's technically a gsettings file but if you've installed using the flatpak its in the keyfile in the glib2.0 folder within the clapper folder of ~/.var. As you've noted there isn't a lot of options to change so there usually isn't a lot in it but it's there to back up if you want.

To the main part of the request though, I think you need to be a bit more specific here because just asking for "more customization" isn't that helpful. I am not recommending spamming the issue tracker with every little option you want to see but at least the bigger items should be. We can then discuss if its worth exposing and why or why not.

dougg0k commented 2 weeks ago

I checked the file, it seems to contain the basics of almost all that you already do through the UI.

───────┬───────────────────────────────────────────────────────────────────────
       │ File: /home/user/.var/app/com.github.rafostar.Clapper/config/glib-2.0/settings/keyfile
───────┼───────────────────────────────────────────────────────────────────────
   1   │ [com/github/rafostar/Clapper]
   2   │ window-size='[1837,1195]'
   3   │ volume-last=1.0
   4   │ resume-database='[]'
   5   │ play-flags=1719
   6   │ fullscreen-auto=false
   7   │ plugin-ranking='[{"apply":false,"name":"vah264dec","rank":300}]'
   8   │ plugin-feature-ranks=''
   9   │ volume=0.720001220703125
  10   │ mute=false
  11   │ speed=1.0
  12   │ subtitles-enabled=true
  13   │ progression-mode=1
  14   │ maximized=true
  15   │ fullscreened=false
  16   │ subtitle-font-desc='Netflix Sans 12'
───────┴───────────────────────────────────────────────────────────────────────

I would still use mpv config as the reference.

If you check their config, there are different gpu settings that can get you better quality and better use of the hardware. Also use different codecs to be more efficient.

I suppose scalers and shaders would be a plus, but not necessary for the moment.

There are customization to tweak things like debanding and other parts that can get rid of artifacts in videos, also a good example here are madVR.

Subtitles customization are a very good one where you can leave it in a good way to be read, as the default are not that good. https://github.com/noelsimbolon/mpv-config/blob/windows/mpv.conf#L126


There seem to be a sort of plugin support that could have this, based on the gsettings config file, not sure how it works,

A good way would be to expose configs in the docs and to the extent in how it works.

Rafostar commented 2 weeks ago

I checked the file, it seems to contain the basics of almost all that you already do through the UI.

GSettings file is supposed to store local config done by preferences and few other values to restore at startup (such as last volume level). All settings from it are available through UI, and manually editing it is not intended way to change these values and not really recommended.

I would still use mpv config as the reference.

Clapper does not use libmpv but GStreamer, thus it doesn't have the same amount of options. GStreamer does things differently from mpv. And having thousands of options in preferences that rarely anyone uses (or even understands) is not the aim here.

To the main part of the request though, I think you need to be a bit more specific here

Yes, currently as this request title goes it just a simple "please make it better" (with the what is actually "better" unexplained).

If you check their config, there are different gpu settings that can get you better quality and better use of the hardware. Also use different codecs to be more efficient.

I suppose scalers and shaders would be a plus, but not necessary for the moment.

There are customization to tweak things like debanding and other parts that can get rid of artifacts in videos, also a good example here are madVR.

GStreamer uses plugins (modules) to do different things. Most of them are autoplugged depending on video to be able to play file. If there are multiple plugins available that do the same thing, you can tweak which one is used via "ranking" that is part of preferences window (e.g. use Nvidia instead of Intel GPU, force software decoding, use different decoder, etc.).

For anything remaining, on latest clapper-git you can use command line to manually force insertion of "extra" plugins and set their parameters as audio/video filters or sinks. This allows you a lot of freedom assuming you have the right plugin for the job (scalers, shaders, other post processing, etc.). These are considered VERY ADVANCED features that work or not depending on hardware and plugin availability on the user system, thus this is (currently?) not exposed in the UI itself. And if you do not have a plugin for something, you (or someone else) can always create one for your own usage.

dougg0k commented 2 weeks ago

Clapper does not use libmpv but GStreamer, thus it doesn't have the same amount of options. GStreamer does things differently from mpv. And having thousands of options in preferences that rarely anyone uses (or even understands) is not the aim here.

I understand, I meant most as reference, as if something were to be done, do based on the availability. Just having it there documented in how to tweak and the options available, would already be something.

Yes, currently as this request title goes it just a simple "please make it better" (with the what is actually "better" unexplained).

Not really, maybe you are interpreting it like this because you dont plan on giving the flexibility but instead do something more opinionated (how you want, specifically).

I didnt request as to make something better, but to give the option for the user to do so. Advanced or not. That's the more customizability (overall).

As an example, the fonts on mpv by default are also not good, but they have different options available there, that can turn into very good reading. It's not something specifically, but the extent and flexibility that can be done, you can take reference from there or somewhere else, doesnt really matter where or what. The more you cover, the better.

Rafostar commented 2 weeks ago

maybe you are interpreting it like this because you dont plan on giving the flexibility but instead do something more opinionated (how you want, specifically).

Um, please reread last 2 paragraphs from my earlier response. If this is not flexibility, then I dunno what is :smile:

For more basic/common options, subtitles font, color, position, etc. sure, I aim to have them in preferences, but there are already separate feature request for them.

dougg0k commented 2 weeks ago

Right, is there any documentation that would help reaching the right plugins? Including config options available in them.

Rafostar commented 2 weeks ago

Plugins that are provided by GStreamer itself are documented here. You can also use gst-inspect-1.0 tool for this. For anything other (3rd party) refer to the source that provides it.

Example: We combine fisheye element together with chromahold and set it config options to remove all colors except blue.

clapper --video-filter="fisheye ! chromahold target-r=0 target-g=0 target-b=255"

When used with VA (vaapi hw acceleration), you probably gonna need to insert vapostproc there too so it will download pixels from GPU letting other image editing filters work (another reason why this is for advanced users).

clapper --video-filter="vapostproc ! fisheye ! chromahold target-r=0 target-g=0 target-b=255"

And as I previously mentioned, flexibility is here and what one can do is very powerful as long as you have the right plugin or are willing to write one that uses some library to do what you want.

dougg0k commented 2 weeks ago

Cool, thanks.

Rafostar commented 2 weeks ago

For anything universal and common a separate issues are preferred. I will also give the example I posted here on the "post processing" feature request. Ideally I should update documentation or wiki to mention all this so its easier to find, but currently this is not yet in any released version anyway.

Rafostar commented 2 weeks ago

BTW, same goes for audio here.

For example:

clapper --audio-filter="audiokaraoke"

audiokaraoke element (as name suggests) removes/mutes frequencies where voice is carried for a karaoke experience.

dougg0k commented 2 weeks ago

Right, something useful for starters would be to include useful plugins in the docs and best configurations and maybe even tradeoff depending on what.

For subtitles you could even include good open source fonts, where to download them and configurations differences.

Mostly in the sense as to improve things, not just to add something that is possible but not very useful.

First time experiences many times can be the define moment in deciding if something are worth continue using or not. If no at least have options to easily modify and make them better.