Finally, even if your rationale is 99% correct, then there is still that 1% that makes the result a mechanistic copy.
And I see no way in which most people would 100% agree with your view.
If you want to protect the idea or the design, get a patent. A patent on one h264 encoder applies to all h264 encoders.
There is a chance the courts or the legislature will decide differently. But until then, we should assume the existing law of the land holds.