Log in

View Full Version : Removing x264 encoder settings from file


kunkie
26th September 2008, 14:57
I've noticed that all the mp4 files I create have the x264 encoder settings viewable in mediainfo.

Is there any way of getting rid of this data?

(using latest x264)

LoRd_MuldeR
26th September 2008, 16:13
Why do you want to remove that data? Do you have anything to hide?

kunkie
26th September 2008, 16:14
yes, I do.

[figured it out - you can change the source to do that]

Ranguvar
26th September 2008, 17:11
I'm going to hazard a guess that this is for fansub/film encoding?

Take my advice. Practice the open philosophy you preach. Let others learn from you. It will only result in such content being generally of higher quality.

Dark Shikari
26th September 2008, 17:13
Don't worry, encoding experts can still tell how bad your settings are even without that header.

:devil:

Ranguvar
26th September 2008, 17:13
The idea is to educate those who aren't experts, so that they will create/share better content ;)

kunkie
26th September 2008, 17:59
yes, I do.

Having said that I still can't figure out how to edit stuff I've already encoded.

Is there a version of h264_parse that can write?

Comatose
27th September 2008, 02:47
Hex editor :p
You can also change stuff like the Writing application and library for some extra lulz.

Ranguvar: If they don't lurk here (or at least on animesuki), then they probably don't know that even exists.

martino
27th September 2008, 07:22
Recalls a Dominoes (or was it GG) encode without the header... xD (among others, now pointing to DS' point about being crap-tastic)

dug123
27th September 2008, 17:53
if your just gonna do garbage encodes like for example 1 ref, hexagon m.e., 5 subme (or lower), 0 b-frames, and 0 trellis, then you might as well just encode with xvid.
personally i just find it stupid to take a high quality codec like x264 and then lower the settings so much that it barely looks better if not worse then xvid.
try using good settings like sharktooth hq-slow or better (even hq-slower is only about 2x longer encoding time then xvid). then you wont have anything to hide and your encodes will look good (assuming that the encoding bitrate is good enough for the resolution used)

kunkie
27th September 2008, 18:37
Fine then...I'll tell you why I need this:

It's so I can do a subjective quality test with someone remote and I don't want them to know what settings were used.

None of this anime stuff...lol

Anyway I used a hex editor:

:thanks:

akupenguin
27th September 2008, 18:58
It's so I can do a subjective quality test with someone remote and I don't want them to know what settings were used.
If you're worried about them cheating on the comparison, you better not be testing AQ, CQM, deblock, refs, B-frames, pyramid, partitions, wpred, 8x8dct, etc which can all be read from the bitstream even without the options sei. Pure analysis options like subme, trellis, and decimate are ok (you'd have to be a developer to guess those settings based only on the result.)

Dark Shikari
27th September 2008, 20:26
If you're worried about them cheating on the comparison, you better not be testing AQ, CQM, deblock, refs, B-frames, pyramid, partitions, wpred, 8x8dct, etc which can all be read from the bitstream even without the options sei. Pure analysis options like subme, trellis, and decimate are ok (you'd have to be a developer to guess those settings based only on the result.)Subme 6 can be distinguished from subme 5 or lower because non-RD mode decision overweights i4x4 and underweights i8x8. Of course, if you're claiming to have used psy-RD, its even more obvious that you are or are not using RD.

Decimate can be spotted by doing a quick statistical analysis of CBP values, or even just simply grepping a debug trace of the file for a case in which you have a combination of coefficients that would have been decimated using x264's algorithm had decimate been on.

I suspect creative methods can be invented for most of the other options, especially if you have the source used for the encode.

lexor
27th September 2008, 23:11
I think you are overstating average user's ability to read bitstream. I mean drag-and-drop into a hex editor is one thing, analyzing NAL units is another. I don't think he has to worry about that.

Dark Shikari
27th September 2008, 23:11
I think you are overstating average user's ability to read bitstream. I mean drag-and-drop into a hex editor is one thing, analyzing NAL units is another. I don't think he has to worry about that.But its not the average users that matter; the average users don't care about the encoding settings. The only purpose of such a thing would be to try to fool experts, which will also fail.

lexor
27th September 2008, 23:17
But its not the average users that matter; the average users don't care about the encoding settings. The only purpose of such a thing would be to try to fool experts, which will also fail.

Average user won't, but average test subject will. One always wants to be "right", they would want to know the settings to look better than others (which is always a problem with letting people know they are being tested), but they are unlikely to have technical knowledge to get it. So removing plain text cheat is sufficient.

Dark Shikari
27th September 2008, 23:34
Average user won't, but average test subject will. One always wants to be "right", they would want to know the settings to look better than others (which is always a problem with letting people know they are being tested), but they are unlikely to have technical knowledge to get it. So removing plain text cheat is sufficient.In such a case you should just distribute losslessly encoded files (re-encoded from the x264-encoded file). This is how you can do truly blind tests between different video formats, too.

Gabriel_Bouvigne
29th September 2008, 08:38
Here is how it's done in audio tests (like the hydrogenaudio.org ones):
Distribute lossy files as-is, (eventually decode them), and have your testing tool randomize inputs and create encrypted result files.
The only way for a tester to cheat would be to run the testing tool in debug mode from within a debugger.

kunkie
30th September 2008, 12:53
Thanks for your help everyone.

Basically the guy is in between an 'average user' and an 'expert' (a sort of discerning consumer sort of level) and I knew that as a test subject he would want to be 'right'. He had the ability to use mediainfo but probably wouldn't have had much else. Hence, debuggers, hex editing etc wouldn't have really happened.

CruNcher
30th September 2008, 14:29
kunkie i would say the problem here is not how to hide the data from the test subject but the test subject itself, maybe he's better of visiting a psychologist (he seems to have a big ego problem) then running mediainfo won't help, or maybe you have in believing he has the ego problem so you just project it onto him, because you don't trust that person who knows :D
someone who think he is an expert wouldn't cheat on such a topic and look @ the data after the test only, most wouldn't even want to know them afterwards for further tests :)

DarkZell666
30th September 2008, 14:58
kunkie i would say the problem here is not how to hide the data from the test subject but the test subject itself, maybe he's better of visiting a psychologist (he seems to have a big ego problem) then running mediainfo won't help, or maybe you have in believing he has the ego problem so you just project it onto him, because you don't trust that person who knows :D
someone who think he is an expert wouldn't cheat on such a topic and look @ the data after the test only, most wouldn't even want to know them afterwards for further tests :)

You just can't cure curiosity sometimes :p

In fact, there's no right or wrong, that's the whole point :)
If he prefers how the video looks like with "weaker" settings, he's not actually wrong because as we say and repeat 10 times a day on Doom9 ... it's subjective =)

According to that beloved principle, I believe it's the other way round: it's sick to actually tell someone he's wrong because he didn't say he prefered the video that was encoded with the stronger settings ;)

CruNcher
30th September 2008, 15:56
That's the reason for blind tests to weighten the results and find a common denominator to agree and build on sure it's not the absolute truth as that doesn't exist, though when you have a test subject that is biased by knowing the setup before either expert or not you can't be sure it's reacting on it's free decision anymore and your results drifting away, of course using experts in such a way is useful if you want to prove a massive change what no one would expect visually and get a wow effect so for example if he knows how a certain setting reacts on a certain situation and improved that and subjectively a lot seeing that in Psy-RD in which specific cases that works is still not known fully or scientific blind tested (no base of approval found) @ all :)