[Zapping-misc] Unable to get closed caption from vbi
Status: Alpha
Brought to you by:
mschimek
From: Anshul <er....@gm...> - 2015-09-28 10:09:48
|
Hello, I have dumped raw vbi file and trying to get closed caption data from it. I have taken vbi_raw_decoder structure and set its parameter to following value: *scanning = 525.* scanning was set to 525 since in GXF media type was mpeg2 525 its line per frame is also equal to 525 In GXF docs they also said that "The eight most significant bits of the 10-bit sample words shall be stored as uncompressed VBI data. The two least significant bits of each sample shall be discarded. I dont why they have removed 2 bit from lsb, they should have removed 2 bit from msb because in vanc 2 msb represent parity and not of bit 8. but I am not sure that vbi data would contain vanc or something else. so there might be some reason to remove 2 bit lsb. My Question is should I convert 720 bytes to 720word and add some dummy value in lsb. In my GXF video I dont have color difference data but I have luma data, dont know if its called luma difference data, so basically I am confused since I have not told zvbi decoder that data is luma or color difference not sure about following: rd.sampling_format = VBI_PIXFMT_YUV420; I have a chart in GXF video which say your video could be of 50Hz, 59.94Hz, 24/23.98Hz, 25Hz, 30/29.97 Hz but I have feeling that above sample rate is not what zvbi want. I have to search for saample rate some where else. so not sure about following: sampling_rate = 13.5e6; /* Hz */ In GXF specs they say that "Each line shall consist of 720 bytes of luma or color difference data." thats why I have set: bytes_per_line = 720 not sure about this too: offset = 9.7e-6 * 13.5e6; not sure about this too: start[0] = 21; count[0] = 1; not sure about this too: start[1] = 284; count[1] = 1; GXF say that Fields per frame are interlaced interlaced = TRUE; Not sure about it: synchronous = TRUE; I do want caption, may be cdat or vanc so selected since this one looks more promising vbi_raw_decoder_add_services (&my_struct_address, VBI_SLICED_CAPTION_525, 0); /* Decoding loop. Execute once for each frame. */ If some one wants to point me out with some document that would also be much help, I find very little documentation about vbi on internet. Thanks Anshul |