#include <pithsync.h>
 | 
|   | FPCUTPT ()=default | 
|   | 
| void  | setup (FPCUTPT cutpts[], int16_t array_origin, STATS *projection, int16_t zero_count, int16_t pitch, int16_t x, int16_t offset) | 
|   | 
| void  | assign (FPCUTPT cutpts[], int16_t array_origin, int16_t x, bool faking, bool mid_cut, int16_t offset, STATS *projection, float projection_scale, int16_t zero_count, int16_t pitch, int16_t pitch_error) | 
|   | 
| void  | assign_cheap (FPCUTPT cutpts[], int16_t array_origin, int16_t x, bool faking, bool mid_cut, int16_t offset, STATS *projection, float projection_scale, int16_t zero_count, int16_t pitch, int16_t pitch_error) | 
|   | 
| int32_t  | position () | 
|   | 
| double  | cost_function () | 
|   | 
| double  | squares () | 
|   | 
| double  | sum () | 
|   | 
| FPCUTPT *  | previous () | 
|   | 
| int16_t  | cheap_cuts () const | 
|   | 
| int16_t  | index () const | 
|   | 
Definition at line 27 of file pithsync.h.
 
◆ FPCUTPT()
◆ assign()
      
        
          | void FPCUTPT::assign  | 
          ( | 
          FPCUTPT  | 
          cutpts[],  | 
        
        
           | 
           | 
          int16_t  | 
          array_origin,  | 
        
        
           | 
           | 
          int16_t  | 
          x,  | 
        
        
           | 
           | 
          bool  | 
          faking,  | 
        
        
           | 
           | 
          bool  | 
          mid_cut,  | 
        
        
           | 
           | 
          int16_t  | 
          offset,  | 
        
        
           | 
           | 
          STATS *  | 
          projection,  | 
        
        
           | 
           | 
          float  | 
          projection_scale,  | 
        
        
           | 
           | 
          int16_t  | 
          zero_count,  | 
        
        
           | 
           | 
          int16_t  | 
          pitch,  | 
        
        
           | 
           | 
          int16_t  | 
          pitch_error  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Definition at line 88 of file pithsync.cpp.
  106   int16_t balance_count;           
 
  115   int16_t half_pitch = pitch / 2 - 1;
 
  120   else if (half_pitch < 0)
 
  122   lead_flag = 1 << half_pitch;
 
  124   back_balance = cutpts[x - 1 - array_origin].back_balance << 1;
 
  125   back_balance &= lead_flag + lead_flag - 1;
 
  128   fwd_balance = cutpts[x - 1 - array_origin].fwd_balance >> 1;
 
  129   if (projection->
pile_count (x + half_pitch) > zero_count)
 
  130     fwd_balance |= lead_flag;
 
  139   for (
index = x - pitch - pitch_error; 
index <= x - pitch + pitch_error;
 
  141     if (
index >= array_origin) {
 
  142       segpt = &cutpts[
index - array_origin];
 
  143       dist = x - segpt->xpos;
 
  148             lead_flag = back_balance ^ segpt->fwd_balance;
 
  150             while (lead_flag != 0) {
 
  152               lead_flag &= lead_flag - 1;
 
  156             for (balance_index = 0;
 
  157               index + balance_index < x - balance_index;
 
  169         r_index = segpt->region_index + 1;
 
  170         total = segpt->mean_sum + dist;
 
  171         balance_count += offset;
 
  173           dist * dist + segpt->sq_sum + balance_count * balance_count;
 
  174         mean = total / r_index;
 
  175         factor = mean - pitch;
 
  177         factor += sq_dist / (r_index) - mean * mean;
 
  184           mid_cuts = segpt->mid_cuts + mid_cut;
 
  185           region_index = r_index;
 
 
 
 
◆ assign_cheap()
      
        
          | void FPCUTPT::assign_cheap  | 
          ( | 
          FPCUTPT  | 
          cutpts[],  | 
        
        
           | 
           | 
          int16_t  | 
          array_origin,  | 
        
        
           | 
           | 
          int16_t  | 
          x,  | 
        
        
           | 
           | 
          bool  | 
          faking,  | 
        
        
           | 
           | 
          bool  | 
          mid_cut,  | 
        
        
           | 
           | 
          int16_t  | 
          offset,  | 
        
        
           | 
           | 
          STATS *  | 
          projection,  | 
        
        
           | 
           | 
          float  | 
          projection_scale,  | 
        
        
           | 
           | 
          int16_t  | 
          zero_count,  | 
        
        
           | 
           | 
          int16_t  | 
          pitch,  | 
        
        
           | 
           | 
          int16_t  | 
          pitch_error  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Definition at line 195 of file pithsync.cpp.
  213   int16_t balance_count;           
 
  222   int16_t half_pitch = pitch / 2 - 1;
 
  227   else if (half_pitch < 0)
 
  229   lead_flag = 1 << half_pitch;
 
  231   back_balance = cutpts[x - 1 - array_origin].back_balance << 1;
 
  232   back_balance &= lead_flag + lead_flag - 1;
 
  235   fwd_balance = cutpts[x - 1 - array_origin].fwd_balance >> 1;
 
  236   if (projection->
pile_count (x + half_pitch) > zero_count)
 
  237     fwd_balance |= lead_flag;
 
  247   if (
index >= array_origin) {
 
  248     segpt = &cutpts[
index - array_origin];
 
  249     dist = x - segpt->xpos;
 
  253         lead_flag = back_balance ^ segpt->fwd_balance;
 
  255         while (lead_flag != 0) {
 
  257           lead_flag &= lead_flag - 1;
 
  262       r_index = segpt->region_index + 1;
 
  263       total = segpt->mean_sum + dist;
 
  264       balance_count += offset;
 
  266         dist * dist + segpt->sq_sum + balance_count * balance_count;
 
  267       mean = total / r_index;
 
  268       factor = mean - pitch;
 
  270       factor += sq_dist / (r_index) - mean * mean;
 
  276       mid_cuts = segpt->mid_cuts + mid_cut;
 
 
 
 
◆ cheap_cuts()
  
  
      
        
          | int16_t FPCUTPT::cheap_cuts  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
inline   | 
  
 
 
◆ cost_function()
  
  
      
        
          | double FPCUTPT::cost_function  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
 
◆ index()
  
  
      
        
          | int16_t FPCUTPT::index  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
inline   | 
  
 
 
◆ position()
  
  
      
        
          | int32_t FPCUTPT::position  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
 
◆ previous()
◆ setup()
      
        
          | void FPCUTPT::setup  | 
          ( | 
          FPCUTPT  | 
          cutpts[],  | 
        
        
           | 
           | 
          int16_t  | 
          array_origin,  | 
        
        
           | 
           | 
          STATS *  | 
          projection,  | 
        
        
           | 
           | 
          int16_t  | 
          zero_count,  | 
        
        
           | 
           | 
          int16_t  | 
          pitch,  | 
        
        
           | 
           | 
          int16_t  | 
          x,  | 
        
        
           | 
           | 
          int16_t  | 
          offset  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Definition at line 32 of file pithsync.cpp.
   44   int16_t half_pitch = pitch / 2 - 1;
 
   50   else if (half_pitch < 0)
 
   52   lead_flag = 1 << half_pitch;
 
   56   sq_sum = offset * offset;
 
   64   if (x == array_origin) {
 
   67     for (ind = 0; ind <= half_pitch; ind++) {
 
   70         fwd_balance |= lead_flag;
 
   74     back_balance = cutpts[x - 1 - array_origin].back_balance << 1;
 
   75     back_balance &= lead_flag + lead_flag - 1;
 
   78     fwd_balance = cutpts[x - 1 - array_origin].fwd_balance >> 1;
 
   79     if (projection->
pile_count (x + half_pitch) > zero_count)
 
   80       fwd_balance |= lead_flag;
 
 
 
 
◆ squares()
  
  
      
        
          | double FPCUTPT::squares  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
 
◆ sum()
◆ fake_count
      
        
          | int16_t FPCUTPT::fake_count | 
        
      
 
 
◆ faked
◆ terminal
The documentation for this class was generated from the following files: