title: How does DEFLATE(zlib) determine block size?
body: <p>I wonder how DEFLATE determines block size(I mean, in zlib.)</p>
  
  <p>In RFC 1591, following explanation exists:
  "The compressor terminates a block when it determines that starting a new block with fresh trees would be useful, or when the block size fills up the compressor's block buffer."</p>
  
  <p>It is not enough for me. I want to know what condition is needed to end current block and start new block in detail. </p>
  
  <p>How does DEFLATE decide whether fresh tress would be useful or not?
  What is size of compressor's block buffer?</p>