diff options
Diffstat (limited to '')
-rw-r--r-- | encoder.h | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -76,7 +76,7 @@ public: class LZ_encoder : public LZ_encoder_base { - struct Pair /* distance-length pair */ + struct Pair // distance-length pair { int dis; int len; @@ -90,12 +90,12 @@ class LZ_encoder : public LZ_encoder_base struct Trial { State state; - int price; /* dual use var; cumulative price, match length */ - int dis; /* rep index or match distance. (-1 for literal) */ - int prev_index; /* index of prev trial in trials[] */ - int prev_index2; /* -2 trial is single step */ - /* -1 literal + rep0 */ - /* >= 0 ( rep or match ) + literal + rep0 */ + int price; // dual use var; cumulative price, match length + int dis; // rep index or match distance. (-1 for literal) + int prev_index; // index of prev trial in trials[] + int prev_index2; // -2 trial is single step + // -1 literal + rep0 + // >= 0 ( rep or match ) + literal + rep0 int reps[num_rep_distances]; void update( const int pr, const int distance, const int p_i ) @@ -145,7 +145,7 @@ class LZ_encoder : public LZ_encoder_base int get_match_pairs( Pair * pairs = 0 ); void update_distance_prices(); - /* move-to-front dis in/into reps if( dis > 0 ) */ + // move-to-front dis in/into reps if( dis > 0 ) static void mtf_reps( const int dis, int reps[num_rep_distances] ) { if( dis >= num_rep_distances ) @@ -255,7 +255,7 @@ class LZ_encoder : public LZ_encoder_base const State state ); enum { before = max_num_trials + 1, - /* bytes to keep in buffer after pos */ + // bytes to keep in buffer after pos after_size = ( 2 * max_match_len ) + 1, dict_factor = 2, num_prev_positions3 = 1 << 16, |