{"id":13537107,"url":"https://github.com/ultraembedded/core_jpeg","last_synced_at":"2026-03-05T11:32:50.439Z","repository":{"id":43358871,"uuid":"305197324","full_name":"ultraembedded/core_jpeg","owner":"ultraembedded","description":"High throughput JPEG decoder in Verilog for FPGA","archived":false,"fork":false,"pushed_at":"2022-03-05T21:24:43.000Z","size":175,"stargazers_count":221,"open_issues_count":7,"forks_count":43,"subscribers_count":10,"default_branch":"main","last_synced_at":"2025-03-01T10:25:10.096Z","etag":null,"topics":["axi-stream","fpga","jpeg-decoder","mjpeg","motion-jpeg","verilog","verilog-hdl"],"latest_commit_sha":null,"homepage":"","language":"Verilog","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ultraembedded.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-10-18T21:11:51.000Z","updated_at":"2025-02-15T16:00:36.000Z","dependencies_parsed_at":"2022-08-12T10:40:39.740Z","dependency_job_id":null,"html_url":"https://github.com/ultraembedded/core_jpeg","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ultraembedded/core_jpeg","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ultraembedded%2Fcore_jpeg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ultraembedded%2Fcore_jpeg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ultraembedded%2Fcore_jpeg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ultraembedded%2Fcore_jpeg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ultraembedded","download_url":"https://codeload.github.com/ultraembedded/core_jpeg/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ultraembedded%2Fcore_jpeg/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30122160,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T11:11:57.947Z","status":"ssl_error","status_checked_at":"2026-03-05T11:11:29.001Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["axi-stream","fpga","jpeg-decoder","mjpeg","motion-jpeg","verilog","verilog-hdl"],"created_at":"2024-08-01T09:00:55.231Z","updated_at":"2026-03-05T11:32:50.407Z","avatar_url":"https://github.com/ultraembedded.png","language":"Verilog","funding_links":[],"categories":["Accelerators"],"sub_categories":[],"readme":"# High throughput JPEG decoder\n\nGithub: [https://github.com/ultraembedded/core_jpeg](https://github.com/ultraembedded/core_jpeg)\n\nThis project is a JPEG decoder core for FPGA written in Verilog.\n\n![JPEG Core](docs/block_diagram.png)\n\n## Features\n* Baseline JPEG Decoder IP (sequential encoded images).\n* 32-bit AXI Stream input.\n* Input format: JPEG (JPEG File Interchange Format)\n* Output format: 24-bit RGB output in 8x8 blocks (row-major ordering).\n* Support for Monochrome, 4:4:4, 4:2:0 chroma subsampling support.\n* Support for fixed standard Huffman tables (reduced logic usage, fast).\n* Support for dynamic Huffman tables (from JPEG input stream -\u003e slower decode, more logic).\n* Dynamic DQT tables from JPEG input stream.\n* Synthesizable Verilog 2001, Verilator and FPGA friendly.\n* Multipliers and tables / FIFO's map efficiently to FPGA resources (DSP48, blockRAM, etc).\n* Verified using co-simulation against a C-model and tested on FPGA with thousands of images.\n\n## Design Aims\n1. Fast decode performance suitable for video playback\n2. Support a minimal JPEG baseline feature set.\n3. Be well tested (with verification against a reference C-model).\n4. Map to FPGA resources such as BlockRAM, DSP macros wherever possible.\n\n## FPGA Mapping\nThe current version of the JPEG decoder uses the following resources on a Xilinx 7 series FPGA (post-implementation);  \n![Resource Usage](docs/resources.png)\n\nThe design is also able to meet timing \u003e= 75MHz.\n\n## Performance\nPeak JPEG decode performance is as follows;\n* Monochrome  = 66 cycles per 8x8 pixels  (1.0 cycles per pixel)\n* YCbCr 4:2:0 = 137 cycles per 8x8 pixels (2.1 cycles per pixel)\n* YCbCr 4:4:4 = 198 cycles per 8x8 pixels (3.1 cycles per pixel)\n\n## Use Case\nThe purpose of this design was to replace a 3rd party JPEG decoder core used in my [Motion JPEG](https://en.wikipedia.org/wiki/Motion_JPEG) based [FPGA video player](https://github.com/ultraembedded/FPGAmp).  \nMotion JPEG has worse compression performance than MPEG based video, but the complexity of the HW required is low enough that it can be used on low(-ish)-end FPGAs.\n\nVideo playback usually requires at least 25 frames per second, hence there is a budget of less than 40ms per JPEG frame.  \nThis fact drives the design choices taken for this implementation.\n\nClearly, the higher the resolution, the more pixels that must be produced from the JPEG decoder within that 40ms budget, so this core is designed to have high throughput in the output stages - with additional resources dedicated to the IDCT transform, and output re-ordering stages to facilitate this.\n\n## Limitations\nThe current release does not support;\n* Restart markers\n* 4:2:2 H/V chroma subsampling (only 4:4:4 and 4:2:0 are supported).\n\nUnder the GNU Image Manipulation Program, the following 'X' options are **not** supported currently;\n![Unsupported Opts](docs/supported_opts.png)\n\nNote: Support for 'optimised' Huffman tables is possible when design parameter SUPPORT_WRITABLE_DHT=1.  \nThis functionality increases the core size substantially and reduces performance.\n\n## Future Work / TODO\n* Add support for the first layer of progressive JPEG images.\n* Add option to reduce arithmetic precision to reduce design size.\n* Add lightweight variant of the core with reduced performance (for smaller FPGAs).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fultraembedded%2Fcore_jpeg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fultraembedded%2Fcore_jpeg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fultraembedded%2Fcore_jpeg/lists"}