mpeg5 / xevd Goto Github PK
View Code? Open in Web Editor NEWeXtra-fast Essential Video Decoder, MPEG-5 EVC (Essential Video Coding)
License: Other
eXtra-fast Essential Video Decoder, MPEG-5 EVC (Essential Video Coding)
License: Other
I guess xevd might have some global variables written during operation.
It makes a race condition between instances if several instances are created in an application.
Someone need to check whether xevd has risk of thread safe or not.
Currently, xevd supports only one SPS and PPS.
According to standardization, multiple SPS and PPS should be supported.
I was trying to build xevd in my linux - system
but During the build process, my system always sends this warnings and faild to "make"
/home/waganawa/문서/RA/xevd/src_main/xevdm.c: In function ‘xevd_apply_filter’:
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3204:34: error: storing the address of local variable ‘g_dra_control_effective’ in ‘*mctx.pps_dra_params’ [-Werror=dangling-pointer=]
3204 | mctx->pps_dra_params = (void )&(g_dra_control_effective.signalled_dra);
| ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3187:21: note: ‘g_dra_control_effective’ declared here
3187 | DRA_CONTROL g_dra_control_effective;
| ^~~~~~~~~~~~~~~~~~~~~~~
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3187:21: note: ‘ctx’ declared here
/home/waganawa/문서/RA/xevd/src_main/xevdm.c: In function ‘xevd_decode’:
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3610:34: error: storing the address of local variable ‘dra_control_effective’ in ‘(XEVDM_CTX *)id.pps_dra_params’ [-Werror=dangling-pointer=]
3610 | mctx->pps_dra_params = &(dra_control_effective.signalled_dra);
| ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3593:17: note: ‘dra_control_effective’ declared here
3593 | DRA_CONTROL dra_control_effective;
| ^~~~~~~~~~~~~~~~~~~~~
/home/waganawa/문서/RA/xevd/src_main/xevdm.c:3593:17: note: ‘id’ declared here
cc1: all warnings being treated as errors
is there something I missed?
inlined from 'xevd_recon_tree' at xevdm.c:1778:9:
xevdm.c:1124:9: warning: 'xevdm_IBC_mc' accessing 98304 bytes in a region of size 32768 [-Wstringop-overflow=]
1124 | xevdm_IBC_mc(x, y, log2_cuw, log2_cuh, core->mv[0], ctx->pic, core->pred[0], mcore->tree_cons, ctx->sps.chroma_format_idc);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
xevdm.c: In function 'xevd_recon_tree':
xevdm.c:1124:9: note: referencing argument 7 of type 'pel (*)[16384]' {aka 'short int (*)[16384]'}
In file included from xevdm_def.h:625,
from xevdm.c:38:
xevdm_mc.h:76:6: note: in a call to function 'xevdm_IBC_mc'
76 | void xevdm_IBC_mc(int x, int y, int log2_cuw, int log2_cuh, s16 mv[MV_D], XEVD_PIC *ref_pic, pel pred[N_C][MAX_CU_DIM], TREE_CONS tree_cons, int chroma_format_idc);
| ^~~~~~~~~~~~
I'm not sure but it seems to me that the xevd_config function call returns the incorrect value for the XEVD_CFG_GET_MAX_CODING_DELAY input parameter.
I mean the call like the following one:
xevd_config(id, XEVD_CFG_GET_MAX_CODING_DELAY, &max_coding_delay, &size);
Why do I think so?
It's because the function always returns the value of 0 even if the decoded stream was previously encoded with a value of bframes parameter other than zero.
While encoding the raw video stream I set XEVE_CDSC::param::bframes to be 15 (I did it just right before creating the encoder instance).
However, while decoding the previously encoded stream the value of XEVD_CFG_GET_MAX_CODING_DELAY received from SPS NALU was equal to 0.
I expect that the value of max encoding delay received by calling xevd_config(id, XEVD_CFG_GET_MAX_CODING_DELAY, &max_coding_delay, &size) will be the same, at least correlated to, as the value bframes set while encoding the stream.
Correct me If I'm wrong.
When function xevd_config(XEVD id, int cfg, void * buf, int * size) is used, xevd_app sample application and any other that is using xevd is crashing.
This happens because sometimes inside xevd_config sps from context is null.
Line 3553 in 1385ab5
Reproduction:
Line 522 in 1385ab5
Backtrace:
(gdb) bt
#0 xevd_config (id=0x7ffff7f83010, cfg=402, buf=0x7fffffffd978, size=0x7fffffffd990)
at /home/user/git/xevd/src_main/xevdm.c:3553
#1 0x0000555555559b80 in get_extra_config (id=0x7ffff7f83010)
at /home/user/git/xevd/app/xevd_app.c:202
#2 0x000055555555a9be in main (argc=5, argv=0x7fffffffdc98)
at /home/user/git/xevd/app/xevd_app.c:522
(gdb)
(gdb) p ctx
$1 = (XEVD_CTX *) 0x7ffff7f83010
(gdb) p ctx->sps
$2 = (XEVD_SPS *) 0x0
Hello! i'm trying build with -DARM=TRUE
with alpine linux via docker on an aarch64 host (mac book m3) but running into various build errors.
$ uname -a
Linux 00823b109f1f 6.6.16-linuxkit #1 SMP Fri Feb 16 11:54:02 UTC 2024 aarch64 Linux
$ mkdir build && cd build
$ cmake -DARM=TRUE ..
$ gcc --version
gcc (Alpine 13.2.1_git20231014) 13.2.1 20231014
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Some problems encountered:
/xevd/src_main/xevdm.c:3386:28: error: 'xevdm_itrans_map_tbl_neon' undeclared (first use in this function); did you mean 'xevdm_itrans_map_tbl'?
3386 | xevd_func_itrans = xevdm_itrans_map_tbl_neon;
/xevd/src_main/neon/xevdm_itdq_neon.c:1401:14: error: array subscript 16 is above array bounds of 'int32x4_t[16]' [-Werror=array-bounds=]
1401 | t[16] = vzip2q_s32(v[0], v[1]);
/xevd/src_main/neon/xevdm_mc_neon.c: In function 'xevdm_bl_mc_l_n0_neon':
/xevd/src_main/neon/xevdm_mc_neon.c:827:57: error: 'tbl_bl_mc_l_coeff' undeclared (first use in this function); did you mean 'tbl_mc_l_coeff'?
827 | mc_filter_bilin_horz_neon(ref, s_ref, pred, s_pred, tbl_bl_mc_l_coeff[dx], w, h, min, max, MAC_ADD_N0, MAC_SFT_N0, 1);
| ^~~~~~~~~~~~~~~~~
| tbl_mc_l_coeff
[ 171] NALU --> B-slice (4971 bytes, poc=123, tid=4, [L0 122 120 ] [L1 124 128 ]
End of file
bumping process starting...
I don't know why the decoder stops working
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.