Home  >  Q&A  >  body text

java - 播放软件是如何做到在线匹配字幕的?

突然想到了这个问题,网上搜了下好像并没有什么结果。我个人感觉是哈希值来匹配对应的视频文件,但是问题来了,就同一部电影来说不同的分辨率,不同的网友剪辑版本会导致同一部电影出现很多不同的哈希值,那么播放软件又是如何做到精确匹配的?谢谢

PHP中文网PHP中文网2741 days ago527

reply all(3)I'll reply

  • PHP中文网

    PHP中文网2017-04-18 10:33:53

    1. Hash matching

    2. File name matching, not accurate, may return multiple ones for the user to choose from. After one user selects, the hash can be recorded, and hash matching is used to match other users

    3. Video or audio feature matching can only match the features of the first few minutes, similar to listening to music and recognizing music, it can be regarded as an advanced hash matching

    Most users are ordinary users who look for ready-made resources and do not know how to edit themselves, so the first two methods can handle most situations.

    reply
    0
  • PHP中文网

    PHP中文网2017-04-18 10:33:53

    That’s pretty much what I said above
    I would like to add that the general method of Hash matching is to get the front, middle and last bytes of the file and take them out to calculate MD5

    reply
    0
  • ringa_lee

    ringa_lee2017-04-18 10:33:53

    Most of them are file names. Different videos correspond to different subtitles. If you search online, you will see that almost every version of a movie will correspond to a subtitle. Basically, if the file name (resolution, production team, version) does not match, Nine times out of ten, the subtitles are misaligned

    reply
    0
  • Cancelreply