From: Mauro Carvalho Chehab Date: Thu, 6 Mar 2014 13:21:22 +0000 (-0300) Subject: libdvbv5: better document some MPEG TS fields X-Git-Tag: v4l-utils-1.2.0~149 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6f0f266701a15f463c1107ef5e0efce324a91b87;p=platform%2Fupstream%2Fv4l-utils.git libdvbv5: better document some MPEG TS fields Unfortunately, some names on this table don't reflect the names at the MPEG specs. Yet, we want to be clear what they mean, so let's improve the comments at the header.h and add a better description when debug is enabled. Signed-off-by: Mauro Carvalho Chehab --- diff --git a/lib/include/descriptors/header.h b/lib/include/descriptors/header.h index 08f2ac8..8ba93b0 100644 --- a/lib/include/descriptors/header.h +++ b/lib/include/descriptors/header.h @@ -17,6 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html * + * Described at ISO/IEC 13818-1 */ #ifndef _HEADER_H @@ -56,13 +57,13 @@ struct dvb_table_header { uint8_t syntax:1; } __attribute__((packed)); }; - uint16_t id; + uint16_t id; /* TS ID */ uint8_t current_next:1; uint8_t version:5; uint8_t one2:2; - uint8_t section_id; - uint8_t last_section; + uint8_t section_id; /* section_number */ + uint8_t last_section; /* last_section_number */ } __attribute__((packed)); struct dvb_v5_fe_parms; diff --git a/lib/libdvbv5/descriptors/header.c b/lib/libdvbv5/descriptors/header.c index 4453daf..f1ed873 100644 --- a/lib/libdvbv5/descriptors/header.c +++ b/lib/libdvbv5/descriptors/header.c @@ -32,17 +32,17 @@ int dvb_table_header_init(struct dvb_table_header *t) void dvb_table_header_print(struct dvb_v5_fe_parms *parms, const struct dvb_table_header *t) { - dvb_log("| table_id %d", t->table_id); - dvb_log("| section_length %d", t->section_length); - dvb_log("| zero %d", t->zero); - dvb_log("| one %d", t->one); - dvb_log("| zero2 %d", t->zero2); - dvb_log("| syntax %d", t->syntax); - dvb_log("| id %d", t->id); - dvb_log("| current_next %d", t->current_next); - dvb_log("| version %d", t->version); - dvb_log("| one2 %d", t->one2); - dvb_log("| section_id %d", t->section_id); - dvb_log("| last_section %d", t->last_section); + dvb_log("| table_id %d", t->table_id); + dvb_log("| section_length %d", t->section_length); + dvb_log("| zero %d", t->zero); + dvb_log("| one %d", t->one); + dvb_log("| zero2 %d", t->zero2); + dvb_log("| syntax %d", t->syntax); + dvb_log("| transport_stream_id %d", t->id); + dvb_log("| current_next %d", t->current_next); + dvb_log("| version %d", t->version); + dvb_log("| one2 %d", t->one2); + dvb_log("| section_number %d", t->section_id); + dvb_log("| last_section_number %d", t->last_section); }