diff --git a/ffmpeg_x64_800_vvc_patched/libavformat/aacdec.c b/ffmpeg_x64_800_20250822/libavformat/aacdec.c
index 0b4bd69..e26887d 100644
--- a/libavformat/aacdec.c
+++ b/libavformat/aacdec.c
@@ -20,18 +20,13 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/avassert.h"
 #include "libavutil/intreadwrite.h"
 #include "avformat.h"
-#include "avio_internal.h"
-#include "demux.h"
 #include "internal.h"
+#include "rawdec.h"
 #include "id3v1.h"
-#include "id3v2.h"
 #include "apetag.h"
 
-#define ADTS_HEADER_SIZE 7
-
 static int adts_aac_probe(const AVProbeData *p)
 {
     int max_frames = 0, first_frames = 0;
@@ -81,33 +76,9 @@ static int adts_aac_probe(const AVProbeData *p)
         return 0;
 }
 
-static int adts_aac_resync(AVFormatContext *s)
-{
-    uint16_t state;
-    int64_t start_pos = avio_tell(s->pb);
-
-    // skip data until an ADTS frame is found
-    state = avio_r8(s->pb);
-    while (!avio_feof(s->pb) &&
-           (avio_tell(s->pb) - start_pos) < s->probesize) {
-        state = (state << 8) | avio_r8(s->pb);
-        if ((state >> 4) != 0xFFF)
-            continue;
-        avio_seek(s->pb, -2, SEEK_CUR);
-        break;
-    }
-    if (s->pb->eof_reached)
-        return AVERROR_EOF;
-    if ((state >> 4) != 0xFFF)
-        return AVERROR_INVALIDDATA;
-
-    return 0;
-}
-
 static int adts_aac_read_header(AVFormatContext *s)
 {
     AVStream *st;
-    int ret;
 
     st = avformat_new_stream(s, NULL);
     if (!st)
@@ -125,94 +96,22 @@ static int adts_aac_read_header(AVFormatContext *s)
         avio_seek(s->pb, cur, SEEK_SET);
     }
 
-    ret = adts_aac_resync(s);
-    if (ret < 0)
-        return ret;
-
     // LCM of all possible ADTS sample rates
     avpriv_set_pts_info(st, 64, 1, 28224000);
 
     return 0;
 }
 
-static int handle_id3(AVFormatContext *s, AVPacket *pkt)
-{
-    AVDictionary *metadata = NULL;
-    FFIOContext pb;
-    ID3v2ExtraMeta *id3v2_extra_meta;
-    int ret;
-
-    ret = av_append_packet(s->pb, pkt, ff_id3v2_tag_len(pkt->data) - pkt->size);
-    if (ret < 0)
-        return ret;
-
-    ffio_init_read_context(&pb, pkt->data, pkt->size);
-    ff_id3v2_read_dict(&pb.pub, &metadata, ID3v2_DEFAULT_MAGIC, &id3v2_extra_meta);
-    if ((ret = ff_id3v2_parse_priv_dict(&metadata, id3v2_extra_meta)) < 0)
-        goto error;
-
-    if (metadata) {
-        if ((ret = av_dict_copy(&s->metadata, metadata, 0)) < 0)
-            goto error;
-        s->event_flags |= AVFMT_EVENT_FLAG_METADATA_UPDATED;
-    }
-
-error:
-    av_packet_unref(pkt);
-    ff_id3v2_free_extra_meta(&id3v2_extra_meta);
-    av_dict_free(&metadata);
-
-    return ret;
-}
-
-static int adts_aac_read_packet(AVFormatContext *s, AVPacket *pkt)
-{
-    int ret, fsize;
-
-retry:
-    ret = av_get_packet(s->pb, pkt, ADTS_HEADER_SIZE);
-    if (ret < 0)
-        return ret;
-
-    if (ret < ADTS_HEADER_SIZE)
-        return AVERROR(EIO);
-
-    if ((AV_RB16(pkt->data) >> 4) != 0xfff) {
-        // Parse all the ID3 headers between frames
-        int append = ID3v2_HEADER_SIZE - ADTS_HEADER_SIZE;
-
-        av_assert2(append > 0);
-        ret = av_append_packet(s->pb, pkt, append);
-        if (ret != append)
-            return AVERROR(EIO);
-        if (!ff_id3v2_match(pkt->data, ID3v2_DEFAULT_MAGIC)) {
-            av_packet_unref(pkt);
-            ret = adts_aac_resync(s);
-        } else
-            ret = handle_id3(s, pkt);
-        if (ret < 0)
-            return ret;
-
-        goto retry;
-    }
-
-    fsize = (AV_RB32(pkt->data + 3) >> 13) & 0x1FFF;
-    if (fsize < ADTS_HEADER_SIZE)
-        return AVERROR_INVALIDDATA;
-
-    ret = av_append_packet(s->pb, pkt, fsize - pkt->size);
-
-    return ret;
-}
-
 const FFInputFormat ff_aac_demuxer = {
     .p.name       = "aac",
     .p.long_name  = NULL_IF_CONFIG_SMALL("raw ADTS AAC (Advanced Audio Coding)"),
     .p.flags      = AVFMT_GENERIC_INDEX,
     .p.extensions = "aac",
+    .p.priv_class = &ff_raw_demuxer_class,
     .p.mime_type  = "audio/aac,audio/aacp,audio/x-aac",
     .read_probe   = adts_aac_probe,
     .read_header  = adts_aac_read_header,
-    .read_packet  = adts_aac_read_packet,
+    .read_packet  = ff_raw_read_partial_packet,
     .raw_codec_id = AV_CODEC_ID_AAC,
+    .priv_data_size = sizeof(FFRawDemuxerContext),
 };
diff --git a/ffmpeg_x64_800_vvc_patched/libavformat/avidec.c b/ffmpeg_x64_800_20250822/libavformat/avidec.c
index 81a0ae3..2820478 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -1695,6 +1695,7 @@ static int avi_read_idx1(AVFormatContext *s, int size)
                 sti->index_entries[0].flags |= AVINDEX_KEYFRAME;
         }
     }
+    avi->index_loaded = 2;
     return 0;
 }
 
@@ -1824,8 +1825,7 @@ static int avi_load_index(AVFormatContext *s)
         next += size + (size & 1LL);
 
         if (tag == MKTAG('i', 'd', 'x', '1') &&
-            avi_read_idx1(s, size) >= 0) {
-            avi->index_loaded=2;
+            ((s->flags & AVFMT_FLAG_IGNIDX) || (avi_read_idx1(s, size) >= 0))) {
             ret = 0;
         }else if (tag == MKTAG('L', 'I', 'S', 'T')) {
             uint32_t tag1 = avio_rl32(pb);
diff --git a/ffmpeg_x64_800_vvc_patched/libavformat/mov.c b/ffmpeg_x64_800_20250822/libavformat/mov.c
index b29c41a..35d9ea5 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -5184,7 +5184,8 @@ static int mov_read_trak(MOVContext *c, AVIOContext *pb, MOVAtom atom)
         c->advanced_editlist_autodisabled = 1;
     }
 
