Commit Graph

5105 Commits

Author SHA1 Message Date
jianglianfang c18976b40d vtun: add nv21
Signed-off-by: jianglianfang <jianglianfang@xiaomi.com>
2026-04-20 20:58:41 +08:00
p-chenhaijun10 39be95705c ffmpeg/libavdevice: fix warning.
CC:  ffmpeg/libavdevice/vtun_enc.c ffmpeg/libavdevice/vtun_enc.c: In function ‘vtun_write_uncoded_frame’:
ffmpeg/libavdevice/vtun_enc.c:318:60: warning: format ‘%lld’ expects argument of type ‘long long int’, but argument 4 has type ‘int64_t’ {aka ‘long int’} [-Wformat=]
  318 |         av_log(priv, AV_LOG_DEBUG, "vtun drop frame pts:%lld selected=%d\n", dequeue_frame->pts, selected);
      |                                                         ~~~^                 ~~~~~~~~~~~~~~~~~~
      |                                                            |                              |
      |                                                            long long int                  int64_t {aka long int}
      |                                                         %ld

Signed-off-by: p-chenhaijun10 <p-chenhaijun10@xiaomi.com>
2026-04-20 20:58:41 +08:00
yangsen5 89cda4ac7a ffmpeg: change log level of drop frame in vtun_enc to debug
Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2026-04-20 20:58:40 +08:00
zhushiqshi 816255cbb6 FFMPEG: implement to drop video frame smoothly
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:58:40 +08:00
wangwenchao10 7c164343f0 ffmpeg/libavformat:mod vtun frame_cnt range
Signed-off-by: wangwenchao10 <wangwenchao10@xiaomi.com>
2026-04-20 20:58:40 +08:00
fangyibo 0de7a29e32 ffmpeg: change registermq to open to adapt new upper driver
Signed-off-by: fangyibo <fangyibo@xiaomi.com>
2026-04-20 20:58:35 +08:00
jinxiuxu 0d358f92e3 ffmpeg: add unistd.h for close
libavdevice/alsa.c and libavfilter/alsa.c

Signed-off-by: jinxiuxu <jinxiuxu@xiaomi.com>
2026-04-20 20:58:32 +08:00
anjiahao a2afedb6b4 ffmpeg:add missing header file
ffmpeg/libavdevice/nuttx.c:206:5: error: implicit declaration of function 'close'; did you mean 'pclose'? [-Werror=implicit-function-declaration]
  206 |     close(fd);
      |     ^~~~~
      |     pclose
At top level:
ffmpeg/libavfilter/af_amix.c:727:5: error: implicit declaration of function 'close'; did you mean 'pclose'? [-Werror=implicit-function-declaration]
  727 |     close(s->timer_fd);
      |     ^~~~~
      |     pclose
ffmpeg/libavfilter/af_amix.c: In function 'process_command':
ffmpeg/libavfilter/af_amix.c:806:13: error: implicit declaration of function 'read'; did you mean 'fread'? [-Werror=implicit-function-declaration]
  806 |             read(pollfd->fd, &exp, sizeof(exp));
      |             ^~~~
      |             fread
ffmpeg/libavfilter/sink_movie_async.c:82:5: error: unknown type name 'pthread_cond_t'
   82 |     pthread_cond_t            cond;
      |     ^~~~~~~~~~~~~~
ffmpeg/libavfilter/sink_movie_async.c: In function 'moviesink_send_cmd':
ffmpeg/libavfilter/sink_movie_async.c:116:5: error: implicit declaration of function 'pthread_mutex_lock' [-Werror=implicit-function-declaration]
  116 |     pthread_mutex_lock(&priv->mutex);
      |     ^~~~~~~~~~~~~~~~~~
ffmpeg/libavfilter/sink_movie_async.c:118:5: error: implicit declaration of function 'pthread_cond_signal' [-Werror=implicit-function-declaration]
  118 |     pthread_cond_signal(&priv->cond);
      |     ^~~~~~~~~~~~~~~~~~~
