H265 Decoder pipeline not working when use filesink

Hello,
I try to decode some .hevc file on Agx Orin Development Kit,
when i use these pipeline
gst-launch-1.0 filesrc location=sample.hevc ! h265parse ! nvv4l2decoder ! nv3dsink -e it works and play the video on screen
but when try to save decoded video as file and use these pipeline
gst-launch-1.0 filesrc location=sample.hevc ! h265parse ! nvv4l2decoder ! filesink location=test.yuv

I play video with ffmpeg and gst-play.

log is like these

Setting pipeline to PAUSED …
Opening in BLOCKING MODE
0:00:00.222750959 19455 0xaaaad5330600 WARN v4l2 gstv4l2object.c:4497:gst_v4l2_object_probe_caps:nvv4l2decoder0:src Failed to probe pixel aspect ratio with VIDIOC_CROPCAP: Unknown error -1
0:00:00.222832048 19455 0xaaaad5330600 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.222863824 19455 0xaaaad5330600 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.222883345 19455 0xaaaad5330600 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.222901713 19455 0xaaaad5330600 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.223314805 19455 0xaaaad5330600 WARN basesrc gstbasesrc.c:3600:gst_base_src_start_complete: pad not activated yet
Pipeline is PREROLLING …
NvMMLiteOpen : Block : BlockType = 279
NVMEDIA: Reading vendor.tegra.display-size : status: 6
NvMMLiteBlockCreate : Block : BlockType = 279
0:00:00.231115781 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.232029871 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xaaaad52345a0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.332526103 19455 0xaaaad5359460 WARN v4l2 gstv4l2object.c:4497:gst_v4l2_object_probe_caps:nvv4l2decoder0:src Failed to probe pixel aspect ratio with VIDIOC_CROPCAP: Unknown error -1
0:00:00.332566551 19455 0xaaaad5359460 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.332608023 19455 0xaaaad5359460 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.332621208 19455 0xaaaad5359460 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.332632408 19455 0xaaaad5359460 WARN v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0xaaaad5309ba0 Failed to determine interlace mode
0:00:00.332904954 19455 0xaaaad5359460 WARN v4l2videodec gstv4l2videodec.c:1836:gst_v4l2_video_dec_decide_allocation: Duration invalid, not setting latency
0:00:00.333539841 19455 0xaaaad5359460 WARN v4l2bufferpool gstv4l2bufferpool.c:1082:gst_v4l2_buffer_pool_start:nvv4l2decoder0:pool:src Uncertain or not enough buffers, enabling copy threshold
0:00:00.334145159 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.334196904 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7801aea0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.334444714 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.334476427 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7801a000 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.334741037 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.334767054 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808c6c0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.334913679 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.334938799 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808c900 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.335194130 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.335218482 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808c480 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.335401204 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.335462325 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808cc60 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.335717111 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.335743512 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808cea0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.335922937 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.335953914 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7810d240 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.336183996 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.336242877 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7810da20 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.339859842 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.339910306 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7810d480 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.341130031 19455 0xaaaad50a4580 WARN v4l2bufferpool gstv4l2bufferpool.c:1533:gst_v4l2_buffer_pool_dqbuf:nvv4l2decoder0:pool:src Driver should never set v4l2_buffer.field to ANY
Pipeline is PREROLLED …
Setting pipeline to PLAYING …
New clock: GstSystemClock
0:00:00.341738709 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.341777078 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7810dd80 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.346876010 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.346910250 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xaaaad52346c0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.351712924 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.351794012 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7801ac60 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.356231018 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.356278698 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff78185000 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.361524672 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.361578209 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808c7e0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.366233649 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.366278833 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff78185360 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.371240356 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.371285829 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7808cd80 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.376073110 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.376124950 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff7810d6c0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.380758342 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.380821671 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff781855a0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
0:00:00.386364511 19455 0xaaaad5359460 FIXME h265parse gsth265parse.c:1850:gst_h265_parse_parse_frame: Implement timestamp/duration interpolation based on SEI message
0:00:00.386440864 19455 0xaaaad5359460 WARN bufferpool gstbufferpool.c:1235:default_reset_buffer:nvv4l2decoder0:pool:sink Buffer 0xffff781857e0 without the memory tag has maxsize (0) that is smaller than the configured buffer pool size (4194304). The buffer will be not be reused. This is most likely a bug in this GstBufferPool subclass
^Chandling interrupt.

it is waiting after the New Clock line and do nothing, i tried a lot of pipeline, i got same result. I use last jetpack sdk.
It creates test.yuv file with 0 bytes,
when i interrupt the program with pressing Ctrl + C, it would be 704 bytes every time

Hi,
Please try the command:

gst-launch-1.0 filesrc location=sample.hevc ! h265parse ! nvv4l2decoder ! nvvidconv ! video/x-raw,format=I420 ! filesink location=test.yuv

The decoded YUV is in NVMM buffer and please copy to CPU buffer through nvvidconv plugin.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.