using MP4Box - GPAC version 1.1.0-DEV-rev1248-g3e4a34873-ab-suite
I use:
```
MP4Box -add "E:\Output\test_2021-09-26@01_22_24_5910_03.264"#video:fps=24000/1001:name="":lang="" -brand avc1 -add "E:\Output\iId_10_aid_0_lang_fr_DELAY_957ms_2021-09-26@01_22_24_5910_02.aac"#audio:delay=957:name="":lang="fr" -mpeg4 -itags tool="Hybrid 2021.09.25.1" -tmp "E:\Output" -new "E:\Output\test.mp4"
```
to mux a file
```
Track Importing MPEG-4 AVC - Width 1920 Height 1080 FPS 24000/1001 SAR 1/1
AVC|H264 Import results: 2112 samples (4250 NALUs) - Slices: 57 I 680 P 1376 B - 2135 SEI - 22 IDR
AVC|H264 Stream uses forward prediction - stream CTS offset: 3 frames
The given code is not a valid one: , using 'und' as 3-letter code
Track Importing AAC  - SampleRate 48000 Num Channels 6
Saving E:\Output\test.mp4: 0.500 secs Interleaving
```
everthing seems fine, but the output is async as if the specified delay was ignored.

First I thought the file was broken, or the delay would be wrong, but muxing the same files with mkvmerge:
```
mkvmerge --ui-language en -o "E:\Output\test.mkv" --global-tags "E:\Output\mkvtags_2021-09-26@01_22_24_5910__04.xml" -d 0 --default-track 0:yes --default-duration "0:24000/1001fps" --fourcc 0:MP4V --no-chapters --compression -1:none --forced-track 0:yes --no-audio --no-subtitles "E:\Output\test_2021-09-26@01_22_24_5910_03.264" --language 0:fr --default-track 0:yes --sync 0:957 --forced-track 0:no -a 0 --compression -1:none --no-video --no-subtitles --no-chapters "E:\Output\iId_10_aid_0_lang_fr_DELAY_957ms_2021-09-26@01_22_24_5910_02.aac"
```
produces a sync file.

Uploaded the files to my [url=https://drive.google.com/drive/folders/1X4xxJ5h8I6Ed00yc8sTIfJmDG-DnSpXL]GoogleDrive[/url].
I also reencode the audio file with different aac encoders, but that didn't change a thing. Muxing with mkvmerge works fine, muxing with MP4Box is async.

Cu Selur
Muxing avc und aac delay problem
This is a GitHub Issue
repo:gpac
owner:gpac
Title : Muxing avc und aac delay problem
Issue date:

--- start body ---
using MP4Box - GPAC version 1.1.0-DEV-rev1248-g3e4a34873-ab-suite
I use:
```
MP4Box -add "E:\Output\test_2021-09-26@01_22_24_5910_03.264"#video:fps=24000/1001:name="":lang="" -brand avc1 -add "E:\Output\iId_10_aid_0_lang_fr_DELAY_957ms_2021-09-26@01_22_24_5910_02.aac"#audio:delay=957:name="":lang="fr" -mpeg4 -itags tool="Hybrid 2021.09.25.1" -tmp "E:\Output" -new "E:\Output\test.mp4"
```
to mux a file
```
Track Importing MPEG-4 AVC - Width 1920 Height 1080 FPS 24000/1001 SAR 1/1
AVC|H264 Import results: 2112 samples (4250 NALUs) - Slices: 57 I 680 P 1376 B - 2135 SEI - 22 IDR
AVC|H264 Stream uses forward prediction - stream CTS offset: 3 frames
The given code is not a valid one: , using 'und' as 3-letter code
Track Importing AAC  - SampleRate 48000 Num Channels 6
Saving E:\Output\test.mp4: 0.500 secs Interleaving
```
everthing seems fine, but the output is async as if the specified delay was ignored.

First I thought the file was broken, or the delay would be wrong, but muxing the same files with mkvmerge:
```
mkvmerge --ui-language en -o "E:\Output\test.mkv" --global-tags "E:\Output\mkvtags_2021-09-26@01_22_24_5910__04.xml" -d 0 --default-track 0:yes --default-duration "0:24000/1001fps" --fourcc 0:MP4V --no-chapters --compression -1:none --forced-track 0:yes --no-audio --no-subtitles "E:\Output\test_2021-09-26@01_22_24_5910_03.264" --language 0:fr --default-track 0:yes --sync 0:957 --forced-track 0:no -a 0 --compression -1:none --no-video --no-subtitles --no-chapters "E:\Output\iId_10_aid_0_lang_fr_DELAY_957ms_2021-09-26@01_22_24_5910_02.aac"
```
produces a sync file.

Uploaded the files to my [url=https://drive.google.com/drive/folders/1X4xxJ5h8I6Ed00yc8sTIfJmDG-DnSpXL]GoogleDrive[/url].
I also reencode the audio file with different aac encoders, but that didn't change a thing. Muxing with mkvmerge works fine, muxing with MP4Box is async.

Cu Selur
--- end body ---
