mbebenita / Broadway

A JavaScript H.264 decoder.
Other
2.73k stars 424 forks source link

h264 file can be played by VLC but can not be played by Player.js #204

Open xhy854 opened 5 years ago

xhy854 commented 5 years ago

I used VideoTool on MacOS to generate a H264 file and it can be played by VLC. I send each frame's compressed H264 data (which is consists of several NALUs) to an web client and try to decode the frames by player.decode() ,but the player doesn't work and canvas stays black and doesn't show any picture. I work with raw H264 instead of MP4 file ,thus I use Player directly. Is that due to certain parameters for the encoder which is VideoTool in my scenario?

soliton4 commented 5 years ago

its probably a profile missmatch broadway only supports baseline profile atm

TiepHoangDev commented 5 years ago

its probably a profile missmatch broadway only supports baseline profile atm

you can suggest how to convert to "baseline profile atm"?

soliton4 commented 5 years ago

you can use ffmpeg or any h264 encoder of choice openh264 can also encode in baseline profile