diff options
Diffstat (limited to 'lib/frame.cc')
-rw-r--r-- | lib/frame.cc | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/lib/frame.cc b/lib/frame.cc index 3a6c1eb..fb7f6f3 100644 --- a/lib/frame.cc +++ b/lib/frame.cc @@ -3,7 +3,7 @@ * frame.cc * * Mon Nov 15 19:45:07 CET 2004 - * Copyright 2004 Bent Bisballe + * Copyright 2004 Bent Bisballe Nyeng * deva@aasimon.org ****************************************************************************/ @@ -24,9 +24,10 @@ * along with MIaV; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#include <config.h> #include "frame.h" +#include "info.h" + #include <memory.h> #include <stdlib.h> @@ -43,6 +44,14 @@ Frame::Frame(char *vframe, int vframesize, video_format_t vformat, this->aframesize = aframesize; this->aformat = aformat; + timecode.hour = 0; + timecode.min = 0; + timecode.sec = 0; + timecode.frame = 0; + + freeze = false; + snapshot = false; + // FIX... remove when old code is removed data = NULL; } @@ -59,12 +68,14 @@ Frame::Frame(char *vframe, int vframesize, video_format_t vformat, */ Frame::Frame(unsigned char *d, int sz) { + MIaV::info->error("Allocated a frame in the old way!"); + if(sz) data = new unsigned char[sz]; if(sz && d) memcpy(data, d, sz); if(sz == 0 && d) data = d; size = sz; number = 0; - memset(timecode, 0, sizeof(timecode)); + memset(timestamp, 0, sizeof(timestamp)); endOfFrameStream = false; |