1/**********
2This library is free software; you can redistribute it and/or modify it under
3the terms of the GNU Lesser General Public License as published by the
4Free Software Foundation; either version 3 of the License, or (at your
5option) any later version. (See <http://www.gnu.org/copyleft/lesser.html>.)
6
7This library is distributed in the hope that it will be useful, but WITHOUT
8ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
9FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
10more details.
11
12You should have received a copy of the GNU Lesser General Public License
13along with this library; if not, write to the Free Software Foundation, Inc.,
1451 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
15**********/
16// "liveMedia"
17// Copyright (c) 1996-2020 Live Networks, Inc. All rights reserved.
18// A filter that breaks up an H263 video elementary stream into frames.
19// Author Benhard Feiten
20
21#ifndef _H263PLUS_VIDEO_STREAM_FRAMER_HH
22#define _H263PLUS_VIDEO_STREAM_FRAMER_HH
23
24#ifndef _FRAMED_FILTER_HH
25#include "FramedFilter.hh"
26#endif
27
28
29class H263plusVideoStreamFramer: public FramedFilter {
30public:
31
32 static H263plusVideoStreamFramer* createNew(UsageEnvironment& env, FramedSource* inputSource);
33
34 Boolean& pictureEndMarker() { return fPictureEndMarker; } // a hack for implementing the RTP 'M' bit
35
36protected:
37 // Constructor called only by createNew(), or by subclass constructors
38 H263plusVideoStreamFramer(UsageEnvironment& env,
39 FramedSource* inputSource,
40 Boolean createParser = True);
41 virtual ~H263plusVideoStreamFramer();
42
43
44public:
45 static void continueReadProcessing(void* clientData,
46 unsigned char* ptr, unsigned size,
47 struct timeval presentationTime);
48 void continueReadProcessing();
49
50private:
51 virtual void doGetNextFrame();
52 virtual Boolean isH263plusVideoStreamFramer() const;
53
54protected:
55 double fFrameRate;
56 unsigned fPictureCount; // hack used to implement doGetNextFrame() ??
57 Boolean fPictureEndMarker;
58
59private:
60 class H263plusVideoStreamParser* fParser;
61 struct timeval fPresentationTimeBase;
62};
63
64#endif
65