summaryrefslogtreecommitdiff
path: root/src/libfame_wrapper.cc
diff options
context:
space:
mode:
authordeva <deva>2005-07-22 15:59:39 +0000
committerdeva <deva>2005-07-22 15:59:39 +0000
commitf9733b615614a990d3e047f251b4ad1ea48a0534 (patch)
treeb73c2304ab5984da394bf382302fd9d9b1c8c60f /src/libfame_wrapper.cc
parent5d12a7bbc5d935e56afcea2d8af60e08ff82f02f (diff)
*** empty log message ***
Diffstat (limited to 'src/libfame_wrapper.cc')
-rw-r--r--src/libfame_wrapper.cc11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/libfame_wrapper.cc b/src/libfame_wrapper.cc
index 64eb9f5..a7e52e3 100644
--- a/src/libfame_wrapper.cc
+++ b/src/libfame_wrapper.cc
@@ -31,6 +31,9 @@
/*
* $Log$
+ * Revision 1.3 2005/07/22 15:59:39 deva
+ * *** empty log message ***
+ *
* Revision 1.2 2005/07/05 23:15:16 deva
* *** empty log message ***
*
@@ -239,15 +242,17 @@ Frame *LibFAMEWrapper::encode(Frame *dvframe)
// Allocate a new frame for the output
Frame *output = new Frame(NULL, FAME_BUFFER_SIZE);
- output->size = 0;
- unsigned char* pt = output->data;
+
+ // Init frame params
+ dv_get_timestamp(dvdecoder, output->timecode); // Set timecode
+ output->size = 0; // Init size (incremented as we read)
+ unsigned char* pt = output->data; // Set pointer to start of data buffer
// Encode YUV frame and write it to disk.
fame_start_frame(fame_context, &yuv, 0);
int written;
while((written = fame_encode_slice(fame_context))) {
- // fwrite(fame_buffer, written, 1, f);
memcpy(pt, fame_buffer, written);
pt += written;
output->size += written;