-    mov_build_index(c, st);
+    if(!(c->fc->flags & AVFMT_FLAG_IGNIDX))
+        mov_build_index(c, st);
 
 #if CONFIG_IAMFDEC
     if (sc->iamf) {
diff --git a/ffmpeg_x64_800_vvc_patched/libavformat/mp3dec.c b/ffmpeg_x64_800_20250822/libavformat/mp3dec.c
index 31eeb68..00fa26c 100644
--- a/libavformat/mp3dec.c
+++ b/libavformat/mp3dec.c
@@ -431,6 +431,9 @@ static int mp3_read_header(AVFormatContext *s)
     }
     if (i == 64 * 1024) {
         off = avio_seek(s->pb, off, SEEK_SET);
+        av_log(s, AV_LOG_ERROR, "Failed to find MPEG audio header.\n");
+        if((mp3->filesize < 32) || (mp3->filesize >= 0x7eeeeeee)) /* MPXPLAY_DISKDRIV_FILESIZE_UNKNOWN */
+            return AVERROR_INVALIDDATA;
     } else {
         av_log(s, i > 0 ? AV_LOG_INFO : AV_LOG_VERBOSE, "Skipping %d bytes of junk at %"PRId64".\n", i, off);
         off = avio_seek(s->pb, off + i, SEEK_SET);
diff --git a/ffmpeg_x64_800_vvc_patched/libavformat/mpegts.c b/ffmpeg_x64_800_20250822/libavformat/mpegts.c
index 981dd8c..7d85c27 100644
--- a/libavformat/mpegts.c
+++ b/libavformat/mpegts.c
@@ -180,7 +180,7 @@ struct MpegTSContext {
     MpegTSFilter *pids[NB_PID_MAX];
     int current_pid;
 
-    AVStream *epg_stream;
+    //AVStream *epg_stream;
     AVBufferPool* pools[32];
 };
 
@@ -386,7 +386,7 @@ static int discard_pid(MpegTSContext *ts, unsigned int pid)
     int used = 0, discarded = 0;
     struct Program *p;
 
-    if (pid == PAT_PID)
+    if ((pid == PAT_PID) || !ts->stream)
         return 0;
 
     /* If none of the programs have .discard=AVDISCARD_ALL then there's
@@ -2641,6 +2641,7 @@ static void pat_cb(MpegTSFilter *filter, const uint8_t *section, int section_len
     }
 }
 
+#if 0
 static void eit_cb(MpegTSFilter *filter, const uint8_t *section, int section_len)
 {
     MpegTSContext *ts = filter->u.section_filter.opaque;
@@ -2694,6 +2695,7 @@ static void eit_cb(MpegTSFilter *filter, const uint8_t *section, int section_len
     ts->pkt->stream_index = ts->epg_stream->index;
     ts->stop_parse = 1;
 }
+#endif // 0
 
 static void sdt_cb(MpegTSFilter *filter, const uint8_t *section, int section_len)
 {
@@ -3159,7 +3161,7 @@ static int mpegts_read_header(AVFormatContext *s)
 
         mpegts_open_section_filter(ts, SDT_PID, sdt_cb, ts, 1);
         mpegts_open_section_filter(ts, PAT_PID, pat_cb, ts, 1);
-        mpegts_open_section_filter(ts, EIT_PID, eit_cb, ts, 1);
+//        mpegts_open_section_filter(ts, EIT_PID, eit_cb, ts, 1);
 
         handle_packets(ts, probesize / ts->raw_packet_size);
         /* if could not find service, enable auto_guess */
@@ -3421,7 +3423,7 @@ MpegTSContext *avpriv_mpegts_parse_open(AVFormatContext *s)
 
     mpegts_open_section_filter(ts, SDT_PID, sdt_cb, ts, 1);
     mpegts_open_section_filter(ts, PAT_PID, pat_cb, ts, 1);
-    mpegts_open_section_filter(ts, EIT_PID, eit_cb, ts, 1);
+    //mpegts_open_section_filter(ts, EIT_PID, eit_cb, ts, 1);
 
     return ts;
 }
diff --git a/ffmpeg_x64_800_vvc_patched/libavutil/random_seed.c b/ffmpeg_x64_800_20250822/libavutil/random_seed.c
index e08ab7b..e680906 100644
--- a/libavutil/random_seed.c
+++ b/libavutil/random_seed.c
@@ -26,7 +26,7 @@
 #if HAVE_IO_H
 #include <io.h>
 #endif
-#if HAVE_BCRYPT
+#if CONFIG_BCRYPT
 #include <windows.h>
 #include <bcrypt.h>
 #endif
@@ -160,7 +160,7 @@ int av_random_bytes(uint8_t* buf, size_t len)
 {
     int err;
 
-#if HAVE_BCRYPT
+#if CONFIG_BCRYPT
     BCRYPT_ALG_HANDLE algo_handle;
     NTSTATUS ret = BCryptOpenAlgorithmProvider(&algo_handle, BCRYPT_RNG_ALGORITHM,
                                                MS_PRIMITIVE_PROVIDER, 0);
