Open-AVB AVTP Pipeline SDK  1.4
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
openavb_map_mpeg2ts_pub.h
1 /*************************************************************************************************************
2 Copyright (c) 2012-2015, Symphony Teleca Corporation, a Harman International Industries, Incorporated company
3 All rights reserved.
4 
5 Redistribution and use in source and binary forms, with or without
6 modification, are permitted provided that the following conditions are met:
7 
8 1. Redistributions of source code must retain the above copyright notice, this
9  list of conditions and the following disclaimer.
10 2. Redistributions in binary form must reproduce the above copyright notice,
11  this list of conditions and the following disclaimer in the documentation
12  and/or other materials provided with the distribution.
13 
14 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS LISTED "AS IS" AND
15 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
16 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
17 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS LISTED BE LIABLE FOR
18 ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
19 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
20 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
21 ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
23 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24 
25 Attributions: The inih library portion of the source code is licensed from
26 Brush Technology and Ben Hoyt - Copyright (c) 2009, Brush Technology and Copyright (c) 2009, Ben Hoyt.
27 Complete license and copyright information can be found at
28 https://github.com/benhoyt/inih/commit/74d2ca064fb293bc60a77b0bd068075b293cf175.
29 *************************************************************************************************************/
30 
31 /*
32 * HEADER SUMMARY : Mpeg2 TS mapping module public interface
33 *
34 * Refer to IEC 61883-4 for details of the "source packet" structure.
35 *
36 * This mapping module module as a talker requires an interface module to push
37 * one source packet of 192 octets into the media queue along with a media queue
38 * time value when the first data block of the source packet was obtained.
39 * There is no need to place the timestamp witin the source packet header,
40 * this will be done within the mapping module were the max transit time will be
41 * added. The mapping module may bundle multiple source packets into one avtp packet
42 * before sending it.
43 *
44 * This mapping module module as a listener will parse source packets from the
45 * avtp packet and place each source packet of 192 octets into the media queue along
46 * with the correct time stamp from the source packet header. The interface module
47 * will pull each source packet from the media queue and present has needed.
48 *
49 * The protocol_specific_header, CIP header and the mpeg2 ts source packet header are
50 * all taken care of in the mapping module.
51 */
52 
53 #ifndef OPENAVB_MAP_MPEG2TS_PUB_H
54 #define OPENAVB_MAP_MPEG2TS_PUB_H 1
55 
56 #include "openavb_types_pub.h"
57 
58 // NOTE: A define is used for the MediaQDataFormat identifier because it is needed in separate execution units (static / dynamic libraries)
59 // that is why a single static (static/extern pattern) definition can not be used.
60 #define MapMpeg2tsMediaQDataFormat "Mpeg2ts"
61 
62 #endif // OPENAVB_MAP_MPEG2TS_PUB_H