Lecture de flux à partir d’un fichier AVI
La sous-routine suivante obtient des informations de flux à partir d’un fichier AVI et détermine le type de flux à partir de la structure AVISTREAMINFO retournée par la fonction AVIStreamInfo .
// StreamTypes - opens the streams in an AVI file and determines
// stream types.
//
// Global variables
// gcpavi - count of streams in an AVI file
// gapavi[] = array of stream-interface pointers
void StreamTypes(HWND hwnd)
{
AVISTREAMINFO avis;
LONG r, lHeight = 0;
WORD w;
int i;
RECT rc;
// Walk through all streams.
for (i = 0; i < gcpavi; i++) {
AVIStreamInfo(gapavi[i], &avis, sizeof(avis));
if (avis.fccType == streamtypeVIDEO) {
// Place video-processing functions here.
}
else if (avis.fccType == streamtypeAUDIO) {
// Place audio-processing functions here.
}
else if (avis.fccType == streamtypeTEXT) {
// Place text-processing functions here.
}
}
}
Commentaires
https://aka.ms/ContentUserFeedback.
Bientôt disponible : Tout au long de 2024, nous allons supprimer progressivement GitHub Issues comme mécanisme de commentaires pour le contenu et le remplacer par un nouveau système de commentaires. Pour plus d’informations, consultezEnvoyer et afficher des commentaires pour