To capture your demo or intro in a video in case it runs under Windows with DirectX various hardware and software methods exist. Let's start with software methods.
The most recommendable one is using the executable kkpature by Farbrausch, this will allow you to make a frame by frame capture with the highest quality sound and video.
USING ORIGINAL KKAPTURE
The original version of kkapture can be downloaded here. This version has some limitations, it won't work with all intros or demos, and supports a limited amound of video codecs. It also generated segmented .AVI files when the filesize exceeds 1 GB.
For this version we recommend using the "XVID MPEG-4 Codec" and configure it in Maximum Quality.
Once the capture procedure is finished you'll likely have several segmented .AVI files.
These segments will have to be joined together with VirtualDubMod and exported as a single .AVI file.
This .AVI file can then be converted to .MP4 with H264 codec using Handbrake.
In Handbrake configure Dimensions 1920x1080 o 1280x720, format MP4, Avg Bitrate 20000, 2 pass encoding and turbo first pass enabled. Audio is recommended AC3 256kbps or higher. (AAC is not recommended with the default ffmpeg aac encoder)
USING MODIFIED KKAPTURE VERSIONS
Other versions of kkapture exist that allow for different functionality and options, these forks can be downloaded here and here. Try at your own risk.
USING OBS STUDIO (less recommended)
In some situations it will only be possible to capture the demo or intro with screen capture software. For windows we recommend OBS STUDIO. On windows we recommend replacing the default AAC codec by the one that comes with iTunes installation for windows as explained here. (If under MacOS you don't need to do this as these codecs come default with the OS).
In OBS STUDIO we have to create a new scene, where we'll add screen capture source, without cursor capture, and system audio capture. The screen capture size will be configured to the resolution of our demo or intro (1920x1080 or 1280x720 in general) Then select settings > output - encoder software x264, enter a high video bitrate (10000 or higher), encoder preset fast, recording format mp4, audio bitrate 256kbps or higher.
Make sure it's capturing correctly, both the screen and the audio of your PC. Then click on "Start Recording" and run your demo/intro. Then click "stop recording." Your video should be ready in the folder you designed under settings.
HARDWARE METHOD
If all else fails this one should work. In this case you'll need two computers. One of them will receive the video signal via HDMI capture card or device from another computer (maybe more graphically powerful) that will round the demo or intro.
There're different ways to achieve this but it's basically using a video capture device (OBS STUDIO would work too) and different methods you must study depending on your videocard and OS.
It's basically using the capture board in OBS studio as video and audio source, instead of capturing the screen.
CAPTURING RETRO INTROS AND DEMOS VIDEOS
In this case it depends if you want to capture from real hardware or an emulator. Some platforms like Commodore 64 or Amiga have really good emulators. You basically just run the intro/demo in the emulator and capture with OBS Studio or your favorite capture software.
If you want to make a real hardware capture it's better to use another PC with an analog video capture card, preferable use s-video to keep a good video quality.