The error was that I for one call doGetNextFrame several times calling afterGetting. For solution used by queue from stl.I think there is a shortage of examples to DeviceSource. The source code for opencv attached.22.01.2012, 15:48, "Ross Finlayson" :As I noted before, SPS (nal_unit_type 7) and PPS
As I noted before, SPS (nal_unit_type 7) and PPS (nal_unit_type 8) NAL units
*must* appear - at least once - in the sequence of NAL units that you feed to
"H264VideoStreamDiscreteFramer". Therefore, in your case, you must set your
"b_repeat_headers" variable to 1.
If this is causing a segmenta
If I set to 1, then there SIGSEGV and output:
referenceCount = 1
nals[i].i_type = 7
newFrameSize = 23 fTo[0]&0x1F = 7
nals[i].i_type = 8
newFrameSize = 4 fTo[0]&0x1F = 8
nals[i].i_type = 6
newFrameSize = 571 fTo[0]&0x1F = 5
nals[i].i_type = 5
newFrameSize = 39523 fTo[0]&0x1F = 8
referenceCo
> There is also an option: int b_repeat_headers; /* put SPS/PPS before each
> keyframe */. It should be set in 0?
I suggest setting this to 1, to ensure that the downstream
"H264VideoStreamDiscreteFramer" gets to see the SPS and PPS NAL units at least
once. (This is important, otherwise the R
Sorry. You are right. In x264.h written:int b_annexb; /* if set, place start codes (4 bytes) before NAL units, * otherwise place size (4 bytes) before NAL units. */Thus in any case, the first 4 bytes should be removed. There is also an option: int b_repeat_headers; /* put S
> Warning: Invalid 'nal_unit_type': 0. Does the NAL unit begin with a MPEG
> 'start code' by mistake?
This message means exactly what it says (and you can very easily see - in the
"H264VideoStreamDiscreteFramer" source code - where/why it's displayed).
Remember, You Have Complete Source Code.