But I have a specific platform, Sega CD, and everything needs to be done in machine code, even the codec. I can't just use some editing software, it would simply be a VCD, it's a completely different format. I need to compress and decompress the data myself, and the speed of Sega CD drive is 150 kbytes/second, it will need to fit both audio and video. I can use Cinepak, and that would be faster, but the quality would be horrible. I can write my own codec, but that's going to take much more time, although it may be better in quality. More than that, I need at least a primitive engine to handle interactions and disc addressing.
Very interesting topic, but there does seem to be very little documentation about it. I looked for any disassemblies of FMV games but with no luck, still, here are a lot of links providing tools useful for development, source code for different games, and documentation on the Genesis hardware and assembly, there's also Discord links where you may find people far more knowledgeable than me:
A curated list of Sega Mega Drive development resources - GitHub - And-0/awesome-megadrive: A curated list of Sega Mega Drive development resources
This is a program that allows you to view and extract multimedia files from CD games using Sega's own format, it is open source so you could read the source code of the program to understand how the proprietary format worked, and maybe write your own program to convert video clips to CD compatible ones:
Download SGA Conversion and Analysis Tool for free. Convert SGA format multimedia files to PNG and AVI format. This program is a utility for viewing, analyzing, and converting the data in SGA format multimedia files used by Digital Pictures in their games for the Sega Mega CD, Sega Super 32X...
More Genesis development resources, with some related to the CD:
Apparently it is possible to use the Cinepak codec to play video on the CD (Bad Apple example), in this thread you can find the code of some of these games that show video through Cinepak, maybe it's similar to what you want to do yourself and you can use this code as base to start with:
I guess this topic is a bit like a more technical-oriented counterpart to this thread I made a while ago: http://www.sega-16.com/forum/showthread.php?12407-Best-And-worst-Quality-FMV-%28Streaming-video%29-on-the-Sega-CD Anyway, does anyone know specific details on the various FMV...
Aside from disassembling games, I also enjoy assembling them. While I don't have a lick of talent when it comes to the creative side of game creation, I love to work on the code and technical minutiae. In particular, I enjoy the Sega 16-bit era hardware, and while we have a great library for...
A breakdown of the Cinepak video codec used for several Sega CD games.
Unfortunately there is no full guide or complete resource that tells you everything you need to know, and I never programmed for any Sega consoles so I can't help you there but you may be able to find people with experience in homebrew communities. I hope these can be useful.