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

Function hb_resume

libhb/hb.c:2042–2061  ·  view source on GitHub ↗

* Resumes the conversion process. * @param h Handle to hb_handle_t. */

Source from the content-addressed store, hash-verified

2040 * @param h Handle to hb_handle_t.
2041 */
2042void hb_resume( hb_handle_t * h )
2043{
2044 if( h->paused )
2045 {
2046 if (h->pause_date != -1)
2047 {
2048 // Calculate paused time for current job sequence
2049 h->pause_duration += hb_get_date() - h->pause_date;
2050
2051 // Calculate paused time for current job pass
2052 // Required to calculate accurate ETA for pass
2053 h->current_job->st_paused += hb_get_date() - h->pause_date;
2054 h->pause_date = -1;
2055 h->state.param.working.paused = h->pause_duration;
2056 }
2057
2058 hb_unlock( h->pause_lock );
2059 h->paused = 0;
2060 }
2061}
2062
2063/**
2064 * Stops the conversion process.

Callers 4

hb_stopFunction · 0.85
hb_scan_stopFunction · 0.85
EventLoopFunction · 0.85
ghb_resume_queueFunction · 0.85

Calls 2

hb_get_dateFunction · 0.85
hb_unlockFunction · 0.85

Tested by 1

EventLoopFunction · 0.68