Skip to content

Unable to play H264 Stream from Ambarella Camera #14

Description

@ranulphus

I have a number of H.264 cameras that output raw h264 data frames. I have made a player based on the OpenH264.NET example, decoding one frame at a time and displaying. This works for all but one of the cameras. There doesn’t seem to be anything unusual about the camera and VLC is able to play it fine from a file or UDP stream. I also built OpenH264 from source on Linux and ran the h264dec utility against the data and it seemed to have no issue decoding. Any ideas as to why there might be an issue with this one camera with OpenH264.NET?

    "streams": [
        {
            "index": 0,
            "codec_name": "h264",
            "codec_long_name": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",
            "profile": "Main",
            "codec_type": "video",
            "codec_time_base": "1001/60000",
            "codec_tag_string": "[0][0][0][0]",
            "codec_tag": "0x0000",
            "width": 432,
            "height": 240,
            "coded_width": 432,
            "coded_height": 240,
            "closed_captions": 0,
            "has_b_frames": 0,
            "sample_aspect_ratio": "1:1",
            "display_aspect_ratio": "9:5",
            "pix_fmt": "yuvj420p",
            "level": 21,
            "color_range": "pc",
            "chroma_location": "left",
            "field_order": "progressive",
            "refs": 1,
            "is_avc": "false",
            "nal_length_size": "0",
            "r_frame_rate": "30000/1001",
            "avg_frame_rate": "30000/1001",
            "time_base": "1/1200000",
            "bits_per_raw_sample": "8",
            "disposition": {
                "default": 0,
                "dub": 0,
                "original": 0,
                "comment": 0,
                "lyrics": 0,
                "karaoke": 0,
                "forced": 0,
                "hearing_impaired": 0,
                "visual_impaired": 0,
                "clean_effects": 0,
                "attached_pic": 0,
                "timed_thumbnails": 0
            }
        }
    ]

UPDATE: I can see that DecodeFrame2 is returning dsNoParamSets (16)
UPDATE2: It actually seems to alternate between frames, first dsNoParamSets (16) and then dsBitstreamError (4) the next frame...and so on

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions