MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / UpdateState2

Function UpdateState2

libhb/scan.c:1878–1897  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1876}
1877
1878static void UpdateState2(hb_scan_t *scan, int title)
1879{
1880 hb_state_t state;
1881
1882 hb_get_state2(scan->h, &state);
1883#define p state.param.scanning
1884 /* Update the UI */
1885 state.state = HB_STATE_SCANNING;
1886 p.title_cur = title;
1887 p.title_count = hb_list_count( scan->title_set->list_title );
1888 p.preview_cur = 1;
1889 p.preview_count = scan->preview_count;
1890 if (scan->title_index)
1891 p.progress = (float)(p.title_cur - 1) / p.title_count;
1892 else
1893 p.progress = 0.5 + 0.5 * (float)(p.title_cur - 1) / p.title_count;
1894#undef p
1895
1896 hb_set_state(scan->h, &state);
1897}
1898
1899static void UpdateState3(hb_scan_t *scan, int preview)
1900{

Callers 1

ScanFuncFunction · 0.85

Calls 3

hb_get_state2Function · 0.85
hb_list_countFunction · 0.85
hb_set_stateFunction · 0.85

Tested by

no test coverage detected