bilibili / ijkplayer

Android/iOS video player based on FFmpeg n3.4, with MediaCodec, VideoToolbox support.
GNU General Public License v2.0
32.6k stars 8.14k forks source link

Playing streaming video type is https. #16

Closed fantasy1022 closed 9 years ago

fantasy1022 commented 10 years ago

Hello, Thank you for awesome job to do this player. I have question about playing streaming video which protocol is https. This would cause playing error. Does it has any solution for this function? Thank you!

bbcallen commented 10 years ago

https support need build ffmpeg with openssl. Not support by current build script, yet

fantasy1022 commented 10 years ago

Does it means that add "--enable-openssl" command in compile-ffmpeg.sh ? I do not have much experience in ffmpeg, so can you describe more details how to do. Thank you!

bbcallen commented 10 years ago

Not enough. OpenSSL should be built first, then add OpenSSL directories to FFmpeg's CFLAGS, LDFLAGS, LIBS…

Then configure with --enable-nonfree --enable-openssl

fantasy1022 commented 10 years ago

I have been built OpenSSL, and it produce libcrypto.a and libssl.a. But I do not know how to set path of CFLAGS, LDFLAGS, LIBS. Can you give me some example? Thank you for help!

bbcallen commented 10 years ago

https://github.com/yixia/OpenSSL-Vitamio See how vitamio do

fantasy1022 commented 10 years ago

OK, I will try. Thank for your reply!

bbcallen commented 10 years ago

Do you have any video source for test?

fantasy1022 commented 10 years ago

I have a link, but it has been expired. Can you give me some test link? Thank you!

fantasy1022 commented 10 years ago

I find https streaming to test. Finally, I success that use ijkplayer playing streaming in https. Thank you for your help !!

chodison commented 10 years ago

can you give the https streaming url?

nchicas-phunware commented 10 years ago

Hi fantasy1022,

Any chance to get the build script or a brief explanation of how to add support for https?

I would greatly appreciate your help, thanks!

fantasy1022 commented 10 years ago

Hi Nchicas-phunware, I put ijkplayer library which can play video in HTTPs in my fork ijkplayer. You can reference this, thanks!

eversanchez12 commented 10 years ago

Hello fantasy1022 I was trying to use the DemoApp in your fork but is no working for me. How ca use it? I watch a lib folder in the DemoApp, could you tell me how can I use it and run the demo?. I would greatly appreciate your help, thanks!

fantasy1022 commented 10 years ago

Hi eversanchez12, Import three packages which are ijkmediademo, ijkmediaplayer, ijkmediawidget. The ijkmediademo package is the main APP, and the another are library to ijkmediademo. The ijkmediaplayer is library to ijkmediawidget. Try above-mentioned procedure!

mshibanami commented 9 years ago

Hi. bbcallen/ijkplayer has init-ios-openssl.sh and ios/compile-openssl.sh. Does It mean that ijkplayer supports OpenSSL for iOS? Is there any manual to build for it?

bbcallen commented 9 years ago

to mshibanami: Intent to, but haven't tested, yet.

mshibanami commented 9 years ago

Oh, I see. I hope it goes well. (^_^)

bbcallen commented 9 years ago

Tested

Zo2m4bie commented 8 years ago

@fantasy1022 Hello. I know it's kind of old question but I try to compile ffmpeg with openssl. And I see you mentioned above about adding --enable-openssl and adding openssl folder to compile-ffmpeg script in FF_CFG_FLAGS, FF_CFLAGS. I found at do-compile-ffmpeg this script:


if [ -f "${FF_DEP_OPENSSL_LIB}/libssl.a" ]; then
echo "then called"
  FF_CFG_FLAGS="$FF_CFG_FLAGS --enable-nonfree"
    FF_CFG_FLAGS="$FF_CFG_FLAGS --enable-openssl"

    FF_CFLAGS="$FF_CFLAGS -I${FF_DEP_OPENSSL_INC}"
    FF_DEP_LIBS="-L${FF_DEP_OPENSSL_LIB} -lssl -lcrypto"
fi 

As I understand this script adds openssl lib to FF_CFG_FLAGS and FF_CFLAGS. So ffmpeg has to compile with openssl, but my https streams still don't work. Unfortunately I cannot work with your compiled lib, because I made some changes in ffmpeg code. Can you provide some steps how to compile lib with openssl? Thank you!