/[debian]/mimetic/trunk/mimetic/codec/qp.h
ViewVC logotype

Diff of /mimetic/trunk/mimetic/codec/qp.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 196 by gregoa, Sat Feb 25 16:49:22 2006 UTC revision 197 by gregoa, Sun Apr 16 12:21:05 2006 UTC
# Line 2  Line 2 
2      copyright            : (C) 2002-2005 by Stefano Barbato      copyright            : (C) 2002-2005 by Stefano Barbato
3      email                : stefano@codesink.org      email                : stefano@codesink.org
4    
5      $Id: qp.h,v 1.16 2005/02/23 11:48:15 tat Exp $      $Id: qp.h,v 1.19 2006/04/10 09:43:50 tat Exp $
6   ***************************************************************************/   ***************************************************************************/
7    
8  /***************************************************************************  /***************************************************************************
# Line 20  Line 20 
20  #include <sstream>  #include <sstream>
21  #include <cassert>  #include <cassert>
22  #include <mimetic/libconfig.h>  #include <mimetic/libconfig.h>
23    #include <mimetic/utils.h>
24  #include <mimetic/circular_buffer.h>  #include <mimetic/circular_buffer.h>
25  #include <mimetic/codec/codec_base.h>  #include <mimetic/codec/codec_base.h>
26  #include <mimetic/codec/codec_chain.h>  #include <mimetic/codec/codec_chain.h>
# Line 150  class Encoder: public buffered_codec, pu Line 151  class Encoder: public buffered_codec, pu
151          }          }
152      }      }
153  public:  public:
154        /*! return the multiplier of the required (max) size of the output buffer
155         * when encoding */
156        double codeSizeMultiplier() const
157        {
158            // worse case is *3 but we'll use the (euristic) average value of 1.5.
159            // this may decrease performance when encoding messages with many
160            // non-ASCII (> 127) characters
161            return 1.5;
162        }
163      /*!      /*!
164       Constructor       Constructor
165       \param isBinary if true all space and newline characters will be       \param isBinary if true all space and newline characters will be
# Line 467  public: Line 477  public:
477          {          {
478              if(len == 1)              if(len == 1)
479              {              {
480                  assert(m_prev[0] == '=');                  /* malformed if m_prev[0] == '=' */
481                  write('=', out);                  write('=', out);
482              } else {              } else {
483                  write('=', out);                  write('=', out);

Legend:
Removed from v.196  
changed lines
  Added in v.197

  ViewVC Help
Powered by ViewVC 1.1.26