User User name Password  
   
Saturday 8.6.2024 / 19:39
Search AfterDawn Forums:        In English   Suomeksi   På svenska
afterdawn.com > forums > digital video > video - everything else > how can pts (presentation time stamp) be decoded at the hex level?
Show topics
 
Forums
Forums
How can PTS (presentation time stamp) be decoded at the hex level?
  Jump to:
 
Posted Message
TheJoyOfHex
Newbie
_
14. March 2013 @ 18:08 _ Link to this message    Send private message to this user   
Can somebody please explain to me how to interpret the hex code of an MPEG header to read the presentation time stamp from a given packet?

My understanding is that the PTS information is a 33 bit integer (divisible by 90,000 to gain the value in seconds) but I haven't been able to work out the syntax of the bytes.

I've included below a sample of the hex from the file.

Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F

00000000 00 00 01 E0 7F 9A 87 C1 17 31 34 AB 89 C1 11 34
00000010 AB 19 41 0F 8B 80 7E 00 80 FF A0 A1 A2 6B EC 3B
00000020 00 00 01 00 00 00 01 20 00 88 40 19 28 58 21 20
00000030 A3 1F 00 00 01 B3 05 47 A7 00 00 01 B6 11 78 14
00000040 8B 83 C0 FD 2A 0F 0D 04 08 3C 57 F5 A0 F9 D0 24

FFprobe with the -show_packets option reports the following information:

[PACKET]
codec_type=video
stream_index=0
pts=220906720
pts_time=2454.519111
dts=220892320
dts_time=2454.359111
duration=900
duration_time=0.010000
convergence_duration=N/A
convergence_duration_time=N/A
size=32640
pos=0
flags=K
[/PACKET]

However, I've not been able work backwards from 220906720 in order to find how this number is derived.

Please help!
afterdawn.com > forums > digital video > video - everything else > how can pts (presentation time stamp) be decoded at the hex level?
 

Digital video: AfterDawn.com | AfterDawn Forums
Music: MP3Lizard.com
Gaming: Blasteroids.com | Blasteroids Forums | Compare game prices
Software: Software downloads
Blogs: User profile pages
RSS feeds: AfterDawn.com News | Software updates | AfterDawn Forums
International: AfterDawn in Finnish | AfterDawn in Swedish | AfterDawn in Norwegian | download.fi
Navigate: Search | Site map
About us: About AfterDawn Ltd | Advertise on our sites | Rules, Restrictions, Legal disclaimer & Privacy policy
Contact us: Send feedback | Contact our media sales team
 
  © 1999-2024 by AfterDawn Ltd.

  IDG TechNetwork