* [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
@ 2022-05-06 6:55 caleb
2022-05-06 17:56 ` Pierre-Anthony Lemieux
2022-05-07 8:35 ` Michael Niedermayer
0 siblings, 2 replies; 8+ messages in thread
From: caleb @ 2022-05-06 6:55 UTC (permalink / raw)
To: ffmpeg-devel; +Cc: caleb, pal
---
libavcodec/jpeg2000.h | 2 ++
libavcodec/jpeg2000dec.c | 4 ++++
2 files changed, 6 insertions(+)
diff --git a/libavcodec/jpeg2000.h b/libavcodec/jpeg2000.h
index d06313425e..e5ecb4cbf9 100644
--- a/libavcodec/jpeg2000.h
+++ b/libavcodec/jpeg2000.h
@@ -110,6 +110,8 @@ enum Jpeg2000Quantsty { // quantization style
#define JPEG2000_CSTY_PREC 0x01 // Precincts defined in coding style
#define JPEG2000_CSTY_SOP 0x02 // SOP marker present
#define JPEG2000_CSTY_EPH 0x04 // EPH marker present
+#define JPEG2000_CTSY_HTJ2K_F 0x40 // Only HT code-blocks (Rec. ITU-T T.814 | ISO/IEC 15444-15) are present
+#define JPEG2000_CTSY_HTJ2K_M 0xC0 // HT code blocks (Rec. ITU-T T.814 | ISO/IEC 15444-15) can be present
// Progression orders
#define JPEG2000_PGOD_LRCP 0x00 // Layer-resolution level-component-position progression
diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c
index 92966b11f5..30f8c878d1 100644
--- a/libavcodec/jpeg2000dec.c
+++ b/libavcodec/jpeg2000dec.c
@@ -521,6 +521,10 @@ static int get_cox(Jpeg2000DecoderContext *s, Jpeg2000CodingStyle *c)
c->cblk_style = bytestream2_get_byteu(&s->g);
if (c->cblk_style != 0) { // cblk style
+ if (c->cblk_style & JPEG2000_CTSY_HTJ2K_M || c->cblk_style & JPEG2000_CTSY_HTJ2K_F) {
+ av_log(s->avctx, AV_LOG_ERROR, "Support for High throughput JPEG 2000 is not yet available\n");
+ return AVERROR_PATCHWELCOME;
+ }
av_log(s->avctx, AV_LOG_WARNING, "extra cblk styles %X\n", c->cblk_style);
if (c->cblk_style & JPEG2000_CBLK_BYPASS)
av_log(s->avctx, AV_LOG_WARNING, "Selective arithmetic coding bypass\n");
--
2.34.0
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-05-06 6:55 [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present caleb
@ 2022-05-06 17:56 ` Pierre-Anthony Lemieux
2022-05-07 8:31 ` Michael Niedermayer
2022-05-07 8:35 ` Michael Niedermayer
1 sibling, 1 reply; 8+ messages in thread
From: Pierre-Anthony Lemieux @ 2022-05-06 17:56 UTC (permalink / raw)
To: caleb; +Cc: FFmpeg development discussions and patches
LGTM
On Thu, May 5, 2022 at 11:56 PM caleb <etemesicaleb@gmail.com> wrote:
>
> ---
> libavcodec/jpeg2000.h | 2 ++
> libavcodec/jpeg2000dec.c | 4 ++++
> 2 files changed, 6 insertions(+)
>
> diff --git a/libavcodec/jpeg2000.h b/libavcodec/jpeg2000.h
> index d06313425e..e5ecb4cbf9 100644
> --- a/libavcodec/jpeg2000.h
> +++ b/libavcodec/jpeg2000.h
> @@ -110,6 +110,8 @@ enum Jpeg2000Quantsty { // quantization style
> #define JPEG2000_CSTY_PREC 0x01 // Precincts defined in coding style
> #define JPEG2000_CSTY_SOP 0x02 // SOP marker present
> #define JPEG2000_CSTY_EPH 0x04 // EPH marker present
> +#define JPEG2000_CTSY_HTJ2K_F 0x40 // Only HT code-blocks (Rec. ITU-T T.814 | ISO/IEC 15444-15) are present
> +#define JPEG2000_CTSY_HTJ2K_M 0xC0 // HT code blocks (Rec. ITU-T T.814 | ISO/IEC 15444-15) can be present
>
> // Progression orders
> #define JPEG2000_PGOD_LRCP 0x00 // Layer-resolution level-component-position progression
> diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c
> index 92966b11f5..30f8c878d1 100644
> --- a/libavcodec/jpeg2000dec.c
> +++ b/libavcodec/jpeg2000dec.c
> @@ -521,6 +521,10 @@ static int get_cox(Jpeg2000DecoderContext *s, Jpeg2000CodingStyle *c)
>
> c->cblk_style = bytestream2_get_byteu(&s->g);
> if (c->cblk_style != 0) { // cblk style
> + if (c->cblk_style & JPEG2000_CTSY_HTJ2K_M || c->cblk_style & JPEG2000_CTSY_HTJ2K_F) {
> + av_log(s->avctx, AV_LOG_ERROR, "Support for High throughput JPEG 2000 is not yet available\n");
> + return AVERROR_PATCHWELCOME;
> + }
> av_log(s->avctx, AV_LOG_WARNING, "extra cblk styles %X\n", c->cblk_style);
> if (c->cblk_style & JPEG2000_CBLK_BYPASS)
> av_log(s->avctx, AV_LOG_WARNING, "Selective arithmetic coding bypass\n");
> --
> 2.34.0
>
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-05-06 17:56 ` Pierre-Anthony Lemieux
@ 2022-05-07 8:31 ` Michael Niedermayer
2022-05-07 8:44 ` Soft Works
0 siblings, 1 reply; 8+ messages in thread
From: Michael Niedermayer @ 2022-05-07 8:31 UTC (permalink / raw)
To: FFmpeg development discussions and patches
[-- Attachment #1.1: Type: text/plain, Size: 364 bytes --]
On Fri, May 06, 2022 at 10:56:16AM -0700, Pierre-Anthony Lemieux wrote:
> LGTM
will apply
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Into a blind darkness they enter who follow after the Ignorance,
they as if into a greater darkness enter who devote themselves
to the Knowledge alone. -- Isha Upanishad
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-05-06 6:55 [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present caleb
2022-05-06 17:56 ` Pierre-Anthony Lemieux
@ 2022-05-07 8:35 ` Michael Niedermayer
2022-08-07 16:46 ` Caleb Etemesi
1 sibling, 1 reply; 8+ messages in thread
From: Michael Niedermayer @ 2022-05-07 8:35 UTC (permalink / raw)
To: FFmpeg development discussions and patches
[-- Attachment #1.1: Type: text/plain, Size: 424 bytes --]
Hi
before applying this
Author: caleb <etemesicaleb@gmail.com>
If you want your full name there please resend this with your full name
so its in git with your full name. It cannot be
changed later if its pushed like this
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
The educated differ from the uneducated as much as the living from the
dead. -- Aristotle
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-05-07 8:31 ` Michael Niedermayer
@ 2022-05-07 8:44 ` Soft Works
0 siblings, 0 replies; 8+ messages in thread
From: Soft Works @ 2022-05-07 8:44 UTC (permalink / raw)
To: FFmpeg development discussions and patches
> -----Original Message-----
> From: ffmpeg-devel <ffmpeg-devel-bounces@ffmpeg.org> On Behalf Of
> Michael Niedermayer
> Sent: Saturday, May 7, 2022 10:31 AM
> To: FFmpeg development discussions and patches <ffmpeg-
> devel@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if
> HTJ2K codeblocks are present.
>
> On Fri, May 06, 2022 at 10:56:16AM -0700, Pierre-Anthony Lemieux
> wrote:
> > LGTM
>
> will apply
>
> thx
>
> [...]
> --
> Michael GnuPG fingerprint:
> 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> Into a blind darkness they enter who follow after the Ignorance,
> they as if into a greater darkness enter who devote themselves
> to the Knowledge alone. -- Isha Upanishad
They who read as if sentences devoted to pretention of the wise
words into great pain will enter. -- softworkz :-)
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-05-07 8:35 ` Michael Niedermayer
@ 2022-08-07 16:46 ` Caleb Etemesi
2022-08-07 19:50 ` Michael Niedermayer
0 siblings, 1 reply; 8+ messages in thread
From: Caleb Etemesi @ 2022-08-07 16:46 UTC (permalink / raw)
To: FFmpeg development discussions and patches
caleb is fine.
On Sat, May 7, 2022 at 11:35 AM Michael Niedermayer <michael@niedermayer.cc>
wrote:
> Hi
>
> before applying this
>
> Author: caleb <etemesicaleb@gmail.com>
>
> If you want your full name there please resend this with your full name
> so its in git with your full name. It cannot be
> changed later if its pushed like this
>
> thx
>
> [...]
> --
> Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> The educated differ from the uneducated as much as the living from the
> dead. -- Aristotle
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
>
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-08-07 16:46 ` Caleb Etemesi
@ 2022-08-07 19:50 ` Michael Niedermayer
2022-08-07 20:30 ` Caleb Etemesi
0 siblings, 1 reply; 8+ messages in thread
From: Michael Niedermayer @ 2022-08-07 19:50 UTC (permalink / raw)
To: FFmpeg development discussions and patches
[-- Attachment #1.1: Type: text/plain, Size: 454 bytes --]
On Sun, Aug 07, 2022 at 07:46:51PM +0300, Caleb Etemesi wrote:
> caleb is fine.
ok will apply
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Old school: Use the lowest level language in which you can solve the problem
conveniently.
New school: Use the highest level language in which the latest supercomputer
can solve the problem without the user falling asleep waiting.
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present.
2022-08-07 19:50 ` Michael Niedermayer
@ 2022-08-07 20:30 ` Caleb Etemesi
0 siblings, 0 replies; 8+ messages in thread
From: Caleb Etemesi @ 2022-08-07 20:30 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Also apologies for a really late reply,
Still learning about mail threads
Kind regards.
Caleb
On Sun, 7 Aug 2022, 22:51 Michael Niedermayer, <michael@niedermayer.cc>
wrote:
> On Sun, Aug 07, 2022 at 07:46:51PM +0300, Caleb Etemesi wrote:
> > caleb is fine.
>
> ok will apply
>
> thx
>
> [...]
> --
> Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> Old school: Use the lowest level language in which you can solve the
> problem
> conveniently.
> New school: Use the highest level language in which the latest
> supercomputer
> can solve the problem without the user falling asleep waiting.
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
>
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2022-08-07 20:30 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-06 6:55 [FFmpeg-devel] [PATCH] avcodec/jpeg2000: Fast fail if HTJ2K codeblocks are present caleb
2022-05-06 17:56 ` Pierre-Anthony Lemieux
2022-05-07 8:31 ` Michael Niedermayer
2022-05-07 8:44 ` Soft Works
2022-05-07 8:35 ` Michael Niedermayer
2022-08-07 16:46 ` Caleb Etemesi
2022-08-07 19:50 ` Michael Niedermayer
2022-08-07 20:30 ` Caleb Etemesi
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git