overlapSize returns the overlap prefix size for parallel jobs.
()
| 360 | |
| 361 | // overlapSize returns the overlap prefix size for parallel jobs. |
| 362 | func (o *encoderOptions) overlapSize() int { |
| 363 | switch o.level { |
| 364 | case SpeedBestCompression: |
| 365 | return o.windowSize / 2 |
| 366 | case SpeedBetterCompression: |
| 367 | return o.windowSize / 4 |
| 368 | default: |
| 369 | return o.windowSize / 8 |
| 370 | } |
| 371 | } |
| 372 | |
| 373 | // WithEncoderDict allows to register a dictionary that will be used for the encode. |
| 374 | // |