h.264

Decode H264 From Array of Integers

半世苍凉 提交于 2019-12-23 15:38:05
问题 I'm trying to decode a H264 raw protocol from a camera but I'm having some problems using the Jcodec H264Decoder. I receive an array of integers with the information from the camera. Below a sample of the data: array: 00 00 01 FD 00 00 14 69 00 00 00 01 61 E4 80 6F D3 5B 76 97 DF 04 3A EF 54 97 0E D9 F5...more The code I'm using is : ByteBuffer bb = ByteBuffer.wrap( Utils.intArrayToByteArray(array, arraySize) ); bb.rewind(); // Create a buffer to hold the output picture which is big enough

How to convert H.264 UDP packets to playable media stream or file (defragmentation)

允我心安 提交于 2019-12-23 10:54:08
问题 I am missing some fundamental thing in translating an UDP stream of a SDP session into a decodable H.264 stream. I am testing with a H.264 capable camera and can play the stream with a player directly. When I try to play the translated stream it will not be recognized by the player (missing header error). However I have to decode the UDP stream to be able to integrate this in a Java application for which there are some decoders around. I have seen very good answers to following questions

H.264 decoding error log from RTSP stream

泄露秘密 提交于 2019-12-23 07:49:15
问题 I am getting the following H264 error log. This log comes while decoding an RTSP video stream with help of FFMPEG. The picture displayed is blurred after 5/6 seconds. The picture would recover it from time to time. However, it remains blurred for most of the time. EDIT: Some FFMPEG discussion forums suggested to upgrade FFMPEG version to avoid these logs. I have updated the latest FFMPEG build of June 19, 2015.Still the log remains there and picture is still blurred. EDIT 2: The RTSP stream

Recording cross-platform (H.264?) videos using WebRTC MediaRecorder

感情迁移 提交于 2019-12-23 07:32:03
问题 I have the following specified with my MediaRecorder implementation: const getMediaRecorderOptions = function () { var options = { mimeType: "video/webm;codecs=vp8" }; // 9 was lagggy, cpu-intensive if (!MediaRecorder.isTypeSupported(options.mimeType)) { logger.recorderLog(options.mimeType + " is not Supported"); options = { mimeType: "video/webm;codecs=vp8" }; if (!MediaRecorder.isTypeSupported(options.mimeType)) { logger.recorderLog(options.mimeType + " is not Supported"); options = {

It takes too long time to mux h264 into mp4 file using mp4parser

怎甘沉沦 提交于 2019-12-23 04:50:38
问题 I'm using mp4parser to mux h264 file and aac file into mp4 file.And the code is as belows. String h264Path = "path to my h264 file, generated by Android MediaCodec"; DataSource videoFile = new FileDataSourceImpl(h264Path); H264TrackImpl h264Track = new H264TrackImpl(videoFile, "eng", 5, 1); // 5fps. you can play with timescale and timetick to get non integer fps, 23.967 is 24000/1001 Movie movie = new Movie(); movie.addTrack(h264Track); Container out = new DefaultMp4Builder().build(movie);

H264 format doesn't audio how to get audio in h264

∥☆過路亽.° 提交于 2019-12-23 04:46:02
问题 I am getting data from Camera and I am trying to convert NV21 data to .H264 format. I am done this with MediaCodec but When I saved .H264 format it doesn't have audio and only playing Video at VLC media player. I want to play Video with its audio.Can I do this with using .H264 format or Do I use other converting format? How can do this? I shared below my code. private synchronized void encode(byte[] data) { ByteBuffer[] inputBuffers = mMediaCodec.getInputBuffers(); ByteBuffer[] outputBuffers

mux raw h 264 to an mp4 file, some odd errors

删除回忆录丶 提交于 2019-12-23 02:01:33
问题 What I'm doing is on an IOS app with Xcode 7.3. I got h264 data from an ip camera using UDP,the data can be decoded and displayed rightly (decoded by ffmpeg). Now I want to mux the raw H264 data to an mp4 file(some users may want to record what they are watching on his cell-phone), using ffmpeg. Nothing wrong happened when the code is running, and the result file can be played normally with QuickTime on my computer. But when played on iphone with iphone's default video player, it can't be

H264 parsing - slice header detection

一笑奈何 提交于 2019-12-22 17:08:06
问题 I know that in h264 we can detect a NAL Unit by the bit pattern 0x000001 . Is there an equivalent method to detect a slice header in a NAL Unit? How does one handle multi-slice NAL units? Currently I'm using parsing code for h264 and get the slice header in a respective structure. 回答1: The slice header syntax is discussed on page 36 (section 7.3.3) of the H.264 standard. It might be worth having a look at the reference software. 来源: https://stackoverflow.com/questions/10612893/h264-parsing

H264 parsing - slice header detection

时间秒杀一切 提交于 2019-12-22 17:07:27
问题 I know that in h264 we can detect a NAL Unit by the bit pattern 0x000001 . Is there an equivalent method to detect a slice header in a NAL Unit? How does one handle multi-slice NAL units? Currently I'm using parsing code for h264 and get the slice header in a respective structure. 回答1: The slice header syntax is discussed on page 36 (section 7.3.3) of the H.264 standard. It might be worth having a look at the reference software. 来源: https://stackoverflow.com/questions/10612893/h264-parsing

Setting larger GOP size in MediaFoundation hardware MFT

天大地大妈咪最大 提交于 2019-12-22 10:09:36
问题 I'm trying to live stream the desktop that's captured through Desktop duplication API. H264 encoding works fine, except the fact that the Desktop duplication API delivers frames only when there is a screen change, but video encoders expect the frames to be delivered at a constant frame rate. So, I'm forced to save the previous sample to feed the encoder at a constant rate when there is no screen change triggered. This works, I could see live output at the other end. One problem though, the