ffmpeg/libavfilter/sink_movie_async.c:119:5: error: implicit declaration of function 'pthread_mutex_unlock'; did you mean 'nxrmutex_unlock'? [-Werror=implicit-function-declaration]
  119 |     pthread_mutex_unlock(&priv->mutex);
      |     ^~~~~~~~~~~~~~~~~~~~
      |     nxrmutex_unlock
ffmpeg/libavfilter/sink_movie_async.c: In function 'moviesink_thread':
ffmpeg/libavfilter/sink_movie_async.c:669:13: error: implicit declaration of function 'pthread_cond_wait' [-Werror=implicit-function-declaration]
  669 |             pthread_cond_wait(&priv->cond, &priv->mutex);
      |             ^~~~~~~~~~~~~~~~~
ffmpeg/libavfilter/sink_movie_async.c: In function 'moviesink_uninit':
ffmpeg/libavfilter/sink_movie_async.c:763:5: error: implicit declaration of function 'pthread_mutex_destroy'; did you mean 'nxrmutex_destroy'? [-Werror=implicit-function-declaration]
  763 |     pthread_mutex_destroy(&priv->mutex);
      |     ^~~~~~~~~~~~~~~~~~~~~
      |     nxrmutex_destroy
ffmpeg/libavfilter/sink_movie_async.c:764:5: error: implicit declaration of function 'pthread_cond_destroy' [-Werror=implicit-function-declaration]

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2026-04-20 20:58:32 +08:00
wurui3 5942cbff28 ffmpeg/libavdevices: convert AUDIO_SUBFMT_AMR_XXX to AUDIO_FMT_AMRXXX.
Signed-off-by: wurui3 <wurui3@xiaomi.com>
2026-04-20 20:58:32 +08:00
wurui3 78d1671636 ffmpeg/libavdevice: transfer subfmt to avcodec.
Avcodec should depends on not only subfmt as well as fmt.

Signed-off-by: wurui3 <wurui3@xiaomi.com>
2026-04-20 20:58:32 +08:00
yangliming bb407307a6 fix ffmpeg video compile error
./ffmpeg/libavdevice/fbdev_common.h:28:10: fatal error: features.h: No such file or directory
   28 | #include <features.h>
      |          ^~~~~~~~~~~~
compilation terminated.

Signed-off-by: yangliming <yangliming@xiaomi.com>
2026-04-20 20:58:27 +08:00
yangyalei faa7fffd52 FFMPEG: adapt nuttx_enc to ffmpeg 7.x
Signed-off-by: yangyalei <yangyalei@xiaomi.com>
2026-04-20 20:58:05 +08:00
yuexinyi 846cae495e ffmpeg:enable bluelet enc device
Signed-off-by: yuexinyi <yuexinyi@xiaomi.com>
2026-04-20 20:58:02 +08:00
yangyalei 968003a1f3 ffmpeg: include alsa with alsa/asoundlib.h
Signed-off-by: yangyalei <yangyalei@xiaomi.com>
2026-04-20 20:58:00 +08:00
yangyalei 0705eca94a ffmpeg: Optimize the log refresh screen
Signed-off-by: yangyalei <yangyalei@xiaomi.com>
2026-04-20 20:58:00 +08:00
yaojingwei f3a4ace3ce ffmpeg: add video vtun device for graphic application.
Signed-off-by: yaojingwei <yaojingwei@xiaomi.com>
2026-04-20 20:58:00 +08:00
fangyibo caf7d923a6 ffmpeg: alsa outdev compile support
Signed-off-by: fangyibo <fangyibo@xiaomi.com>
2026-04-20 20:57:59 +08:00
yaojingwei f0b733a253 ffmpeg: support write uncoded frame for fbdev to reduce memory copy.
Relate patch is
https://gerrit.pt.mioffice.cn/c/vela/external/ffmpeg/+/905020.

