- Timestamp:
- 10/12/07 17:32:31 (6 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
experimental/components/Packetizer/trunk/Packetizer-metadata/src/PacketizerDSP.h
r5397 r5399 40 40 printf(msg); 41 41 42 #define PACKETIZER_DEFINE_ EXTRACT_API(X)\42 #define PACKETIZER_DEFINE_API(X) \ 43 43 bool X( \ 44 44 char* input, \ … … 123 123 /// \param[in,out] output_length number of (maximum) output bits written 124 124 /// \param[in] type type of packet to use 125 void CreatePacket( 126 PacketType type, 127 char* input, 128 unsigned int input_length, 129 char* output, 130 unsigned int output_length, 131 unsigned int &num_written); 125 PACKETIZER_DEFINE_API(CreatePacket) 132 126 133 127 /// \brief Completely finds and decodes a packet from raw data … … 138 132 /// \param[in] output_length number of output bits available in buffer 139 133 /// \param[out] num_written number of samples written to output buffer 140 PACKETIZER_DEFINE_ EXTRACT_API(ExtractPacket)134 PACKETIZER_DEFINE_API(ExtractPacket) 141 135 142 136 /// \brief Assembles a packet from pre-encoded data bits … … 147 141 /// \param[in] output_length number of output bits available in buffer 148 142 /// \param[out] num_written number of samples written to output buffer 149 void AssemblePacket( 150 char* input, 151 unsigned int input_length, 152 char* output, 153 unsigned int output_length, 154 unsigned int &num_written); 155 156 /// 157 void EncodePacketData( 158 char * input, 159 unsigned int input_length, 160 char * output, 161 unsigned int output_length, 162 unsigned int &num_written); 143 PACKETIZER_DEFINE_API(AssemblePacket) 144 145 /// 146 PACKETIZER_DEFINE_API(EncodePacketData) 163 147 164 148 /// Finds the packet header by correlating with the P/N sync code … … 175 159 /// \param[in] output_length number of output bits available in buffer 176 160 /// \param[out] num_written number of samples written to output buffer 177 PACKETIZER_DEFINE_ EXTRACT_API(ExtractHeader)161 PACKETIZER_DEFINE_API(ExtractHeader) 178 162 179 163 /// Extracts the basic packet type from the header … … 189 173 /// \param[in] output_length number of output bits available in buffer 190 174 /// \param[out] num_written number of samples written to output buffer 191 PACKETIZER_DEFINE_ EXTRACT_API(ExtractSubheader)175 PACKETIZER_DEFINE_API(ExtractSubheader) 192 176 193 177 /// … … 197 181 198 182 /// Extracts the remainder of the packet's raw data 199 PACKETIZER_DEFINE_EXTRACT_API(ExtractPacketData) 200 201 /// 202 bool DecodePacketData( 203 char * input, 204 unsigned int input_length, 205 char * output, 206 unsigned int output_length, 207 unsigned int &num_written); 183 PACKETIZER_DEFINE_API(ExtractPacketData) 184 185 /// 186 PACKETIZER_DEFINE_API(DecodePacketData) 208 187 209 188 protected: … … 257 236 258 237 /// 259 PACKETIZER_DEFINE_ EXTRACT_API(ExtractPacketDataDynamicLength)260 261 /// 262 PACKETIZER_DEFINE_ EXTRACT_API(ExtractPacketDataFixedLength)238 PACKETIZER_DEFINE_API(ExtractPacketDataDynamicLength) 239 240 /// 241 PACKETIZER_DEFINE_API(ExtractPacketDataFixedLength) 263 242 264 243 binary_sequence_t * pn_sync_buffer; ///<