mirror of
https://github.com/cuberite/libdeflate.git
synced 2025-08-03 09:46:04 -04:00
deflate_compress: strengthen levels 10-12 slightly
With deflate_compress_near_optimal(), some data benefits more than originally thought from larger values of max_search_depth and nice_match_length. Some data even needs these parameters to be fairly high for deflate_compress_near_optimal() to compress more than deflate_compress_lazy2(). Bump these parameters up a bit.
This commit is contained in:
parent
69a7ca07fd
commit
8d4a5ae15c
@ -3004,21 +3004,21 @@ libdeflate_alloc_compressor(int compression_level)
|
||||
#if SUPPORT_NEAR_OPTIMAL_PARSING
|
||||
case 10:
|
||||
c->impl = deflate_compress_near_optimal;
|
||||
c->max_search_depth = 30;
|
||||
c->nice_match_length = 50;
|
||||
c->max_search_depth = 35;
|
||||
c->nice_match_length = 75;
|
||||
c->p.n.num_optim_passes = 2;
|
||||
break;
|
||||
case 11:
|
||||
c->impl = deflate_compress_near_optimal;
|
||||
c->max_search_depth = 60;
|
||||
c->nice_match_length = 80;
|
||||
c->max_search_depth = 70;
|
||||
c->nice_match_length = 150;
|
||||
c->p.n.num_optim_passes = 3;
|
||||
break;
|
||||
case 12:
|
||||
default:
|
||||
c->impl = deflate_compress_near_optimal;
|
||||
c->max_search_depth = 100;
|
||||
c->nice_match_length = 133;
|
||||
c->max_search_depth = 150;
|
||||
c->nice_match_length = DEFLATE_MAX_MATCH_LEN;
|
||||
c->p.n.num_optim_passes = 4;
|
||||
break;
|
||||
#endif /* SUPPORT_NEAR_OPTIMAL_PARSING */
|
||||
|
Loading…
x
Reference in New Issue
Block a user