From e2de64d6f1beb9e492daf5b886e19933c1fa41dd Mon Sep 17 00:00:00 2001 From: toma Date: Wed, 25 Nov 2009 17:56:58 +0000 Subject: Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdemultimedia@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- mpeglib/lib/input/inputStream.cpp | 135 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 mpeglib/lib/input/inputStream.cpp (limited to 'mpeglib/lib/input/inputStream.cpp') diff --git a/mpeglib/lib/input/inputStream.cpp b/mpeglib/lib/input/inputStream.cpp new file mode 100644 index 00000000..7eb9943b --- /dev/null +++ b/mpeglib/lib/input/inputStream.cpp @@ -0,0 +1,135 @@ +/* + generic input class + Copyright (C) 1999 Martin Vogt + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU Library General Public License as published by + the Free Software Foundation. + + For more information look at the file COPYRIGHT in this package + + */ + + +#include "inputStream.h" +#include "../util/mmx/mmx.h" + +#include + +using namespace std; + + +InputStream::InputStream() { + timeStampArray=new TimeStampArray((char*)"Input",3000); + urlBuffer=new DynBuffer(20); + // we call mm_support() here because it is the only position + // where we gurantee that not threads are + // running (the call is not thread safe) + // afer the call we never execute the asm part again + // and everything is fine + mm_support(); +} + + + +InputStream::~InputStream() { + delete timeStampArray; + delete urlBuffer; + +} + + +int InputStream::open(const char* dest) { + cout << "direct virtual call InputStream::open:"<insertTimeStamp(src,key,len); +} + +TimeStamp* InputStream::getTimeStamp(long key) { + return timeStampArray->getTimeStamp(key); +} + + +int InputStream::bytesUntilNext(long key) { + return timeStampArray->bytesUntilNext(key); +} + +void InputStream::print() { + cout << "direct virtual call InputStream::print"<getData(); +} + + +void InputStream::setUrl(const char* url) { + urlBuffer->clear(); + if (url != NULL) { + urlBuffer->append(url); + } +} + + + + + -- cgit v1.2.1