Signed-off-by: yaojingwei <yaojingwei@xiaomi.com>
2026-04-20 20:57:59 +08:00
jihandong 700a8c56ac ffmpeg/fbdev: support nuttx
Signed-off-by: jihandong <jihandong@xiaomi.com>
2026-04-20 20:57:59 +08:00
zhushiqshi 1ff9e38fd7 ffmpeg7: rm avdevice-nx.h file then merge into avdevice.h
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:56 +08:00
zhushiqshi 41d399dbeb ffmpeg7: Fix compilation errors due to reflow history
reflow file list:
libavdevice/bluelet.h
libavdevice/bluelet.c
libavdevice/bluelet_dec.c
libavdevice/bluelet_enc.c
+libavdevice/nuttx.h
+libavdevice/nuttx.c
libavdevice/nuttx_dec.c
+libavdevice/nuttx_enc.c
+libavfilter/asink_adevsink.c
libavfilter/asrc_adevsrc.c
libavfilter/asrc_anxsrc.c

Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:56 +08:00
openvela-robot bb23d7ba29 Merge remote-tracking branch 'origin/trunk-filter-20241205' into dev-feature-ffmpeg-7.x
add the follow files with history
libavdevice/bluelet.h
libavdevice/bluelet.c
libavdevice/bluelet_dec.c
libavdevice/bluelet_enc.c
libavdevice/nuttx.h
libavdevice/nuttx.c
libavdevice/nuttx_dec.c
libavdevice/nuttx_enc.c
libavfilter/asink_adevsink.c
libavfilter/asrc_adevsrc.c
2026-04-20 20:57:56 +08:00
openvela-robot 79d0634421 ffmpeg7: fixed amix format when graph load
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:53 +08:00
openvela-robot edde7d2512 ffmpeg: Resolve the issue of recording hanging in the trunk branch
When recording PCM data with the parameters format=s16le:sample_rate=48000:ch_layout=mono, the size is 45. The memcpy buffer size on the driver side is 32, which is too small, leading to an overflow and overwriting values on the stack.

Signed-off-by: zhangsenlin <zhangsenlin@xiaomi.com>
2026-04-20 20:57:51 +08:00
openvela-robot 225a503d52 FFMPEG: fix AVPacket mem leak
Signed-off-by: yangyalei <yangyalei@xiaomi.com>
2026-04-20 20:57:50 +08:00
openvela-robot 6fb822a912 ffmpeg7: add avformat_write_trailer for adevsink
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:47 +08:00
openvela-robot 32ee48238c adevsink:only do grahp reconfig in start flow
Resolve audio ending process interrupted by adevsink non start command

Signed-off-by: shipei <shipei@xiaomi.com>
2026-04-20 20:57:39 +08:00
yangsen5 732e1681e2 ffmpeg: set paused to false when close
Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2026-04-20 20:57:32 +08:00
yangsen5 bc745c54b0 ffmpeg: Do not judge playback underflow before start
Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2026-04-20 20:57:32 +08:00
zhushiqshi 98e06d9329 FFMPEG: porting nuttx_enc for avdevice
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:32 +08:00
openvela-robot 3608e86b4f FFMPEG: fix sys/syscrl.h can not find
Signed-off-by: zhushiqshi <zhushiqshi@xiaomi.com>
2026-04-20 20:57:30 +08:00
openvela-robot a6c20059ed FFMPEG: add resume when eos is on
when eos is on, we should resume the stream if it is paused.

Signed-off-by: jinxiuxu <jinxiuxu@xiaomi.com>
2026-04-20 20:57:27 +08:00
openvela-robot 6cf52fc3f3 swscale/output: fill all the xv36le alpha bits
The format is 10 bit per component, not 8.

