diff options
author | John Stebbins <[email protected]> | 2015-11-13 19:38:02 -0800 |
---|---|---|
committer | John Stebbins <[email protected]> | 2016-01-21 10:09:44 -0700 |
commit | fcb78d5c24387bf2dad2e3c38b4417431b2836ae (patch) | |
tree | 8232f55f36175db115ee08ebd5f5e41c29c53949 /libhb/enc_qsv.c | |
parent | 56925edbfa59cda34d3fa45f4c61f48970cee5fb (diff) |
sync: gut and rewrite
sync.c was difficult to read, fragile, and prone to difficult to
diagnose bugs (see
https://forum.handbrake.fr/viewtopic.php?f=12&t=33147)
This rewrite simplifies the code, removes signals, locking and yield
that probably cause the above problem and is much more flexible. It
fixes a wider variety of timestamp issues than before and is much easier
to extend if other timestamp analysis is desired.
Diffstat (limited to 'libhb/enc_qsv.c')
-rw-r--r-- | libhb/enc_qsv.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libhb/enc_qsv.c b/libhb/enc_qsv.c index 360db65b5..87a180629 100644 --- a/libhb/enc_qsv.c +++ b/libhb/enc_qsv.c @@ -1966,6 +1966,9 @@ int encqsvWork(hb_work_object_t *w, hb_buffer_t **buf_in, hb_buffer_t **buf_out) { qsv_atom = in->qsv_details.qsv_atom; surface = av_qsv_get_last_stage(qsv_atom)->out.p_surface; + // At this point, enc_qsv takes ownership of the QSV resources + // in the 'in' buffer. + in->qsv_details.qsv_atom = NULL; /* * QSV decoding fills the QSV context's dts_seq list, we need to |