vkohaupt / vokoscreenNG

vokoscreenNG is a powerful screencast creator in many languages to record the screen, an area or a window (Linux only). Recording of audio from multiple sources is supported. With the built-in camera support, you can make your video more personal. Other tools such as systray, magnifying glass, countdown, timer, Showclick and Halo support will help
https://linuxecke.volkoh.de/vokoscreen/vokoscreen.html
GNU General Public License v2.0
1.05k stars 91 forks source link

H.264 at compression of 1 still causes artefacting #304

Open Templayer opened 4 months ago

Templayer commented 4 months ago

Bug report checklist

Premise

I'm trying to find a way to record games on Linux that are visually identical in quality. On Windows, I can use Mirillis Action with the FIC codecs set to 100% quality, or Bandicam with either MPEG1 set to 100% or NVENC H264 also set to 100%.

Here, the VP8 codec takes too much CPU (either that, or it won't work with my editing software even if ran through FFMPEG, or both, I don't remember, it's been too long since I tried it), and the H264 codec cannot be set to be visually identical to what was on the screen (monitor settings aside).

Describe the bug

If I set H264 as a codec with the compression setting of 1 (or more, it doesn't actually matter), the resulting video is artefacting.

Here's an example: https://youtu.be/1eDdw7JRV3k

At 1:00 - contains artefacting rain that wasn't there during gameplay. Mirillis Action doesn't produce that in the very same game (while booted under Windows). The artefacting is in the file itself, it has not been caused by youtube. :)

Attachments

Settings.zip

2024-02-28_23-07-03.log

Templayer commented 4 months ago

@vkohaupt Are you sure with that enhancement tag?

Removing graphical glitches that have been encoded into the video doesn't sound like an enhancement to me. More of a bug fix. One that makes recording on Linux problematic at best.

I still don't know how deep goes the rabbit hole, or what repo or dependency is at fault, though.

vkohaupt commented 4 months ago

What does it look like if you use x264 or vp8?

Templayer commented 4 months ago

How do I get x264?

image

EDIT: All the GSTREAMER dependencies should be installed, except for the rs one needed for gif support.

EDIT2:

NAME="Linux Mint" VERSION="21.3 (Virginia)" ID=linuxmint ID_LIKE="ubuntu debian" PRETTY_NAME="Linux Mint 21.3"

Templayer commented 4 months ago

Also, if it sounded that way, I do not wish to sound ungrateful.

You did a lot of work on this, and VokoNG has a lot of potential.

But some of us quality junkies refuse to have inferior quality (i.e. visual glitches in the recorded video), while at the same time, we need something that is not resource-heavy for gaming.

Voko enabled me to do this (it's unlisted on youtube until I translate it - it's me teaching my father how to play Jedi Knight): https://www.youtube.com/watch?v=im_9VBdsiKY&list=PLYl6bTZe5Zy7eU8oKDbFvwqRtrfGuyICI&index=6

That is also how I have noticed that voko had inferior quality due to artefacts.

The right side of the splitscreen is Mirillis Action under Win7, the left side is VokoNG under Linux Mint.

vkohaupt commented 4 months ago

https://www.youtube.com/watch?v=im_9VBdsiKY&list=PLYl6bTZe5Zy7eU8oKDbFvwqRtrfGuyICI&index=6

That is also how I have noticed that voko had inferior quality due to artefacts.

The right side of the splitscreen is Mirillis Action under Win7, the left side is VokoNG under Linux Mint.

I see no difference, the artefacting rain is on the left and right side.

Templayer commented 4 months ago

I do not know if we are talking about the same thing.

Youtube seems to have downgraded the quality a bit even in 4K (ugh) - by artefacting I do NOT mean compression squares/blocks. (the video on my drive doesn't visually have that unless I zoom a lot)

What I actually mean is that the rain leaves a ghost trail of stuck unmoving lines when recorded under Voko. This can be clearly seen at 1:00 in this video: https://youtu.be/1eDdw7JRV3k

Those unmoving lines of rain are what I mean - they are not there during gameplay, but are present on both youtube and the recorded raw file.

At least I think there was a miscommunication here. Compression blocks are one thing. Glitchy graphics added to the video is another.

vkohaupt commented 4 months ago

https://www.youtube.com/watch?v=im_9VBdsiKY&list=PLYl6bTZe5Zy7eU8oKDbFvwqRtrfGuyICI&index=6

Mean you the white lines? The white lines can also be seen under Windows in the video. See attached images

vokoscreenNG-2024-03-01_11-45-57 882 vokoscreenNG-2024-03-01_12-01-01 772

Templayer commented 4 months ago

https://www.youtube.com/watch?v=im_9VBdsiKY&list=PLYl6bTZe5Zy7eU8oKDbFvwqRtrfGuyICI&index=6

Mean you the white lines? The white lines can also be seen under Windows in the video. See attached images

vokoscreenNG-2024-03-01_11-45-57 882 vokoscreenNG-2024-03-01_12-01-01 772

No and yes.

Yes, these white lines are in both versions. They represent rain.

BUT. Only in the Voko version they are getting "stuck". Ghostly copies of those lines are created that are not supposed to be there.

vkohaupt commented 4 months ago

I looked at the rain image by image using avidemux. I don't see any hanging vertical lines. The rain falls and the lines disappear.

Templayer commented 4 months ago

As a last-ditch effort, I recorded an almost 10-minute video explaining it, with a zoomed-in look, outright using my mouse cursor to highlight lines that should be there and lines/dots that should not be there, with time slowed down.

It will take a moment to render...

Templayer commented 4 months ago

There we go - https://www.youtube.com/watch?v=facVsLoQgfM

Or just in case of youtube screwing up, having a quality glitch where what I am showing cannot be seen, etc.: https://mega.nz/file/N9hlRQBb#MyvNy7ncxnX4ycvwaw-P27OgeAEaqb4RRECzQ59tRnQ

vkohaupt commented 4 months ago

I found the error. https://github.com/vkohaupt/vokoscreenNG/blob/3.0/src/mainwindow.cpp#L125 With the new version of openh264 there are no more false colors. I can now set the minimum value to zero, this is without compress.

Thank you very much for your help

Templayer commented 4 months ago

I found the error. https://github.com/vkohaupt/vokoscreenNG/blob/3.0/src/mainwindow.cpp#L125 With the new version of openh264 there are no more false colors. I can now set the minimum value to zero, this is without compress.

Thank you very much for your help

It almost cost me my sanity, as I was doubting myself multiple times, but I was glad to help.

Voko needs to reach its full potential now that Linux Mint is a viable gaming platform. :p

Furthermore - the first two dots/artefacts I found in the video are very hard to see, later in the video I found much better examples (so don't try squinting or quitting at that point if you have trouble seeing those... just watch the video further until I manage to get better examples).

Let's hope this form of artefacting won't happen with 0 compression, but I'm worried that it will produce files that are too big. And setting it to 0 isn't a solution for those who want to use >0 without these "ghosts" in their videos.

I'm usually using HandBrake to finalize my videos with a quality setting of 13 and that doesn't produce ghosting (of course that uses forked FFMPEG).

Of course, I am willing to make another test with 0 compression to see if these artefact ghosts still appear.

I checked out openh264 and it seems to be very immature right now. 0 compression might be a gaming workaround for now. Or even for later, those SSDs are getting pretty affordable. One 20TB HDD (I have two of those already) to store raw footage while editing and 20TB SSD for recording raw footage. #Soon

vkohaupt commented 4 months ago

I have to take everything back. With the value zero there are still incorrect colors and artifacts.

Templayer commented 4 months ago

I have to take everything back. With the value zero there are still incorrect colors and artifacts.

Yup, that is what I have been worried about. Is there any way for me to enable x264 on Mint instead?

Templayer commented 4 months ago

We should test if the same thing happens in x264 and if not, we should keep this Issue alive and bubble it up to their repository by making an Issue there and posting a link to this Issue.

Substantial effort and time were spent writing all this down and finding clear examples in that last video I posted (the zoomed-in slowed-down video with a mouse cursor pointing out the artefacts).

vkohaupt commented 4 months ago

Is there any way for me to enable x264 on Mint instead?

For license reasons there is no x264 for the Flatpak version. x264 is supported in the distribution versions. Linux Mint may provide a vokoscreenNG version.