MCPcopy Create free account
hub / github.com/defold/defold / restart

Method restart

engine/dlib/src/basis/encoder/basisu_resampler.cpp:608–635  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

606 }
607
608 void Resampler::restart()
609 {
610 if (STATUS_OKAY != m_status)
611 return;
612
613 m_cur_src_y = m_cur_dst_y = 0;
614
615 int i, j;
616 for (i = 0; i < m_resample_src_y; i++)
617 {
618 m_Psrc_y_count[i] = 0;
619 m_Psrc_y_flag[i] = false;
620 }
621
622 for (i = 0; i < m_resample_dst_y; i++)
623 {
624 for (j = 0; j < m_Pclist_y[i].n; j++)
625 m_Psrc_y_count[resampler_range_check(m_Pclist_y[i].p[j].pixel, m_resample_src_y)]++;
626 }
627
628 for (i = 0; i < MAX_SCAN_BUF_SIZE; i++)
629 {
630 m_Pscan_buf->scan_buf_y[i] = -1;
631
632 free(m_Pscan_buf->scan_buf_l[i]);
633 m_Pscan_buf->scan_buf_l[i] = NULL;
634 }
635 }
636
637 Resampler::Resampler(int src_x, int src_y,
638 int dst_x, int dst_y,

Callers

nothing calls this directly

Calls 2

resampler_range_checkFunction · 0.85
freeFunction · 0.85

Tested by

no test coverage detected