tdlib / td

Cross-platform library for building Telegram clients
https://core.telegram.org/tdlib
Boost Software License 1.0
7.11k stars 1.44k forks source link

Some video types are not correctly recognized in tdlib #2895

Closed benwoniu630353 closed 5 months ago

benwoniu630353 commented 5 months ago

I built a tdlib small application and found that when the video type is .m4v, it is sent through tdlib and the tag type is video, but the telegram server recognizes it as document. However, I can upload it through telegram’s PC client or mobile APP and it will be displayed as video type after successful upload.

I don't know why

levlam commented 5 months ago

Do you use inputMessageVideo to upload video files?

benwoniu630353 commented 5 months ago

Do you use inputMessageVideo to upload video files?

Yeah,I use it!

TDLIB version 1.8.29 made a document fix. According to my observation, it should have fixed a recognition problem of video types containing the suffix .MEPG4. In previous versions, the .mpeg4 video type would also encounter I encountered the same problem. Now it can be recognized normally. But .m4v still cannot be recognized normally. If possible, please fix it in the next version.

benwoniu630353 commented 5 months ago

Do you use inputMessageVideo to upload video files?

MPEG4,not MEPG4

levlam commented 5 months ago

If you use inputMessageVideo and specify all fields there, then it is sent as a video. File extension doesn't matter. Whether an app receiving the video will be able to play it. depends on the target app.