No subject


Tue Sep 16 16:43:21 CEST 2008


respectively be read from h->mb.pic.p_fdec and h->mb.pic.p_fenc.

Just to make sure the image made of reference blocks would look like a MC one, I
wrote some code you can find in the attached patch. Unfortunately, the produced
images didn't look like what I expected.

Short description of what the patch does:
- add an option to get the residue filename
- initialize output file and output picture buffer
- copy (for now, until I known how to compute residues) for each MB a block of Y
data to the output picture buffer

It does not aim at complying with x264 coding style or be bug-free, though I
could do that if it's worth merging in.

Could someone enlighten me about where the data I'm looking for is located, or
tell me if there's a better way?

Best regards,
Kurosu
---MOQ1222784790b37a3d4ca686e576bb01f897c50bdaac
Content-Type: text/x-diff; name="residue.diff"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="residue.diff"

ZGlmZiAtLWdpdCBhL2NvbW1vbi9jb21tb24uYyBiL2NvbW1vbi9jb21tb24uYwppbmRleCA5ZDg0
YmZhLi5iMzU4NzMyIDEwMDY0NAotLS0gYS9jb21tb24vY29tbW9uLmMKKysrIGIvY29tbW9uL2Nv
bW1vbi5jCkBAIC00NDAsNiArNDQwLDkgQEAgaW50IHgyNjRfcGFyYW1fcGFyc2UoIHgyNjRfcGFy
YW1fdCAqcCwgY29uc3QgY2hhciAqbmFtZSwgY29uc3QgY2hhciAqdmFsdWUgKQogI2VuZGlmCiAg
ICAgT1BUKCJkdW1wLXl1diIpCiAgICAgICAgIHAtPnBzel9kdW1wX3l1diA9IHN0cmR1cCh2YWx1
ZSk7CisgICAgT1BUKCJyZXNpZHVlIikKKyAgICAgICAgcC0+cHN6X3Jlc2lkdWUgID0gc3RyZHVw
KHZhbHVlKTsKKwogICAgIE9QVDIoImFuYWx5c2UiLCAicGFydGl0aW9ucyIpCiAgICAgewogICAg
ICAgICBwLT5hbmFseXNlLmludGVyID0gMDsKZGlmZiAtLWdpdCBhL2NvbW1vbi9jb21tb24uaCBi
L2NvbW1vbi9jb21tb24uaAppbmRleCAxYTI2MGY5Li42NDU3NWQwIDEwMDY0NAotLS0gYS9jb21t
b24vY29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IHgyNjRfdCAqaCApCiAgICAgICAgICAgICB4MjY0X3Zpc3VhbGl6ZV9tYiggaCAp
OwogI2VuZGlmCiAKKyAgICAgICAgaWYgKGgtPnBhcmFtLnBzel9yZXNpZHVlKQorICAgICAgICB7
CisgICAgICAgICAgICBoLT5tYy5jb3B5W1BJWEVMXzE2eDE2XQorICAgICAgICAgICAgICAgICAg
KAorICAgICAgICAgICAgICAgICAgICAgIGgtPnJlc2lkdWUuaW1nLnBsYW5lWzBdICsgKGlfbWJf
eCArIGlfbWJfeSpoLT5yZXNpZHVlLmltZy5pX3N0cmlkZVswXSkqMTYsCisgICAgICAgICAgICAg
ICAgICAgICAgaC0+cmVzaWR1ZS5pbWcuaV9zdHJpZGVbMF0sCisgICAgICAgICAgICAgICAgICAg
ICAgaC0+bWIucGljLnBfZmVuY1swXSwKKyAgICAgICAgICAgICAgICAgICAgICBGRU5DX1NUUklE
RSwKKyAgICAgICAgICAgICAgICAgICAgICAxNgorICAgICAgICAgICAgICAgICAgKTsKKyAgICAg
ICAgfQorCiAgICAgICAgIC8qIHNhdmUgY2FjaGUgKi8KICAgICAgICAgeDI2NF9tYWNyb2Jsb2Nr
X2NhY2hlX3NhdmUoIGggKTsKIApAQCAtMTI0MSw2ICsxMjcyLDggQEAgc3RhdGljIHZvaWQgeDI2
NF9zbGljZV93cml0ZSggeDI2NF90ICpoICkKICAgICAgICAgfQogICAgIH0KIAorICAgIHgyNjRf
cmVzaWR1ZV9kdW1wKCBoICk7CisKICAgICBpZiggaC0+cGFyYW0uYl9jYWJhYyApCiAgICAgewog
ICAgICAgICB4MjY0X2NhYmFjX2VuY29kZV9mbHVzaCggaCwgJmgtPmNhYmFjICk7CkBAIC0yMDQ3
LDYgKzIwODAsMTIgQEAgdm9pZCAgICB4MjY0X2VuY29kZXJfY2xvc2UgICggeDI2NF90ICpoICkK
ICAgICAgICAgICAgIHgyNjRfbG9nKCBoLCBYMjY0X0xPR19JTkZPLCAia2IvczolLjFmXG4iLCBm
X2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
KTsKIAogICAgICAgICBpZiggYyA9PSAtMSApCmRpZmYgLS1naXQgYS94MjY0LmggYi94MjY0LmgK
aW5kZXggNGQ4MWJjZS4uYTQ5MDk2ZCAxMDA2NDQKLS0tIGEveDI2NC5oCisrKyBiL3gyNjQuaApA
QCAtMjE1LDYgKzIxNSw3IEBAIHR5cGVkZWYgc3RydWN0IHgyNjRfcGFyYW1fdAogICAgIGludCAg
ICAgICAgIGlfbG9nX2xldmVsOwogICAgIGludCAgICAgICAgIGJfdmlzdWFsaXplOwogICAgIGNo
YXIgICAgICAgICpwc3pfZHVtcF95dXY7ICAvKiBmaWxlbmFtZSBmb3IgcmVjb25zdHJ1Y3RlZCBm
cmFtZXMgKi8KKyAgICBjaGFyICAgICAgICAqcHN6X3Jlc2lkdWU7ICAgLyogZmlsZW5hbWUgZm9y
IHJlc2lkdWUgZnJhbWVzICovCiAKICAgICAvKiBFbmNvZGVyIGFuYWx5c2VyIHBhcmFtZXRlcnMg
Ki8KICAgICBzdHJ1Y3QK

---MOQ1222784790b37a3d4ca686e576bb01f897c50bdaac--


More information about the x264-devel mailing list