Signed-off-by: James Almer <jamrial@gmail.com>
2026-04-20 20:57:24 +08:00
openvela-robot 356c47e109 FFMPEG: force start and stop after configure for driver
Signed-off-by: hanqiyuan <hanqiyuan@xiaomi.com>
2026-04-20 20:57:20 +08:00
Ramiro Polla e547e1abb3 avdevice/dshow: fix unused variable warning
The acaps variable was used outside of the #if DSHOWDEBUG block with
a1c4929f, but it is no longer used outside of the block since f125c504.
2026-04-20 20:57:18 +08:00
openvela-robot dccba787a1 fftools/ffmpeg_demux: use proper logging contexts everywhere 2026-04-20 20:57:15 +08:00
openvela-robot 1e2e93b397 FFMPEG: only back completed msg when running state.
Signed-off-by: qiaohaijiao1 <qiaohaijiao1@xiaomi.com>
2026-04-20 20:57:12 +08:00
Anton Khirnov 845a2b520b lavf: add a header for generic-layer interfaces
Analogous to what was previously done in avcodec and avfilter.
2026-04-20 20:57:09 +08:00
openvela-robot 34d0892357 configure: Only try to use the -no_warn_duplicate_libraries flag on Darwin
While we only add the flag if the linker seems to support it,
it turns out that ld.bfd had a bug where the flag is accidentally
accepted, and the flag produces an output file named
"_warn_duplicate_libraries".

The ld.bfd bug was fixed in binutils 2.36, in
https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=3991c7acb29aa8d7d52150695eb3efa03a08dd50.

Signed-off-by: Martin Storsjö <martin@martin.st>
2026-04-20 20:57:04 +08:00
openvela-robot c8c957ba35 adevsrc: modify the type of codec_id option param to string.
codec_id=65544 => codec_name=pcm_s32le.

Signed-off-by: yaojingwei <yaojingwei@xiaomi.com>
2026-04-20 20:57:01 +08:00
openvela-robot 2006b05fae avcodec/hevc/ps: return a proper error code when we don't support parsing an sps
Signed-off-by: James Almer <jamrial@gmail.com>
2026-04-20 20:56:54 +08:00
openvela-robot 79836cf6b9 FFMPEG: ff_nuttx_capbility_query_ranges not relay on AVFormatContext
Signed-off-by: yangyalei <yangyalei@xiaomi.com>
2026-04-20 20:56:51 +08:00
openvela-robot 48ade96938 lavfi/buffersink: add array-type options to replace "int-list" ones
"int-list" options are a hack that provides rudimentary support for
array-type options by treating them as byte arrays (i.e.
AV_OPT_TYPE_BINARY). Since we now have proper array-type options, they
should replace "int-list" everywhere (which happens to be just
buffersink).
2026-04-20 20:56:25 +08:00
openvela-robot 53a6ff767c FFmpeg/bluelet: output bluelet send & recv timer duration.
Signed-off-by: zhaocheng1 <zhaocheng1@xiaomi.com>
2026-04-20 20:56:22 +08:00
openvela-robot 0f949a99a6 MAINTAINERS: update myself for dvdvideo, rcwtdec, rcwtenc
I plan to look after and test them for the forseeable future.
I am not a committer but do care for these muxers/demuxers.

Signed-off-by: Marth64 <marth64@proxyid.net>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2026-04-20 20:56:19 +08:00
openvela-robot 3450efdfb3 asrc_dev: add codec option param.
Signed-off-by: yaojingwei <yaojingwei@xiaomi.com>
2026-04-20 20:56:16 +08:00
Marvin Scholz 6956a51b01 avdevice/decklink_dec: fix leaks on error
In case of errors in this function, the allocated context
was not properly freed in several cases.

Signed-off-by: Marton Balint <cus@passwd.hu>
2026-04-20 20:56:14 +08:00
Marvin Scholz 1ad33da9ee avdevice/decklink_dec: fix leak on error
In the early return when both draw_bars and signal_loss_action
options are used, the context allocated previously was not
properly freed.

Introduced in 9bcb86b0fa58f1a5a2a8613065349e26abadb329

Fixes CID1619296

Signed-off-by: Marton Balint <cus@passwd.hu>
2026-04-20 20:56:14 +08:00
Anton Khirnov f47969342f lavd/lavfi: stop using avfilter_graph_create_filter() incorrectly
See previous commits for details.
2026-04-20 20:56:13 +08:00
Marvin Scholz 77881ea9d8 avdevice/avfoundation: remove write-only variable
The block_buffer was only ever written to but then never used in the
following code, making it unnecessary.

Fixes a "variable 'block_buffer' set but not used" compiler warning.
2026-04-20 20:56:07 +08:00