Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update to use jasper-2.x, 3.x/4.x #73

Closed
edwardhartnett opened this issue Dec 18, 2023 · 5 comments · Fixed by #266
Closed

update to use jasper-2.x, 3.x/4.x #73

edwardhartnett opened this issue Dec 18, 2023 · 5 comments · Fixed by #266
Assignees
Labels
enhancement New feature or request

Comments

@edwardhartnett
Copy link
Contributor

NOAA machines are switching to jasper-3.x, IIRC. So we can skip jasper-2.3.3 if we need to.

There was a big change between jasper-2.x and jasper-3.x. There was no change needed in g2c code to upgrade to jasper-4.0.

The jasper initialization had to be rewritten to go from jasper-2 to jasper-3. To support this, I added pre-processor symbol JASPER3, so that the g2c code can build with either jasper-2.x or jasper-3/4.x. See this g2c code.

We can't install an older version, and NOAA machines will soon stop supporting jasper-2.x, if they have not already. Best bet is to support 2.x and 3.x.

We can set up CI testing for the different supported jasper versions.

@edwardhartnett
Copy link
Contributor Author

@webisu what's the status here? It would be good if this were in the next release, but if we need jasper-2.x to get the release out the door, that can work too.

@edwardhartnett
Copy link
Contributor Author

I have bumped this to the 3.4.0 release.

Looks like we have some old copies of g2c code:

  -rw-rw-r--  1 ed ed   5311 Mar 29 09:57 enc_jpeg2000_clone.c
  -rw-rw-r--  1 ed ed   5875 Mar 29 09:57 dec_png_clone.c
  -rw-rw-r--  1 ed ed  13846 Mar 29 09:57 decenc_openjpeg.c

These can be removed and wgrib2 can depend on the NCEPLIBS-g2c library for these. Jasper updates are already handled in g2c.

@webisu
Copy link
Collaborator

webisu commented Jul 5, 2024 via email

@edwardhartnett
Copy link
Contributor Author

edwardhartnett commented Jul 5, 2024

We want the code in one place, not two.

Whether or not g2c decoders are used, we don't want to copy the compression code between projects. Instead, g2c can always be required and can always provide the decompress/compress functions. We will examine the PNG issue separately.

g2c can now handle > 2 GB messages. But again, this has nothing to do with the compress/decompress functions.

Let's fix the g2c decoders, perhaps by porting your decoder code back to the g2c library. But that is a separate issue, which I will start up...

@webisu
Copy link
Collaborator

webisu commented Jul 5, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants