OpenVisualCloud / SVT-JPEG-XS

Welcome to the SVT JPEG XS codec Repository.
Other
43 stars 5 forks source link

svt jpeg xs doesn't create file #2

Open Jamaika1 opened 5 months ago

Jamaika1 commented 5 months ago

ffmpeg_avx.exe -v debug -i "image_21447_24bit.png" -y -f image2 -c:v libsvtjpegxs -an -frames:v 1 -bpp 24 -pix_fmt rgb24 output_jxs.jxs

-------------------------------------------
SVT [version]:  SVT-JPEGXS Encoder Lib v0.9
SVT [build]  :  GCC 14.1.0       64 bit
LIB Build date: Jun  8 2024 16:15:58
-------------------------------------------
[asm level on system : up to sse2]
[asm level selected : up to sse2]
Max Quantization 19, Max Refinement: 29
Number of logical cores available: 4
Number of PPCS 10
slice pack input count 4
slice pack output count 4
-------------------------------------------
SVT [config]: Resolution [width x height]               : 4000 x 3000
SVT [config]: EncoderBitDepth / EncoderColorFormat      : 8 / PACKED YUV444 OR RGB
SVT [config]: Slice height                              : 16
SVT [config]: Rate Control                              : 0:CBR per precinct
SVT [config]: Coding Type: Significance                 : Enabled
SVT [config]: Coding Type: Vertical Prediction          : Disabled
SVT [config]: Coding Type: Signs handling               : Disabled
SVT [config]: Vertical / Horizontal                     : 2 / 5
SVT [config]: Quantization method                       : Deadzone
SVT [config]: BPP / Compression Ratio                   : 24 / 1.00
SVT [config]: Profile Latency, Slice Threads            : 2
SvtMalloc[info]: SVT Memory Usage:
SvtMalloc[info]:     total allocated memory:       1.23 MB
SvtMalloc[info]:         malloced memory:          0.73 KB
SvtMalloc[info]:         callocated memory:        1.02 MB
SvtMalloc[info]:         allocated aligned memory: 213.91 KB
SvtMalloc[info]:     mutex count: 20
SvtMalloc[info]:     semaphore count: 11
SvtMalloc[info]:     thread count: 4
SvtMalloc[info]:     hash table fulless: 0.000068, hash bucket is healthy
SvtMalloc[info]: top 6 calloced memory locations:
SvtMalloc[info]: (234.39 KB): PackStageProcess.c:224
SvtMalloc[info]: (210.94 KB): PackStageProcess.c:233
SvtMalloc[info]: (140.63 KB): GcStageProcess.c:836
SvtMalloc[info]: (93.77 KB): GcStageProcess.c:835
SvtMalloc[info]: (93.75 KB): GcStageProcess.c:834
SvtMalloc[info]: (92.05 KB): PackStageProcess.c:241
SvtMalloc[info]: top 1 aligned memory locations:
SvtMalloc[info]: (187.50 KB): PackStageProcess.c:248
svt_jpeg_xs_encoder_init ok
Output #0, image2, to 'output_jxs.jxs':
  Metadata:
    encoder         : Lavf61.3.104
  Stream #0:0, 0, 1/25: Video: jpegxs, 1 reference frame, rgb24(pc, gbr/unknown/unknown, progressive), 4000x3000, 0/1, q=2-31, 200 kb/s, 25 fps, 25 tbn
      Metadata:
        encoder         : Lavc61.7.100 libsvtjpegxs
frame=    0 fps=0.0 q=0.0 size=       0KiB time=N/A bitrate=N/A speed=N/A
Jamaika1 commented 5 months ago

Why does svt-jpeg-xs have thread functions in common with svt-av1 for ffmpeg?

tszumski commented 5 months ago

Thank you for reporting issue. With regards to svt-jpeg-xs have thread functions in common with svt-av1 this issue will be resolved in next release. With regards to svt jpeg xs doesn't create file I cannot reproduce your issue, From logs "Lavf61.3.104" suggest that you are using ffmpeg 7.0 release. Could you check if the same issue happen with recommended 6.1 ?

MartinEesmaa commented 5 months ago

Hi, @Jamaika1!

Why does svt-jpeg-xs have thread functions in common with svt-av1 for ffmpeg?

I had same problem, but there were many multiple definitions. To avoid multiple definitions, we have to change from svt_full_object like this into svt_jpegxs_full_object for codes.

See the full details when linking FFmpeg latest with along SVT-AV1 and SVT-JPEG-XS:

/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x0): multiple definition of `svt_create_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x30): multiple definition of `svt_destroy_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x30): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x60): multiple definition of `svt_create_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x70): multiple definition of `svt_post_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x70): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xa0): multiple definition of `svt_block_on_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xa0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xc0): multiple definition of `svt_destroy_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xc0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xe0): multiple definition of `svt_create_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xe0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xf0): multiple definition of `svt_release_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x110): multiple definition of `svt_block_on_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x110): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x130): multiple definition of `svt_destroy_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x130): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x150): multiple definition of `svt_create_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x180): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x1a0): multiple definition of `svt_set_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x1b0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x220): multiple definition of `svt_wait_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x1f0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x20): multiple definition of `svt_muxing_queue_dctor'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x20): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x140): multiple definition of `svt_object_wrapper_dctor'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x140): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x6d0): multiple definition of `svt_object_release_enable'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x6d0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x710): multiple definition of `svt_object_release_disable'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x710): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x750): multiple definition of `svt_object_inc_live_count'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x750): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x7a0): multiple definition of `svt_system_resource_ctor'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x7a0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xaa0): multiple definition of `svt_system_resource_get_producer_fifo'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xaa0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xab0): multiple definition of `svt_system_resource_get_consumer_fifo'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xab0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xac0): multiple definition of `svt_shutdown_process'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xac0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xb40): multiple definition of `svt_post_full_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xb40): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xbb0): multiple definition of `svt_release_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xbb0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xc60): multiple definition of `svt_release_dual_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xc60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xd10): multiple definition of `svt_get_empty_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xd10): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xee0): multiple definition of `svt_get_full_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xdf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xfb0): multiple definition of `svt_get_full_object_non_blocking'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xec0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x0): multiple definition of `svt_create_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x30): multiple definition of `svt_destroy_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x30): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x60): multiple definition of `svt_create_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x70): multiple definition of `svt_post_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x70): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/lda0): : multiple definition of `svt_block_on_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:/opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x0): multiple definition of `(.text+0xa0)svt_create_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x30): multiple definition of `svt_destroy_thread'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x30): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x60): multiple definition of `svt_create_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x70): multiple definition of `svt_post_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x70): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xc0): multiple definition of `svt_destroy_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xc0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x: first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xa0): multiple definition of `svt_block_on_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xa0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):e0): multiple definition of `svt_create_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xSvtThreads.c:(.text+0xc0): multiple definition of `svt_destroy_semaphore'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xc0e0): first defined here
): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0xf0): multiple definition of `svt_release_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj): /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(:svt_threads.c:(.text+0xf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x110): multiple definition of `svt_block_on_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x110): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x130): multiple definition of `.text+0xe0): multiple definition of `svt_create_mutexsvt_destroy_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):'; svt_threads.c:/opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x130): first defined here
(.text+0xe0/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x): first defined here
150): multiple definition of `svt_create_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x180): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x1a0): multiple definition of `svt_set_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:1b0)(.text+0x: first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(f0): multiple definition of `svt_release_mutex.text+0x220): multiple definition of `svt_wait_cond_var'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x1f0): first defined here
'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0xf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x110): multiple definition of `/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ldsvt_block_on_mutex'; : /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj)/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)::SystemResourceManager.c:svt_threads.c:((.text.text+0x+0x20110)): multiple definition of `: first defined heresvt_muxing_queue_dctor
'; /opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj):SvtThreads.c:(.text+0x130): multiple definition of `svt_destroy_mutex'; /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj):svt_threads.c:(.text+0x130): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj): :/opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj)sys_resource_manager.c::(SvtThreads.c:.text(+0x.text20+0x)150: first defined here)
: multiple definition of `svt_create_cond_var'/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld; : /opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj)/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)::svt_threads.c:SystemResourceManager.c:((.text.text+0x+0x180140)): first defined here: multiple definition of `
svt_object_wrapper_dctor'; /opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj): :/opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj)sys_resource_manager.c::(SvtThreads.c:.text(+0x.text140+0x)1a0: first defined here)
: multiple definition of `svt_set_cond_var/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld': ; /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)/opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj)::SystemResourceManager.c:svt_threads.c:((.text.text+0x+0x6d01b0)): multiple definition of `: first defined heresvt_object_release_enable
'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj)/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld:: sys_resource_manager.c:/opt/ffbuild/lib/libSvtJpegxs.a(SvtThreads.c.obj)(:.textSvtThreads.c:+0x(6d0.text)+0x: first defined here220
): multiple definition of `/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ldsvt_wait_cond_var: '/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj); :/opt/ffbuild/lib/libSvtAv1Enc.a(svt_threads.c.obj)SystemResourceManager.c::(svt_threads.c:.text(+0x.text710+0x)1f0: multiple definition of `)svt_object_release_disable: first defined here'
; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x710): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x750): multiple definition of `svt_object_inc_live_count'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x750): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x7a0): multiple definition of `svt_system_resource_ctor'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x7a0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xaa0): multiple definition of `svt_system_resource_get_producer_fifo'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xaa0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xab0): multiple definition of `svt_system_resource_get_consumer_fifo'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)(:SystemResourceManager.c:(.text+0x20).text: multiple definition of `+0xsvt_muxing_queue_dctorab0'); : first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj)+0x:ac0sys_resource_manager.c:)(: multiple definition of `.text+0xsvt_shutdown_process20'): first defined here
; /opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj): :sys_resource_manager.c:/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)(:.textSystemResourceManager.c:+0x(ac0.text): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:+0x140): multiple definition of `svt_object_wrapper_dctor'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x140): first defined here
(.text+0xb40): multiple definition of `svt_post_full_object'/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld; : /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj)::SystemResourceManager.c:sys_resource_manager.c:((.text.text+0x+0x6d0b40)): multiple definition of `: first defined heresvt_object_release_enable'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj)
:sys_resource_manager.c:(/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: .text/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xbb0): multiple definition of `svt_release_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:+0x6d0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld(.text+0xbb0): first defined here: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0x710): multiple definition of `svt_object_release_disable'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xc60): multiple definition of `+0x710): first defined heresvt_release_dual_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ldc60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xd10): multiple definition of `: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xsvt_get_empty_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):750): multiple definition of `svt_object_inc_live_count'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj)sys_resource_manager.c:(.text+0xd10): first defined here
:sys_resource_manager.c:(.text/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xee0+0x750): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld): multiple definition of `svt_get_full_object'; : /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x7a0(.text): multiple definition of `svt_system_resource_ctor'; +0xdf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0x7a0): first defined here
/opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xaa0): multiple definition of `svt_system_resource_get_producer_fifoSystemResourceManager.c:(.text+0x'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.textfb0): multiple definition of `svt_get_full_object_non_blocking+0xaa0): first defined here
'; /opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj)/opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text:SystemResourceManager.c:(.text+0xab0+0xec0): first defined here
): multiple definition of `svt_system_resource_get_consumer_fifo'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xab0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xac0): multiple definition of `svt_shutdown_process'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xac0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xb40): multiple definition of `svt_post_full_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xb40): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xbb0): multiple definition of `svt_release_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xbb0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xc60): multiple definition of `svt_release_dual_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xc60): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xd10): multiple definition of `svt_get_empty_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xd10): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xee0): multiple definition of `svt_get_full_object'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xdf0): first defined here
/opt/ct-ng/lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld: /opt/ffbuild/lib/libSvtJpegxs.a(SystemResourceManager.c.obj):SystemResourceManager.c:(.text+0xfb0): multiple definition of `svt_get_full_object_non_blocking'; /opt/ffbuild/lib/libSvtAv1Enc.a(sys_resource_manager.c.obj):sys_resource_manager.c:(.text+0xec0): first defined here
MartinEesmaa commented 5 months ago

Here's what I fixed multiple definitions renaming from svt into jpegxs_svt:

https://github.com/MartinEesmaa/SVT-JPEG-XS/tree/fix-multiple-definitions

Jamaika1 commented 5 months ago

Hi Martin Theoretically svt-av1 codec changed all function names in version 2.1.1. Unfortunately creator of the thread omitted it. I guessed and changed the names myself. I had to modify the plugin to ffmpeg 7.0.1 but codec still doesn't work. https://www.sendspace.com/file/x7wioc https://www.sendspace.com/file/eh99z5 https://www.sendspace.com/file/c9whtp https://www.sendspace.com/file/8r0g2r

soopel commented 4 months ago

Hi Jamaika,

any chance you could check it with ffmpeg 6.1?

Thanks,

Michal

Jamaika1 commented 4 months ago

I haven't tested 6.1 but I created EncAppMain.exe for any version of ffmpeg. I can't produce photos. Edit: codec works only for AVX2. https://forum.doom9.org/showthread.php?p=2004554#post2004554

Thanks Łukasz

tszumski commented 4 months ago

Please provide detailed configuration you are using:

  1. Operating system(Virtual machine or baremetal),
  2. CPU model
  3. Compiler version
  4. How did you apply/configure AVX2 ? If you set "-mavx2" as additional compilation flag(aka. EXPORT C_FLAGS="-mavx2" ), then you explicitly break compatibility/build SVT-JPEG-XS detect at runtime highest supported SIMD flag and configure based on that. From your logs (1st post) you have only sse2 [asm level on system : up to sse2] While your sommandline sugest you are using AVX optimized code ffmpeg_avx.exe
Jamaika1 commented 4 months ago

I use: Windows 11 Pro 23H2 http://msystem.waw.pl/x265/mingw-gcc1131-20221227.7z 13th Gen Intel(R) Core(TM) i5-13600K 3.50 GHz AVX2: gcc.exe -std=gnu11 -static -march=x86-64-v3 -ftree-vectorize -g0 -O3 -fPIC -mavx2 -mpclmul -maes -mbmi2 -mfma -mf16c -Wcomment -Wformat -DWINVER=0x0602 -D_WIN32_WINNT=0x0602 -DWIN32_LEAN_AND_MEAN=/"/" -DARCH_X86_64=1 -DSRM_REPORT=1 -c xxx.c -o xxx.o AVX: gcc.exe -std=gnu11 -static -march=x86-64-v2 -ftree-vectorize -g0 -O3 -fPIC -mavx -mxsave -mpclmul -maes -Wcomment -Wformat -DWINVER=0x0602 -D_WIN32_WINNT=0x0602 -DWIN32_LEAN_AND_MEAN=/"/" -DARCH_X86_64=1 -DSRM_REPORT=1 -c %%f -o %%~nf.o <-- it should be no SIMD, but the codec will not work anyway.

https://www.sendspace.com/file/ehtanv

tszumski commented 4 months ago

Your flags for 2nd command -march=x86-64-v2 and -mavx let the compiler use 256bit SIMD registers. Code build with those flags will not works on non-AVX CPU you allow compiler use https://www.intel.com/content/www/us/en/docs/intrinsics-guide/index.html?wapkw=intrinsics%20guide#avxnewtechs=AVX

Could you check if codec works if you don't add any optional flags?

If you really want to limit compilation to non-AVX code you should use -msse4.2 instead of -mavx

Jamaika1 commented 4 months ago

Could you check if codec works if you don't add any optional flags? What do you mean? Previously I had an old sandybridge processor. I understand that for -mavx there should not be -march=x86-64-v3. For -msse4.2 it should probably be -march=x86-64-v2.

Jamaika1 commented 4 months ago

Testing... gcc.exe -std=gnu11 -static -march=x86-64-v2 -ftree-vectorize -g0 -O3 -fPIC -msse4.2 -Wcomment -Wformat -DHAVE_CONFIG_H=1 -DLIBXML_STATIC=1 -DHAVE_PTHREAD=1 -DPTW32_STATIC_LIB=1 -c xxx.c -o xxx.o FFmpeg with jpegxs see42 doesn't work. https://www.sendspace.com/file/vub60s

MartinEesmaa commented 1 month ago

Hey, @Jamaika1!

I fixed up one definition of misspelled and wrong direction from DESTROY to CREATE. I think you can now compile with SVT-JPEG-XS and SVT-AV1 on my custom FFmpeg repo or vanilla FFmpeg (needs to patched).

You may see latest commits came already before I commented here: https://github.com/MartinEesmaa/SVT-JPEG-XS/tree/fix-multiple-definitions

Fixed commits: https://github.com/MartinEesmaa/SVT-JPEG-XS/commits/fix-multiple-definitions?author=MartinEesmaa

Feel free to reply or ask questions to me. Thanks! :)