diff options
author | deva <deva> | 2005-04-10 20:38:45 +0000 |
---|---|---|
committer | deva <deva> | 2005-04-10 20:38:45 +0000 |
commit | b03406e31c5e5d4f8a4e065b03e68330885a3832 (patch) | |
tree | 0d636129516814509df07afd918daef086be3133 /src/encoder.cc | |
parent | 55a7afdedc7cee2df9012f600dd51aff92ad1af3 (diff) |
lots of styff!
Diffstat (limited to 'src/encoder.cc')
-rw-r--r-- | src/encoder.cc | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/encoder.cc b/src/encoder.cc index 3a4ade2..ca8fb4f 100644 --- a/src/encoder.cc +++ b/src/encoder.cc @@ -69,18 +69,14 @@ Encoder::~Encoder() void Encoder::encode() { DVFrame *f; - printf("0\n"); while(*running) { - printf("1\n"); sem_wait(sem); - printf("2\n"); pthread_mutex_lock(mutex); f = queue->pop(); pthread_mutex_unlock(mutex); - printf("3\n"); if((f && record) || (freeze_request != freeze_value) || (shoot_request != shoot_value)) { @@ -91,6 +87,7 @@ void Encoder::encode() h.header.h_data.freeze = (freeze_request != freeze_value); h.header.h_data.snapshot = (shoot_request != shoot_value); h.header.h_data.record = record; + h.header.h_data.savestate = NO_CHANGE; if(freeze_request != freeze_value) freeze_value = freeze_request; if(shoot_request != shoot_value) shoot_value = shoot_request; @@ -147,7 +144,9 @@ void Encoder::start() { } -void Encoder::stop() { +void Encoder::stop(n_savestate save) { + // TODO: set save state in package header. + // TODO: Flush not yet sent video packages. record = 0; if(s) { if(n) delete n; |