mirror of
https://github.com/mpv-player/mpv
synced 2024-10-30 04:46:41 +01:00
Merge svn changes up to r27573
Conflicts: libmpcodecs/vd_ffmpeg.c
This commit is contained in:
commit
259ea9d703
@ -7391,11 +7391,11 @@ syntax:
|
|||||||
.B \-<codec>opts <option1[=value1]:option2[=value2]:...>
|
.B \-<codec>opts <option1[=value1]:option2[=value2]:...>
|
||||||
.
|
.
|
||||||
.PP
|
.PP
|
||||||
Where <codec> may be: lavc, xvidenc, lame, toolame, twolame,
|
Where <codec> may be: lavc, xvidenc, mp3lame, toolame, twolame,
|
||||||
nuv, xvfw, faac, x264enc, mpeg, lavf.
|
nuv, xvfw, faac, x264enc, mpeg, lavf.
|
||||||
.
|
.
|
||||||
.
|
.
|
||||||
.SS lame (\-lameopts)
|
.SS mp3lame (\-lameopts)
|
||||||
.
|
.
|
||||||
.TP
|
.TP
|
||||||
.B "help\ \ \ "
|
.B "help\ \ \ "
|
||||||
|
@ -3,67 +3,85 @@
|
|||||||
<appendix id="bugs">
|
<appendix id="bugs">
|
||||||
|
|
||||||
<title>Bogues connus</title>
|
<title>Bogues connus</title>
|
||||||
|
|
||||||
<sect1 id="bugs-special">
|
<sect1 id="bugs-special">
|
||||||
<title>Bogues/Problèmes spécifiques à certains systèmes ou à certains CPU</title>
|
<title>Bogues/Problèmes spécifiques à certains systèmes ou à certains CPU</title>
|
||||||
|
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>SIGILL (signal 4) sur P3 en utilisant les noyaux 2.2.x:</para>
|
<para>SIGILL (signal 4) sur P3 en utilisant les noyaux 2.2.x :</para>
|
||||||
<para>Problème: le noyau 2.2.x n'a pas un support natif (fonctionnel) du SSE</para>
|
<para>Problème : le noyau 2.2.x n'a pas un support natif (fonctionnel) du
|
||||||
<para>Solution: mettez à jour le noyau en 2.4.x</para>
|
SSE
|
||||||
<para>Contournement: <command>./configure --disable-sse</command></para>
|
</para>
|
||||||
|
<para>Solution : mettez à jour le noyau en 2.4.x</para>
|
||||||
|
<para>Contournement : <command>./configure --disable-sse</command></para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>SIGILL (signal 4) Général:</para>
|
<para>SIGILL (signal 4) Général :</para>
|
||||||
<para>Problème: vous avez compilé et utilisé <application>MPlayer</application> sur des machines différentes
|
<para>Problème : vous avez compilé et utilisé
|
||||||
|
<application>MPlayer</application> sur des machines différentes
|
||||||
(par exemple compilé sur P3 et tournant sur Celeron)</para>
|
(par exemple compilé sur P3 et tournant sur Celeron)</para>
|
||||||
<para>Solution: compilez <application>MPlayer</application> sur la machine sur laquelle vous l'utiliserez !</para>
|
<para>Solution : compilez <application>MPlayer</application> sur la
|
||||||
<para>Contournement: Vous pouvez oublier tout ceci en passant l'option <option>--enable-runtime-cpudetection</option>
|
machine sur laquelle vous l'utiliserez !</para>
|
||||||
ou en désactivant les instructions spécifiques au CPU (comme <option>--disable-mmx</option>, <option>--disable-3dnow</option>, etc)
|
<para>Contournement : Vous pouvez oublier tout ceci en passant l'option
|
||||||
lors de l'étape de configuration.</para>
|
<option>--enable-runtime-cpudetection</option> ou en désactivant les
|
||||||
|
instructions spécifiques au CPU (comme <option>--disable-mmx</option>,
|
||||||
|
<option>--disable-3dnow</option>, ...) lors de l'étape de
|
||||||
|
configuration.</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</sect1>
|
</sect1>
|
||||||
|
|
||||||
|
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||||
|
|
||||||
|
|
||||||
<sect1 id="bugs-audio">
|
<sect1 id="bugs-audio">
|
||||||
<title>Problèmes de synchro A-V et autres problèmes audio</title>
|
<title>Problèmes de synchro A-V et autres problèmes audio</title>
|
||||||
|
|
||||||
<sect2 id="bugs-delay-all">
|
<sect2 id="bugs-delay-all">
|
||||||
<title>Décalage audio général ou son saccadé (existe avec tous ou de nombreux fichiers)</title>
|
<title>Décalage audio général ou son saccadé
|
||||||
|
(existe avec tous ou de nombreux fichiers)</title>
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem><para>Le plus courant: pilote audio bogué ! - Essayez d'utiliser d'autres pilotes, essayez
|
<listitem><para>Le plus courant : pilote audio bogué ! - Essayez
|
||||||
l'émulation OSS ALSA avec <option>-ao oss</option>, essayez aussi <option>-ao sdl</option>,
|
d'utiliser d'autres pilotes, essayez l'émulation OSS ALSA avec
|
||||||
des fois ça aide. Si votre fichier est lu correctement avec <option>-nosound</option>,
|
<option>-ao oss</option>, essayez aussi <option>-ao sdl</option>, ça aide
|
||||||
alors vous pouvez être certain qu'il s'agit d'un problème de carte son (pilote).
|
parfois. Si votre fichier est lu correctement avec
|
||||||
|
<option>-nosound</option>, alors vous pouvez être certain qu'il s'agit
|
||||||
|
d'un problème de carte son (pilote).
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>Problèmes de buffer audio (taille de buffer mal détectée)</para>
|
<para>Problèmes de buffer audio (taille de buffer mal détectée)</para>
|
||||||
<para>Contournement: option <option>-abs</option> de <application>MPlayer</application></para>
|
<para>Contournement : option <option>-abs</option> de
|
||||||
|
<application>MPlayer</application>
|
||||||
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
<listitem><para>
|
<listitem><para>
|
||||||
Problèmes de taux d'échantillonnage - peut-être que votre carte ne supporte pas le taux
|
Problèmes de fréquence d'échantillonnage - peut-être que votre carte ne
|
||||||
d'échantillonnage utilisé dans vos fichiers - essayez le filtre de réechantillonnage (<option>-af resample=...</option>)
|
supporte pas la fréquence d'échantillonnage utilisée dans vos fichiers -
|
||||||
|
essayez le filtre de réechantillonnage (<option>-af resample=...</option>)
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>Machine lente (CPU ou VGA)</para>
|
<para>Machine lente (CPU ou VGA)</para>
|
||||||
<para>Essayez avec <option>-vo null</option>, si la lecture fonctionne bien, alors vous
|
<para>Essayez avec <option>-vo null</option>, si la lecture fonctionne
|
||||||
avez un(e) carte/pilote VGA lent(e).</para>
|
bien, alors vous avez un(e) carte/pilote VGA lent(e).</para>
|
||||||
<para>Contournement: achetez une carte plus rapide ou lisez cette documentation pour
|
<para>Contournement : achetez une carte plus rapide ou lisez cette
|
||||||
augmenter la vitesse.</para>
|
documentation pour augmenter la vitesse.</para>
|
||||||
<para>Essayez aussi <option>-framedrop</option></para>
|
<para>Essayez aussi <option>-framedrop</option></para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="bugs-delay-specific">
|
<sect2 id="bugs-delay-specific">
|
||||||
<title>Décalage audio/désynchro spécifique à un ou quelques fichiers</title>
|
<title>Décalage audio/désynchro spécifique à un ou quelques fichiers</title>
|
||||||
|
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>Mauvais fichier</para>
|
<para>Mauvais fichier</para>
|
||||||
<para>
|
<para>
|
||||||
Contournement:
|
Contournement :
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>options <option>-ni</option> ou <option>-nobps</option> (pour les fichiers
|
<para>options <option>-ni</option> ou <option>-nobps</option> (pour les fichiers
|
||||||
@ -71,7 +89,10 @@ Contournement:
|
|||||||
<para>et/ou</para>
|
<para>et/ou</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para><option>-mc 0</option>(requis pour les fichiers avec de l'audio VBR mal entrelacé)</para>
|
<para>
|
||||||
|
<option>-mc 0</option> (requis pour les fichiers avec de l'audio VBR
|
||||||
|
mal entrelacé)
|
||||||
|
</para>
|
||||||
<para>et/ou</para>
|
<para>et/ou</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
@ -85,7 +106,8 @@ Si rien de tout ça n'aide, uploadez le fichier SVP, nous le contrôlerons (et r
|
|||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>Votre carte son ne supporte pas la lecture à 48kHz</para>
|
<para>Votre carte son ne supporte pas la lecture à 48kHz</para>
|
||||||
<para>Contournement: achetez une meilleur carte son... ou essayez de décrémenter le
|
<para>Contournement : achetez une meilleur carte son... ou essayez de
|
||||||
|
décrémenter le
|
||||||
nombre de trames par seconde (fps) de 10% (utilisez <option>-fps 27</option> pour un film à 30fps) ou utilisez le
|
nombre de trames par seconde (fps) de 10% (utilisez <option>-fps 27</option> pour un film à 30fps) ou utilisez le
|
||||||
filtre de réechantillonnage (resample)</para>
|
filtre de réechantillonnage (resample)</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
@ -93,43 +115,51 @@ filtre de réechantillonnage (resample)</para>
|
|||||||
<listitem>
|
<listitem>
|
||||||
<para>Machine lente (si A-V n'est pas proche de 0, et que le dernier nombre de la ligne
|
<para>Machine lente (si A-V n'est pas proche de 0, et que le dernier nombre de la ligne
|
||||||
d'état augmente)</para>
|
d'état augmente)</para>
|
||||||
<para>Contournement: <option>-framedrop</option></para>
|
<para>Contournement : <option>-framedrop</option></para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="bugs-nosound">
|
<sect2 id="bugs-nosound">
|
||||||
<title>Pas de son du tout</title>
|
<title>Aucun son</title>
|
||||||
|
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>Votre fichier utilise un codec audio non-supporté</para>
|
<para>Votre fichier utilise un codec audio non-supporté</para>
|
||||||
<para>Solution: lisez la documentation et aidez-nous à en ajouter
|
<para>Solution : lisez la documentation et aidez-nous à en ajouter
|
||||||
le support</para>
|
le support</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="bugs-nopicture">
|
<sect2 id="bugs-nopicture">
|
||||||
<title>Pas d'image du tout (juste une fenêtre complètement grise/verte)</title>
|
<title>Aucune image (juste une fenêtre complètement grise/verte)</title>
|
||||||
|
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>votre fichier utilise un codec vidéo non-supporté</para>
|
<para>Votre fichier utilise un codec vidéo non-supporté</para>
|
||||||
<para>Solution: lisez la documentation et aidez-nous à en ajouter le support</para>
|
<para>Solution : lisez la documentation et aidez-nous à en ajouter le
|
||||||
|
support</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
le codec auto-sélectionné ne peut décoder le fichier, essayez avec un autre en
|
Le codec auto-sélectionné ne peut décoder le fichier, essayez avec un autre en
|
||||||
utilisant les options <option>-vc</option> ou <option>-vfm</option>
|
utilisant les options <option>-vc</option> ou <option>-vfm</option>
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="bugs-video">
|
<sect2 id="bugs-video">
|
||||||
<title>Problèmes de sortie vidéo</title>
|
<title>Problèmes de sortie vidéo</title>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Premièrement notez que les options <option>-fs -vm</option> et
|
Premièrement notez que les options <option>-fs -vm</option> et
|
||||||
<option>-zoom</option> ne sont pas non supportées par tous les pilotes.
|
<option>-zoom</option> ne sont pas non supportées par tous les pilotes.
|
||||||
@ -141,8 +171,10 @@ matériel.
|
|||||||
<title>OSD/sub papillotant</title>
|
<title>OSD/sub papillotant</title>
|
||||||
<para>
|
<para>
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem><para>pilote x11: désolé, cela ne peut être réparé maintenant</para></listitem>
|
<listitem><para>Pilote x11 : désolé, cela ne peut être réparé
|
||||||
<listitem><para>pilote xv: utilisez l'option <option>-double</option></para></listitem>
|
maintenant</para></listitem>
|
||||||
|
<listitem><para>Pilote xv : utilisez l'option
|
||||||
|
<option>-double</option></para></listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</para>
|
</para>
|
||||||
</formalpara>
|
</formalpara>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!-- synced with r20637 -->
|
<!-- synced with r26990 -->
|
||||||
<chapter id="cd-dvd">
|
<chapter id="cd-dvd">
|
||||||
<title>Utilisation des CD/DVD</title>
|
<title>Utilisation des CD/DVD</title>
|
||||||
|
|
||||||
@ -25,12 +25,15 @@ peut contribuer à diminuer.
|
|||||||
</para></listitem>
|
</para></listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="drives_linux">
|
<sect2 id="drives_linux">
|
||||||
<title>Linux</title>
|
<title>Linux</title>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Vous pouvez réduire la vitesse des lecteurs de CD-ROM IDE avec <command>hdparm</command>,
|
Vous pouvez réduire la vitesse des lecteurs de CD-ROM IDE avec <command>hdparm</command>,
|
||||||
<command>setcd</command> ou <command>cdctl</command>. Ils fonctionnent comme suit :
|
<command>setcd</command> ou <command>cdctl</command>. Ils fonctionnent comme
|
||||||
|
suit :
|
||||||
<screen>hdparm -E <replaceable>[vitesse]</replaceable> <replaceable>[périph. cdrom]</replaceable></screen>
|
<screen>hdparm -E <replaceable>[vitesse]</replaceable> <replaceable>[périph. cdrom]</replaceable></screen>
|
||||||
<screen>setcd -x <replaceable>[vitesse]</replaceable> <replaceable>[périph. cdrom]</replaceable></screen>
|
<screen>setcd -x <replaceable>[vitesse]</replaceable> <replaceable>[périph. cdrom]</replaceable></screen>
|
||||||
<screen>cdctl -bS <replaceable>[vitesse]</replaceable></screen>
|
<screen>cdctl -bS <replaceable>[vitesse]</replaceable></screen>
|
||||||
@ -42,7 +45,8 @@ vrai périphérique IDE, et non au périphérique SCSI émulé.
|
|||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Si vous avez les privilèges root, la commande suivante peut également aider :
|
Si vous avez les privilèges root, la commande suivante peut également
|
||||||
|
aider :
|
||||||
<screen>echo file_readahead:2000000 > /proc/ide/<replaceable>[périph. cdrom]</replaceable>/settings</screen>
|
<screen>echo file_readahead:2000000 > /proc/ide/<replaceable>[périph. cdrom]</replaceable>/settings</screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@ -50,7 +54,8 @@ Si vous avez les privilèges root, la commande suivante peut également aider :
|
|||||||
Ceci créé un cache de 2 Mo, ce qui est utile pour les CD-ROMs endommagés (rayés).
|
Ceci créé un cache de 2 Mo, ce qui est utile pour les CD-ROMs endommagés (rayés).
|
||||||
Si vous lui donnez une valeur trop haute, le lecteur ne va pas cesser de s'arrêter
|
Si vous lui donnez une valeur trop haute, le lecteur ne va pas cesser de s'arrêter
|
||||||
et de repartir, ce qui va dramatiquement diminuer les performances. Il est
|
et de repartir, ce qui va dramatiquement diminuer les performances. Il est
|
||||||
également recommandé d'optimiser votre lecteur de CD-ROM avec <command>hdparm</command> :
|
également recommandé d'optimiser votre lecteur de CD-ROM avec
|
||||||
|
<command>hdparm</command> :
|
||||||
<screen>hdparm -d1 -a8 -u1 <replaceable>[périph. cdrom]</replaceable></screen>
|
<screen>hdparm -d1 -a8 -u1 <replaceable>[périph. cdrom]</replaceable></screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@ -61,27 +66,29 @@ man de <command>hdparm</command> pour plus d'explications).
|
|||||||
|
|
||||||
<para>
|
<para>
|
||||||
Référez vous à "<filename>/proc/ide/<replaceable>[périph. cdrom]</replaceable>/settings</filename>"
|
Référez vous à "<filename>/proc/ide/<replaceable>[périph. cdrom]</replaceable>/settings</filename>"
|
||||||
pour optimiser précisémment votre lecteur CD-ROM.
|
pour optimiser précisément votre lecteur CD-ROM.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Les lecteurs SCSI n'ont pas une manière uniforme de règler ces paramètres (Vous en
|
Les lecteurs SCSI n'ont pas une manière uniforme de régler ces paramètres
|
||||||
connaissez une ? Dites-la nous !). Il y a un outil qui fonctionne pour les
|
(Vous en connaissez une ? Dites-la nous !). Il y a un outil qui
|
||||||
|
fonctionne pour les
|
||||||
<ulink url="http://das.ist.org/~georg/">Lecteurs SCSI Plextor</ulink>.
|
<ulink url="http://das.ist.org/~georg/">Lecteurs SCSI Plextor</ulink>.
|
||||||
</para>
|
</para>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
|
<!-- ********** -->
|
||||||
|
|
||||||
<sect2 id="drives_freebsd">
|
<sect2 id="drives_freebsd">
|
||||||
<title>FreeBSD</title>
|
<title>FreeBSD</title>
|
||||||
|
|
||||||
<para>Vitesse :
|
<para>Vitesse :
|
||||||
<screen>
|
<screen>
|
||||||
cdcontrol [-f <replaceable>périphérique</replaceable>] speed <replaceable>[vitesse]</replaceable>
|
cdcontrol [-f <replaceable>périphérique</replaceable>] speed <replaceable>[vitesse]</replaceable>
|
||||||
</screen>
|
</screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>DMA :
|
<para>DMA :
|
||||||
<screen>
|
<screen>
|
||||||
sysctl hw.ata.atapi_dma=1
|
sysctl hw.ata.atapi_dma=1
|
||||||
</screen>
|
</screen>
|
||||||
@ -92,16 +99,20 @@ sysctl hw.ata.atapi_dma=1
|
|||||||
</sect1>
|
</sect1>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||||
|
|
||||||
|
|
||||||
<sect1 id="dvd">
|
<sect1 id="dvd">
|
||||||
<title>Lecture de DVD</title>
|
<title>Lecture de DVD</title>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Pour voir la liste complète des options disponibles, veuillez lire la page de man.
|
Pour voir la liste complète des options disponibles, veuillez lire la page de man.
|
||||||
La syntaxe pour lire un Digital Versatile Disc (DVD) est la suivante :
|
La syntaxe pour lire un Digital Versatile Disc (DVD) est la suivante :
|
||||||
<screen>mplayer dvd://<replaceable><piste></replaceable> [-dvd-device <replaceable><périphérique></replaceable>]</screen>
|
<screen>mplayer dvd://<replaceable><piste></replaceable> [-dvd-device <replaceable><périphérique></replaceable>]</screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Exemple :
|
Exemple :
|
||||||
<screen>mplayer dvd://1 -dvd-device /dev/hdc</screen>
|
<screen>mplayer dvd://1 -dvd-device /dev/hdc</screen>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@ -133,82 +144,63 @@ tous les outils de ce genre. Certains lecteurs RPC-2 peuvent aussi nécessiter
|
|||||||
le réglage de leur code de région.
|
le réglage de leur code de région.
|
||||||
</para></note>
|
</para></note>
|
||||||
|
|
||||||
<formalpara>
|
|
||||||
<title>Structure d'un DVD</title>
|
|
||||||
<para>
|
|
||||||
Les disques DVD utilisent tous des secteurs de 2048 octets par secteur avec ECC/CRC. Ils ont
|
|
||||||
généralement un système de fichier UDF sur une seule piste, qui contient divers fichiers (des
|
|
||||||
petits fichiers .IFO et .BUK et de gros (1Go) fichiers .VOB). Ce sont de véritables fichiers et ils
|
|
||||||
peuvent être joués/copiés depuis le système de fichier monté d'un DVD non-crypté.
|
|
||||||
</para>
|
|
||||||
</formalpara>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
Les fichiers .IFO contiennent les infos de navigation dans le film (carte des chapitres/titres/angles,
|
|
||||||
table des langues, etc) et sont requis pour lire et interpréter le contenu des .VOB (le film). Les
|
|
||||||
fichiers .BUK sont des backups de ces fichiers. Ils utilisent des <emphasis role="bold">secteurs</emphasis>
|
|
||||||
partout, donc vous avez besoin d'utiliser un adressage brut des secteurs sur le disque pour implémenter
|
|
||||||
la navigation DVD. C'est également requis pour décrypter le contenu.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
Le support DVD nécessite un accès brut aux secteurs du périphérique. Malheureusement,
|
|
||||||
vous devez (sous Linux) être root pour avoir accès aux adresses des secteurs d'un fichier. C'est
|
|
||||||
pourquoi nous n'utilisons pas du tout le pilote de système de fichier du noyau, à
|
|
||||||
la place nous l'avons réimplémenté dans l'espace utilisateur. <systemitem>libdvdread</systemitem>
|
|
||||||
0.9.x fait cela. Le pilote pour le système
|
|
||||||
de fichier UDF du noyau n'est pas requis puisqu'ils ont déjà leur pilote UDF incorporé.
|
|
||||||
De plus le DVD n'a pas besoin d'être monté étant donné que seul l'accès brut aux secteurs est utilisé.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
Parfois <filename>/dev/dvd</filename> ne peut être lu par les utilisateurs; les auteurs de
|
|
||||||
<systemitem>libdvdread</systemitem> ont donc implémenté une couche d'émulation qui transforme les
|
|
||||||
adresses des secteurs en noms de fichier+offsets, pour émuler l'accès brut par-dessus un système de fichier
|
|
||||||
monté ou même un disque dur.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
<systemitem>libdvdread</systemitem> accepte même le point de montage au lieu du nom de périphérique
|
|
||||||
pour l'accès brut et regarde dans <filename>/proc/mounts</filename> pour obtenir le nom de périphérique.
|
|
||||||
Il a été développé pour Solaris, où les noms de périphériques sont alloués dynamiquement.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
<formalpara>
|
<formalpara>
|
||||||
<title>Décodage DVD</title>
|
<title>Décodage DVD</title>
|
||||||
<para>
|
<para>
|
||||||
Le décodage DVD est réalisé par <systemitem>libdvdcss</systemitem>. La méthode peut être
|
Le décodage DVD est réalisé par <systemitem>libdvdcss</systemitem>. La
|
||||||
spécifiée par la variable d'environnement <envar>DVDCSS_METHOD</envar>. Voir le manuel
|
méthode peut être spécifiée par la variable d'environnement
|
||||||
pour plus de détails.
|
<envar>DVDCSS_METHOD</envar>. Voir le manuel pour plus de détails.
|
||||||
</para>
|
</para>
|
||||||
</formalpara>
|
</formalpara>
|
||||||
|
|
||||||
|
<sect2 id="region_code">
|
||||||
|
<title>Code zone</title>
|
||||||
<para>
|
<para>
|
||||||
Les lecteurs DVD RPC-1 ne protègent les réglages de protection de région
|
Les lecteurs DVD d'aujourd'hui sont équipés d'une restriction sans queue ni
|
||||||
que de façon logicielle.
|
tête appelée <ulink
|
||||||
Les lecteurs RPC-2 ont une protection matérielle qui ne permet que 5 changements.
|
url="http://fr.wikipedia.org/wiki/DVD#Protections_commerciales_par_zones">
|
||||||
Il peut être requis/recommandé de mettre à niveau le firmware en RPC-1
|
protection commerciale par zones </ulink>.
|
||||||
si vous avez un lecteur DVD RPC-2.
|
C'est un système qui oblige les lecteurs DVD à accepter uniquement les DVDs
|
||||||
Vous pouvez essayer de trouver des mises à jour de firmware pour votre lecteur
|
produits pour l'une des six zones qui découpent le monde. Il est
|
||||||
sur internet. <ulink url="http://forum.rpc-1.com/dl_all.php">Ce forum sur les firmware</ulink>
|
impensable qu'un groupe de personne se réunisse pour arriver à élaborer une
|
||||||
est sans doute un bon point de départ pour vos recherches.
|
telle idée et pense que la Terre entière se pliera à leur volonté.
|
||||||
Si il n'y a pas de mise à niveau de firmware disponible pour votre périphérique,
|
|
||||||
utilisez l'<ulink url="http://linvdr.org/projects/regionset/">outil
|
|
||||||
de réglage de région</ulink> pour changer le code de région de votre lecteur DVD (sous Linux).
|
|
||||||
<emphasis role="bold">Attention</emphasis> :
|
|
||||||
Vous ne pouvez changer la région que 5 fois.
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
|
<para>
|
||||||
|
Les lecteurs qui appliquent le réglage des zones uniquement via logiciel
|
||||||
|
sont connus comme des lecteurs RPC-1, ceux qui le font via matériel comme
|
||||||
|
des lecteurs RPC-2.
|
||||||
|
Les lecteurs RPC-2 permettent de changer de zone cinq fois avant qu'il ne
|
||||||
|
se bloque.
|
||||||
|
Sous Linux, vous pouvez utiliser l'outil <ulink
|
||||||
|
url="http://linvdr.org/projects/regionset/">regionset</ulink> pour modifier
|
||||||
|
le code zone de votre lecteur DVD.
|
||||||
|
</para>
|
||||||
|
|
||||||
|
<para>
|
||||||
|
Heureusement, il est possible de convertir les lecteurs RPC-2 en RPC-1 lors
|
||||||
|
d'une mise à jours du micrologiciel.
|
||||||
|
Saisissez la référence de votre lecteur DVD dans votre moteur de recherche
|
||||||
|
favori ou jetez un œil au forum et à la section téléchargement de <ulink
|
||||||
|
url="http://www.rpc1.org/">"The firmware page"</ulink>.
|
||||||
|
Les mises en garde habituelles des mises à jours de micrologiciels restent
|
||||||
|
valables mais les expériences de suppressions de restrictions de zones sont
|
||||||
|
généralement fructueuses.
|
||||||
|
</para>
|
||||||
|
</sect2>
|
||||||
|
|
||||||
</sect1>
|
</sect1>
|
||||||
|
|
||||||
|
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
|
||||||
|
|
||||||
|
|
||||||
<sect1 id="vcd">
|
<sect1 id="vcd">
|
||||||
<title>Lecture de VCDs</title>
|
<title>Lecture de VCDs</title>
|
||||||
<para>
|
<para>
|
||||||
Pour voir la liste complète des options disponibles, veuillez lire la page de man.
|
Pour voir la liste complète des options disponibles, veuillez lire la page de man.
|
||||||
La syntaxe pour lire un Video CD standard (VCD) est la suivante :
|
La syntaxe pour lire un Vidéo CD standard (VCD) est la suivante :
|
||||||
<screen>mplayer vcd://<replaceable><piste></replaceable> [-cdrom-device <replaceable><périphérique></replaceable>]</screen>
|
<screen>mplayer vcd://<replaceable><piste></replaceable> [-cdrom-device <replaceable><périphérique></replaceable>]</screen>
|
||||||
Exemple :
|
Exemple :
|
||||||
<screen>mplayer vcd://2 -cdrom-device /dev/hdc</screen>
|
<screen>mplayer vcd://2 -cdrom-device /dev/hdc</screen>
|
||||||
Le périphérique VCD par défaut est <filename>/dev/cdrom</filename>. Si votre installation diffère,
|
Le périphérique VCD par défaut est <filename>/dev/cdrom</filename>. Si votre installation diffère,
|
||||||
faites un lien symbolique (symlink) ou spécifiez le bon périphérique en ligne de commande avec l'option
|
faites un lien symbolique (symlink) ou spécifiez le bon périphérique en ligne de commande avec l'option
|
||||||
@ -235,10 +227,8 @@ et lire le fichier obtenu avec <application>MPlayer</application>.
|
|||||||
<title>Structure d'un VCD</title>
|
<title>Structure d'un VCD</title>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Un CD Video (VCD) est constitué de secteurs CD-ROM XA, c'est-à-dire des pistes CD-ROM mode 2
|
Un CD Video (VCD) est constitué de secteurs CD-ROM XA, c'est-à-dire des
|
||||||
forme 1 et 2 :</para>
|
pistes CD-ROM mode 2 forme 1 et 2 :
|
||||||
</formalpara>
|
|
||||||
|
|
||||||
<itemizedlist>
|
<itemizedlist>
|
||||||
<listitem><para>
|
<listitem><para>
|
||||||
La première piste est en mode 2 forme 2 ce qui signifie qu'elle utilise une
|
La première piste est en mode 2 forme 2 ce qui signifie qu'elle utilise une
|
||||||
@ -277,9 +267,11 @@ CD peut être trouvée dans la
|
|||||||
</para></listitem>
|
</para></listitem>
|
||||||
|
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
|
</para>
|
||||||
|
</formalpara>
|
||||||
|
|
||||||
<formalpara>
|
<formalpara>
|
||||||
<title>À propos des fichiers .DAT :</title>
|
<title>À propos des fichiers .DAT :</title>
|
||||||
<para>
|
<para>
|
||||||
Le fichier de ~600 Mo visible sur la première piste d'un VCD monté n'est
|
Le fichier de ~600 Mo visible sur la première piste d'un VCD monté n'est
|
||||||
pas un vrai fichier !
|
pas un vrai fichier !
|
||||||
@ -297,8 +289,8 @@ Il possède un pilote de système de fichier iso9660 modifié
|
|||||||
les pistes brutes au travers de ce fichier .DAT fantôme.
|
les pistes brutes au travers de ce fichier .DAT fantôme.
|
||||||
Si vous montez le disque en utilisant leur pilote, vous pouvez
|
Si vous montez le disque en utilisant leur pilote, vous pouvez
|
||||||
copier et même lire les fichiers .DAT avec <application>MPlayer</application>.
|
copier et même lire les fichiers .DAT avec <application>MPlayer</application>.
|
||||||
Mais cela ne <emphasis role="bold">fonctionnera pas</emphasis>
|
Mais cela ne fonctionnera pas avec le pilote iso9660 standard du
|
||||||
avec le pilote iso9660 standard du noyau !
|
noyau !
|
||||||
Il est recommandé d'utiliser l'option <option>vcd://</option>
|
Il est recommandé d'utiliser l'option <option>vcd://</option>
|
||||||
à la place.
|
à la place.
|
||||||
D'autres possibilités pour la copie de VCD sont le nouveau pilote noyau
|
D'autres possibilités pour la copie de VCD sont le nouveau pilote noyau
|
||||||
|
File diff suppressed because it is too large
Load Diff
16
TOOLS/README
16
TOOLS/README
@ -173,22 +173,6 @@ Note: You will need vcdimager/cdrecord to master/burn the resulting
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
encode2mpeglight.sh
|
|
||||||
|
|
||||||
Author: Giacomo Comes
|
|
||||||
|
|
||||||
Description: Convert anything MPlayer can play to VCD/SVCD/DVD MPEG.
|
|
||||||
|
|
||||||
Usage: encode2mpeglight.sh -o <NAME> -n <NORM> [options] <source>
|
|
||||||
For help and documentation run:
|
|
||||||
encode2mpeglight.sh -h
|
|
||||||
encode2mpeglight.sh -l
|
|
||||||
encode2mpeglight.sh -doc
|
|
||||||
|
|
||||||
Note: This script uses only MEncode/MPlayer. Check the final log
|
|
||||||
file for informations/warnings about the encoding process.
|
|
||||||
|
|
||||||
|
|
||||||
Tech scripts in the TOOLS dir
|
Tech scripts in the TOOLS dir
|
||||||
-----------------------------
|
-----------------------------
|
||||||
|
|
||||||
|
@ -14,9 +14,9 @@
|
|||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
* GNU General Public License for more details.
|
* GNU General Public License for more details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License along
|
||||||
* along with this program; if not, write to the Free Software
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -1,10 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
* ao_arts - aRts audio output driver for MPlayer
|
* aRts audio output driver for MPlayer
|
||||||
*
|
*
|
||||||
* Michele Balistreri <brain87@gmx.net>
|
* copyright (c) 2002 Michele Balistreri <brain87@gmx.net>
|
||||||
*
|
*
|
||||||
* This driver is distribuited under terms of GPL
|
* This file is part of MPlayer.
|
||||||
*
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <artsc.h>
|
#include <artsc.h>
|
||||||
|
@ -1,10 +1,26 @@
|
|||||||
/*
|
/*
|
||||||
* ao_esd - EsounD audio output driver for MPlayer
|
* EsounD audio output driver for MPlayer
|
||||||
*
|
*
|
||||||
* Juergen Keil <jk@tools.de>
|
* copyright (c) 2002 Juergen Keil <jk@tools.de>
|
||||||
*
|
*
|
||||||
* This driver is distributed under the terms of the GPL
|
* This file is part of MPlayer.
|
||||||
*
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
* TODO / known problems:
|
* TODO / known problems:
|
||||||
* - does not work well when the esd daemon has autostandby disabled
|
* - does not work well when the esd daemon has autostandby disabled
|
||||||
* (workaround: run esd with option "-as 2" - fortunatelly this is
|
* (workaround: run esd with option "-as 2" - fortunatelly this is
|
||||||
|
@ -1,11 +1,24 @@
|
|||||||
/*
|
/*
|
||||||
* ao_jack.c - libao2 JACK Audio Output Driver for MPlayer
|
* JACK audio output driver for MPlayer
|
||||||
*
|
|
||||||
* This driver is under the same license as MPlayer.
|
|
||||||
* (http://www.mplayerhq.hu)
|
|
||||||
*
|
*
|
||||||
* Copyleft 2001 by Felix Bünemann (atmosfear@users.sf.net)
|
* Copyleft 2001 by Felix Bünemann (atmosfear@users.sf.net)
|
||||||
* and Reimar Döffinger (Reimar.Doeffinger@stud.uni-karlsruhe.de)
|
* and Reimar Döffinger (Reimar.Doeffinger@stud.uni-karlsruhe.de)
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* along with MPlayer; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,10 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
* ao_openal.c - OpenAL audio output driver for MPlayer
|
* OpenAL audio output driver for MPlayer
|
||||||
*
|
|
||||||
* This driver is under the same license as MPlayer.
|
|
||||||
* (http://www.mplayerhq.hu)
|
|
||||||
*
|
*
|
||||||
* Copyleft 2006 by Reimar Döffinger (Reimar.Doeffinger@stud.uni-karlsruhe.de)
|
* Copyleft 2006 by Reimar Döffinger (Reimar.Doeffinger@stud.uni-karlsruhe.de)
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* along with MPlayer; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
@ -1,13 +1,25 @@
|
|||||||
/*
|
/*
|
||||||
* ao_sdl.c - libao2 SDLlib Audio Output Driver for MPlayer
|
* SDLlib audio output driver for MPlayer
|
||||||
*
|
|
||||||
* This driver is under the same license as MPlayer.
|
|
||||||
* (http://www.mplayerhq.hu)
|
|
||||||
*
|
*
|
||||||
* Copyleft 2001 by Felix Bünemann (atmosfear@users.sf.net)
|
* Copyleft 2001 by Felix Bünemann (atmosfear@users.sf.net)
|
||||||
*
|
*
|
||||||
* Thanks to Arpi for nice ringbuffer-code!
|
* Thanks to Arpi for nice ringbuffer-code!
|
||||||
*
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* along with MPlayer; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
28
libass/ass.c
28
libass/ass.c
@ -716,6 +716,24 @@ static int process_text(ass_track_t* track, char* str)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \brief Process a chunk of subtitle stream data.
|
||||||
|
* \param track track
|
||||||
|
* \param data string to parse
|
||||||
|
* \param size length of data
|
||||||
|
*/
|
||||||
|
void ass_process_data(ass_track_t* track, char* data, int size)
|
||||||
|
{
|
||||||
|
char* str = malloc(size + 1);
|
||||||
|
|
||||||
|
memcpy(str, data, size);
|
||||||
|
str[size] = '\0';
|
||||||
|
|
||||||
|
mp_msg(MSGT_ASS, MSGL_V, "event: %s\n", str);
|
||||||
|
process_text(track, str);
|
||||||
|
free(str);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Process CodecPrivate section of subtitle stream
|
* \brief Process CodecPrivate section of subtitle stream
|
||||||
* \param track track
|
* \param track track
|
||||||
@ -725,13 +743,7 @@ static int process_text(ass_track_t* track, char* str)
|
|||||||
*/
|
*/
|
||||||
void ass_process_codec_private(ass_track_t* track, char *data, int size)
|
void ass_process_codec_private(ass_track_t* track, char *data, int size)
|
||||||
{
|
{
|
||||||
char* str = malloc(size + 1);
|
ass_process_data(track, data, size);
|
||||||
|
|
||||||
memcpy(str, data, size);
|
|
||||||
str[size] = '\0';
|
|
||||||
|
|
||||||
process_text(track, str);
|
|
||||||
free(str);
|
|
||||||
|
|
||||||
if (!track->event_format) {
|
if (!track->event_format) {
|
||||||
// probably an mkv produced by ancient mkvtoolnix
|
// probably an mkv produced by ancient mkvtoolnix
|
||||||
@ -1009,7 +1021,7 @@ ass_track_t* ass_read_memory(ass_library_t* library, char* buf, size_t bufsize,
|
|||||||
return track;
|
return track;
|
||||||
}
|
}
|
||||||
|
|
||||||
char* read_file_recode(char* fname, char* codepage, int* size)
|
char* read_file_recode(char* fname, char* codepage, size_t* size)
|
||||||
{
|
{
|
||||||
char* buf;
|
char* buf;
|
||||||
size_t bufsize;
|
size_t bufsize;
|
||||||
|
10
libass/ass.h
10
libass/ass.h
@ -153,6 +153,14 @@ void ass_free_style(ass_track_t* track, int sid);
|
|||||||
*/
|
*/
|
||||||
void ass_free_event(ass_track_t* track, int eid);
|
void ass_free_event(ass_track_t* track, int eid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \brief Parse a chunk of subtitle stream data.
|
||||||
|
* \param track track
|
||||||
|
* \param data string to parse
|
||||||
|
* \param size length of data
|
||||||
|
*/
|
||||||
|
void ass_process_data(ass_track_t* track, char* data, int size);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Parse Codec Private section of subtitle stream
|
* \brief Parse Codec Private section of subtitle stream
|
||||||
* \param track target track
|
* \param track target track
|
||||||
@ -171,7 +179,7 @@ void ass_process_codec_private(ass_track_t* track, char *data, int size);
|
|||||||
*/
|
*/
|
||||||
void ass_process_chunk(ass_track_t* track, char *data, int size, long long timecode, long long duration);
|
void ass_process_chunk(ass_track_t* track, char *data, int size, long long timecode, long long duration);
|
||||||
|
|
||||||
char* read_file_recode(char* fname, char* codepage, int* size);
|
char* read_file_recode(char* fname, char* codepage, size_t* size);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Read subtitles from file.
|
* \brief Read subtitles from file.
|
||||||
|
@ -63,7 +63,7 @@ static int init(sh_audio_t *sh_audio)
|
|||||||
lavc_context->sample_rate = sh_audio->wf->nSamplesPerSec;
|
lavc_context->sample_rate = sh_audio->wf->nSamplesPerSec;
|
||||||
lavc_context->bit_rate = sh_audio->wf->nAvgBytesPerSec * 8;
|
lavc_context->bit_rate = sh_audio->wf->nAvgBytesPerSec * 8;
|
||||||
lavc_context->block_align = sh_audio->wf->nBlockAlign;
|
lavc_context->block_align = sh_audio->wf->nBlockAlign;
|
||||||
lavc_context->bits_per_sample = sh_audio->wf->wBitsPerSample;
|
lavc_context->bits_per_coded_sample = sh_audio->wf->wBitsPerSample;
|
||||||
}
|
}
|
||||||
lavc_context->request_channels = audio_output_channels;
|
lavc_context->request_channels = audio_output_channels;
|
||||||
lavc_context->codec_tag = sh_audio->format; //FOURCC
|
lavc_context->codec_tag = sh_audio->format; //FOURCC
|
||||||
|
@ -20,7 +20,7 @@ static const vd_info_t info = {
|
|||||||
"ffmpeg",
|
"ffmpeg",
|
||||||
"A'rpi",
|
"A'rpi",
|
||||||
"A'rpi, Michael, Alex",
|
"A'rpi, Michael, Alex",
|
||||||
"native codecs (http://ffmpeg.sf.net/)"
|
"native codecs"
|
||||||
};
|
};
|
||||||
|
|
||||||
LIBVD_EXTERN(ffmpeg)
|
LIBVD_EXTERN(ffmpeg)
|
||||||
@ -266,7 +266,7 @@ static int init(sh_video_t *sh){
|
|||||||
avctx->width = sh->disp_w;
|
avctx->width = sh->disp_w;
|
||||||
avctx->height= sh->disp_h;
|
avctx->height= sh->disp_h;
|
||||||
avctx->workaround_bugs= lavc_param->workaround_bugs;
|
avctx->workaround_bugs= lavc_param->workaround_bugs;
|
||||||
avctx->error_resilience= lavc_param->error_resilience;
|
avctx->error_recognition= lavc_param->error_resilience;
|
||||||
if(lavc_param->gray) avctx->flags|= CODEC_FLAG_GRAY;
|
if(lavc_param->gray) avctx->flags|= CODEC_FLAG_GRAY;
|
||||||
#ifdef CODEC_FLAG2_FAST
|
#ifdef CODEC_FLAG2_FAST
|
||||||
avctx->flags2|= lavc_param->fast;
|
avctx->flags2|= lavc_param->fast;
|
||||||
@ -384,7 +384,7 @@ static int init(sh_video_t *sh){
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(sh->bih)
|
if(sh->bih)
|
||||||
avctx->bits_per_sample= sh->bih->biBitCount;
|
avctx->bits_per_coded_sample= sh->bih->biBitCount;
|
||||||
|
|
||||||
if(lavc_param->threads > 1)
|
if(lavc_param->threads > 1)
|
||||||
avcodec_thread_init(avctx, lavc_param->threads);
|
avcodec_thread_init(avctx, lavc_param->threads);
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
static const vd_info_t info =
|
static const vd_info_t info =
|
||||||
{
|
{
|
||||||
"MPEG 1/2 Video decoder libmpeg2-v0.4.0b",
|
"libmpeg2 MPEG 1/2 Video decoder",
|
||||||
"libmpeg2",
|
"libmpeg2",
|
||||||
"A'rpi & Fabian Franz",
|
"A'rpi & Fabian Franz",
|
||||||
"Aaron & Walken",
|
"Aaron & Walken",
|
||||||
|
@ -1,9 +1,26 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (C) 2005 Rik Snel <rsnel@cube.dyndns.org>, license GPL v2 or later
|
* Copyright (C) 2005 Rik Snel <rsnel@cube.dyndns.org>
|
||||||
* - based on vd_mpegpes.c by A'rpi (C) 2002-2003
|
* - based on vd_mpegpes.c by A'rpi (C) 2002-2003
|
||||||
* - guess_mjpeg_type code stolen from lav_io.c (C) 2000 Rainer Johanni
|
* - guess_mjpeg_type code stolen from lav_io.c (C) 2000 Rainer Johanni
|
||||||
* <Rainer@Johanni.de> from the mjpegtools package
|
* <Rainer@Johanni.de> from the mjpegtools package
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
@ -240,7 +240,7 @@ m_option_t lavcopts_conf[]={
|
|||||||
{"predia", &lavc_param_pre_dia_size, CONF_TYPE_INT, CONF_RANGE, -2000, 2000, NULL},
|
{"predia", &lavc_param_pre_dia_size, CONF_TYPE_INT, CONF_RANGE, -2000, 2000, NULL},
|
||||||
{"dia", &lavc_param_dia_size, CONF_TYPE_INT, CONF_RANGE, -2000, 2000, NULL},
|
{"dia", &lavc_param_dia_size, CONF_TYPE_INT, CONF_RANGE, -2000, 2000, NULL},
|
||||||
{"qpel", &lavc_param_qpel, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_QPEL, NULL},
|
{"qpel", &lavc_param_qpel, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_QPEL, NULL},
|
||||||
{"trell", &lavc_param_trell, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_TRELLIS_QUANT, NULL},
|
{"trell", &lavc_param_trell, CONF_TYPE_FLAG, 0, 0, 1, NULL},
|
||||||
{"lowdelay", &lavc_param_lowdelay, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_LOW_DELAY, NULL},
|
{"lowdelay", &lavc_param_lowdelay, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_LOW_DELAY, NULL},
|
||||||
{"last_pred", &lavc_param_last_pred, CONF_TYPE_INT, CONF_RANGE, 0, 2000, NULL},
|
{"last_pred", &lavc_param_last_pred, CONF_TYPE_INT, CONF_RANGE, 0, 2000, NULL},
|
||||||
{"preme", &lavc_param_pre_me, CONF_TYPE_INT, CONF_RANGE, 0, 2000, NULL},
|
{"preme", &lavc_param_pre_me, CONF_TYPE_INT, CONF_RANGE, 0, 2000, NULL},
|
||||||
@ -369,7 +369,6 @@ static int config(struct vf_instance* vf,
|
|||||||
lavc_venc_context->luma_elim_threshold= lavc_param_luma_elim_threshold;
|
lavc_venc_context->luma_elim_threshold= lavc_param_luma_elim_threshold;
|
||||||
lavc_venc_context->chroma_elim_threshold= lavc_param_chroma_elim_threshold;
|
lavc_venc_context->chroma_elim_threshold= lavc_param_chroma_elim_threshold;
|
||||||
lavc_venc_context->rtp_payload_size= lavc_param_packet_size;
|
lavc_venc_context->rtp_payload_size= lavc_param_packet_size;
|
||||||
if(lavc_param_packet_size )lavc_venc_context->rtp_mode=1;
|
|
||||||
lavc_venc_context->strict_std_compliance= lavc_param_strict;
|
lavc_venc_context->strict_std_compliance= lavc_param_strict;
|
||||||
lavc_venc_context->i_quant_factor= lavc_param_vi_qfactor;
|
lavc_venc_context->i_quant_factor= lavc_param_vi_qfactor;
|
||||||
lavc_venc_context->i_quant_offset= (int)(FF_QP2LAMBDA * lavc_param_vi_qoffset + 0.5);
|
lavc_venc_context->i_quant_offset= (int)(FF_QP2LAMBDA * lavc_param_vi_qoffset + 0.5);
|
||||||
@ -540,7 +539,7 @@ static int config(struct vf_instance* vf,
|
|||||||
#endif
|
#endif
|
||||||
lavc_venc_context->dia_size= lavc_param_dia_size;
|
lavc_venc_context->dia_size= lavc_param_dia_size;
|
||||||
lavc_venc_context->flags|= lavc_param_qpel;
|
lavc_venc_context->flags|= lavc_param_qpel;
|
||||||
lavc_venc_context->flags|= lavc_param_trell;
|
lavc_venc_context->trellis = lavc_param_trell;
|
||||||
lavc_venc_context->flags|= lavc_param_lowdelay;
|
lavc_venc_context->flags|= lavc_param_lowdelay;
|
||||||
lavc_venc_context->flags|= lavc_param_bit_exact;
|
lavc_venc_context->flags|= lavc_param_bit_exact;
|
||||||
lavc_venc_context->flags|= lavc_param_aic;
|
lavc_venc_context->flags|= lavc_param_aic;
|
||||||
@ -665,7 +664,7 @@ static int config(struct vf_instance* vf,
|
|||||||
|
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_QPEL;
|
lavc_venc_context->flags &= ~CODEC_FLAG_QPEL;
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_4MV;
|
lavc_venc_context->flags &= ~CODEC_FLAG_4MV;
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_TRELLIS_QUANT;
|
lavc_venc_context->trellis = 0;
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_CBP_RD;
|
lavc_venc_context->flags &= ~CODEC_FLAG_CBP_RD;
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_QP_RD;
|
lavc_venc_context->flags &= ~CODEC_FLAG_QP_RD;
|
||||||
lavc_venc_context->flags &= ~CODEC_FLAG_MV0;
|
lavc_venc_context->flags &= ~CODEC_FLAG_MV0;
|
||||||
@ -700,8 +699,8 @@ static int config(struct vf_instance* vf,
|
|||||||
|
|
||||||
/* free second pass buffer, its not needed anymore */
|
/* free second pass buffer, its not needed anymore */
|
||||||
av_freep(&lavc_venc_context->stats_in);
|
av_freep(&lavc_venc_context->stats_in);
|
||||||
if(lavc_venc_context->bits_per_sample)
|
if(lavc_venc_context->bits_per_coded_sample)
|
||||||
mux_v->bih->biBitCount= lavc_venc_context->bits_per_sample;
|
mux_v->bih->biBitCount= lavc_venc_context->bits_per_coded_sample;
|
||||||
if(lavc_venc_context->extradata_size){
|
if(lavc_venc_context->extradata_size){
|
||||||
mux_v->bih= realloc(mux_v->bih, sizeof(BITMAPINFOHEADER) + lavc_venc_context->extradata_size);
|
mux_v->bih= realloc(mux_v->bih, sizeof(BITMAPINFOHEADER) + lavc_venc_context->extradata_size);
|
||||||
memcpy(mux_v->bih + 1, lavc_venc_context->extradata, lavc_venc_context->extradata_size);
|
memcpy(mux_v->bih + 1, lavc_venc_context->extradata, lavc_venc_context->extradata_size);
|
||||||
|
@ -1,8 +1,26 @@
|
|||||||
/* vf_bmovl.c v0.9.1 - BitMap OVerLay videofilter for MPlayer
|
/*
|
||||||
|
* vf_bmovl.c v0.9.1 - BitMap OVerLay video filter for MPlayer
|
||||||
*
|
*
|
||||||
* (C) 2002 Per Wigren <wigren@home.se>
|
* (C) 2002 Per Wigren <wigren@home.se>
|
||||||
* Licenced under the GNU General Public License
|
|
||||||
*
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
* Use MPlayer as a framebuffer to read bitmaps and commands from a FIFO
|
* Use MPlayer as a framebuffer to read bitmaps and commands from a FIFO
|
||||||
* and display them in the window.
|
* and display them in the window.
|
||||||
*
|
*
|
||||||
|
@ -75,7 +75,10 @@ static int config(struct vf_instance* vf,
|
|||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
vf->priv->lut[i+129]= lrintf(ff_eval(vf->priv->eq, const_values, const_names, NULL, NULL, NULL, NULL, NULL));
|
const char *error = NULL;
|
||||||
|
vf->priv->lut[i+129]= lrintf(ff_eval2(vf->priv->eq, const_values, const_names, NULL, NULL, NULL, NULL, NULL, &error));
|
||||||
|
if (error)
|
||||||
|
mp_msg(MSGT_VFILTER, MSGL_ERR, "qp: Error evaluating \"%s\": %s\n", vf->priv->eq, error);
|
||||||
}
|
}
|
||||||
|
|
||||||
return vf_next_config(vf,width,height,d_width,d_height,flags,outfmt);
|
return vf_next_config(vf,width,height,d_width,d_height,flags,outfmt);
|
||||||
|
@ -1,20 +1,38 @@
|
|||||||
|
/*
|
||||||
|
* This files includes a straightforward (to be) optimized JPEG encoder for
|
||||||
|
* the YUV422 format, based on mjpeg code from ffmpeg.
|
||||||
|
*
|
||||||
|
* For an excellent introduction to the JPEG format, see:
|
||||||
|
* http://www.ece.purdue.edu/~bouman/grad-labs/lab8/pdf/lab.pdf
|
||||||
|
*
|
||||||
|
* Copyright (C) 2005 Rik Snel <rsnel@cube.dyndns.org>
|
||||||
|
* - based on vd_lavc.c by A'rpi (C) 2002-2003
|
||||||
|
* - parts from ffmpeg Copyright (c) 2000-2003 Fabrice Bellard
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \file vf_zrmjpeg.c
|
* \file vf_zrmjpeg.c
|
||||||
*
|
*
|
||||||
* \brief Does mjpeg encoding as required by the zrmjpeg filter as well
|
* \brief Does mjpeg encoding as required by the zrmjpeg filter as well
|
||||||
* as by the zr video driver.
|
* as by the zr video driver.
|
||||||
*/
|
*/
|
||||||
/*
|
|
||||||
* Copyright (C) 2005 Rik Snel <rsnel@cube.dyndns.org>, license GPL v2 or later
|
|
||||||
* - based on vd_lavc.c by A'rpi (C) 2002-2003
|
|
||||||
* - parts from ffmpeg Copyright (c) 2000-2003 Fabrice Bellard
|
|
||||||
*
|
|
||||||
* This files includes a straightforward (to be) optimized JPEG encoder for
|
|
||||||
* the YUV422 format, based on mjpeg code from ffmpeg.
|
|
||||||
*
|
|
||||||
* For an excellent introduction to the JPEG format, see:
|
|
||||||
* http://www.ece.purdue.edu/~bouman/grad-labs/lab8/pdf/lab.pdf
|
|
||||||
*/
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
@ -181,7 +181,6 @@ static const char *preferred_list[] = {
|
|||||||
"mov,mp4,m4a,3gp,3g2,mj2",
|
"mov,mp4,m4a,3gp,3g2,mj2",
|
||||||
"mpc",
|
"mpc",
|
||||||
"mpc8",
|
"mpc8",
|
||||||
"matroska",
|
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -250,7 +249,7 @@ static void handle_stream(demuxer_t *demuxer, AVFormatContext *avfc, int i) {
|
|||||||
wf->nSamplesPerSec= codec->sample_rate;
|
wf->nSamplesPerSec= codec->sample_rate;
|
||||||
wf->nAvgBytesPerSec= codec->bit_rate/8;
|
wf->nAvgBytesPerSec= codec->bit_rate/8;
|
||||||
wf->nBlockAlign= codec->block_align ? codec->block_align : 1;
|
wf->nBlockAlign= codec->block_align ? codec->block_align : 1;
|
||||||
wf->wBitsPerSample= codec->bits_per_sample;
|
wf->wBitsPerSample= codec->bits_per_coded_sample;
|
||||||
wf->cbSize= codec->extradata_size;
|
wf->cbSize= codec->extradata_size;
|
||||||
if(codec->extradata_size)
|
if(codec->extradata_size)
|
||||||
memcpy(wf + 1, codec->extradata, codec->extradata_size);
|
memcpy(wf + 1, codec->extradata, codec->extradata_size);
|
||||||
@ -326,7 +325,7 @@ static void handle_stream(demuxer_t *demuxer, AVFormatContext *avfc, int i) {
|
|||||||
bih->biSize= sizeof(BITMAPINFOHEADER) + codec->extradata_size;
|
bih->biSize= sizeof(BITMAPINFOHEADER) + codec->extradata_size;
|
||||||
bih->biWidth= codec->width;
|
bih->biWidth= codec->width;
|
||||||
bih->biHeight= codec->height;
|
bih->biHeight= codec->height;
|
||||||
bih->biBitCount= codec->bits_per_sample;
|
bih->biBitCount= codec->bits_per_coded_sample;
|
||||||
bih->biSizeImage = bih->biWidth * bih->biHeight * bih->biBitCount/8;
|
bih->biSizeImage = bih->biWidth * bih->biHeight * bih->biBitCount/8;
|
||||||
bih->biCompression= codec->codec_tag;
|
bih->biCompression= codec->codec_tag;
|
||||||
sh_video->bih= bih;
|
sh_video->bih= bih;
|
||||||
@ -594,8 +593,8 @@ static int demux_lavf_fill_buffer(demuxer_t *demux, demux_stream_t *dsds){
|
|||||||
if(pkt.pts != AV_NOPTS_VALUE){
|
if(pkt.pts != AV_NOPTS_VALUE){
|
||||||
dp->pts=pkt.pts * av_q2d(priv->avfc->streams[id]->time_base);
|
dp->pts=pkt.pts * av_q2d(priv->avfc->streams[id]->time_base);
|
||||||
priv->last_pts= dp->pts * AV_TIME_BASE;
|
priv->last_pts= dp->pts * AV_TIME_BASE;
|
||||||
if(pkt.duration)
|
if(pkt.convergence_duration)
|
||||||
dp->endpts = dp->pts + pkt.duration * av_q2d(priv->avfc->streams[id]->time_base);
|
dp->endpts = dp->pts + pkt.convergence_duration * av_q2d(priv->avfc->streams[id]->time_base);
|
||||||
}
|
}
|
||||||
dp->pos=demux->filepos;
|
dp->pos=demux->filepos;
|
||||||
dp->flags= !!(pkt.flags&PKT_FLAG_KEY);
|
dp->flags= !!(pkt.flags&PKT_FLAG_KEY);
|
||||||
|
@ -239,16 +239,20 @@ static void mpeg2_idct_add_c (const int last, int16_t * block,
|
|||||||
|
|
||||||
void mpeg2_idct_init (uint32_t accel)
|
void mpeg2_idct_init (uint32_t accel)
|
||||||
{
|
{
|
||||||
#ifdef ARCH_X86
|
#ifdef HAVE_SSE2
|
||||||
if (accel & MPEG2_ACCEL_X86_SSE2) {
|
if (accel & MPEG2_ACCEL_X86_SSE2) {
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_sse2;
|
mpeg2_idct_copy = mpeg2_idct_copy_sse2;
|
||||||
mpeg2_idct_add = mpeg2_idct_add_sse2;
|
mpeg2_idct_add = mpeg2_idct_add_sse2;
|
||||||
mpeg2_idct_mmx_init ();
|
mpeg2_idct_mmx_init ();
|
||||||
} else if (accel & MPEG2_ACCEL_X86_MMXEXT) {
|
} else
|
||||||
|
#elif HAVE_MMX2
|
||||||
|
if (accel & MPEG2_ACCEL_X86_MMXEXT) {
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_mmxext;
|
mpeg2_idct_copy = mpeg2_idct_copy_mmxext;
|
||||||
mpeg2_idct_add = mpeg2_idct_add_mmxext;
|
mpeg2_idct_add = mpeg2_idct_add_mmxext;
|
||||||
mpeg2_idct_mmx_init ();
|
mpeg2_idct_mmx_init ();
|
||||||
} else if (accel & MPEG2_ACCEL_X86_MMX) {
|
} else
|
||||||
|
#elif HAVE_MMX
|
||||||
|
if (accel & MPEG2_ACCEL_X86_MMX) {
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_mmx;
|
mpeg2_idct_copy = mpeg2_idct_copy_mmx;
|
||||||
mpeg2_idct_add = mpeg2_idct_add_mmx;
|
mpeg2_idct_add = mpeg2_idct_add_mmx;
|
||||||
mpeg2_idct_mmx_init ();
|
mpeg2_idct_mmx_init ();
|
||||||
@ -261,12 +265,14 @@ void mpeg2_idct_init (uint32_t accel)
|
|||||||
mpeg2_idct_altivec_init ();
|
mpeg2_idct_altivec_init ();
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
#ifdef ARCH_ALPHA
|
#ifdef HAVE_VIS
|
||||||
if (accel & MPEG2_ACCEL_ALPHA_MVI) {
|
if (accel & MPEG2_ACCEL_ALPHA_MVI) {
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_mvi;
|
mpeg2_idct_copy = mpeg2_idct_copy_mvi;
|
||||||
mpeg2_idct_add = mpeg2_idct_add_mvi;
|
mpeg2_idct_add = mpeg2_idct_add_mvi;
|
||||||
mpeg2_idct_alpha_init ();
|
mpeg2_idct_alpha_init ();
|
||||||
} else if (accel & MPEG2_ACCEL_ALPHA) {
|
} else
|
||||||
|
#elif ARCH_ALPHA
|
||||||
|
if (accel & MPEG2_ACCEL_ALPHA) {
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_alpha;
|
mpeg2_idct_copy = mpeg2_idct_copy_alpha;
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
uint32_t eax, ebx, ecx, edx;
|
uint32_t eax, ebx, ecx, edx;
|
||||||
int AMD;
|
int AMD;
|
||||||
uint32_t caps;
|
uint32_t caps;
|
||||||
@@ -105,7 +120,21 @@
|
@@ -107,8 +120,22 @@
|
||||||
caps |= MPEG2_ACCEL_X86_MMXEXT;
|
caps |= MPEG2_ACCEL_X86_MMXEXT;
|
||||||
|
|
||||||
return caps;
|
return caps;
|
||||||
@ -50,7 +50,8 @@
|
|||||||
+#endif /* ARCH_X86 || ARCH_X86_64 */
|
+#endif /* ARCH_X86 || ARCH_X86_64 */
|
||||||
|
|
||||||
#if defined(ARCH_PPC) || defined(ARCH_SPARC)
|
#if defined(ARCH_PPC) || defined(ARCH_SPARC)
|
||||||
@@ -212,7 +241,7 @@
|
#include <signal.h>
|
||||||
|
@@ -214,7 +241,7 @@
|
||||||
|
|
||||||
accel = 0;
|
accel = 0;
|
||||||
#ifdef ACCEL_DETECT
|
#ifdef ACCEL_DETECT
|
||||||
@ -78,7 +79,7 @@
|
|||||||
static void state_restore_mmx (cpu_state_t * state)
|
static void state_restore_mmx (cpu_state_t * state)
|
||||||
{
|
{
|
||||||
emms ();
|
emms ();
|
||||||
@@ -48,18 +48,18 @@
|
@@ -44,18 +48,18 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef ARCH_PPC
|
#ifdef ARCH_PPC
|
||||||
@ -104,7 +105,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
static void state_save_altivec (cpu_state_t * state)
|
static void state_save_altivec (cpu_state_t * state)
|
||||||
@@ -115,9 +119,9 @@
|
@@ -115,7 +119,7 @@
|
||||||
|
|
||||||
void mpeg2_cpu_state_init (uint32_t accel)
|
void mpeg2_cpu_state_init (uint32_t accel)
|
||||||
{
|
{
|
||||||
@ -113,8 +114,6 @@
|
|||||||
if (accel & MPEG2_ACCEL_X86_MMX) {
|
if (accel & MPEG2_ACCEL_X86_MMX) {
|
||||||
mpeg2_cpu_state_restore = state_restore_mmx;
|
mpeg2_cpu_state_restore = state_restore_mmx;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#ifdef ARCH_PPC
|
|
||||||
--- libmpeg2/decode.c 2006-06-16 20:12:26.000000000 +0200
|
--- libmpeg2/decode.c 2006-06-16 20:12:26.000000000 +0200
|
||||||
+++ libmpeg2/decode.c 2006-06-16 20:12:50.000000000 +0200
|
+++ libmpeg2/decode.c 2006-06-16 20:12:50.000000000 +0200
|
||||||
@@ -351,6 +355,15 @@
|
@@ -351,6 +355,15 @@
|
||||||
@ -145,7 +144,7 @@
|
|||||||
mpeg2dec->fbuf[0] = &mpeg2dec->fbuf_alloc[0].fbuf;
|
mpeg2dec->fbuf[0] = &mpeg2dec->fbuf_alloc[0].fbuf;
|
||||||
mpeg2dec->fbuf[1] = &mpeg2dec->fbuf_alloc[1].fbuf;
|
mpeg2dec->fbuf[1] = &mpeg2dec->fbuf_alloc[1].fbuf;
|
||||||
mpeg2dec->fbuf[2] = &mpeg2dec->fbuf_alloc[2].fbuf;
|
mpeg2dec->fbuf[2] = &mpeg2dec->fbuf_alloc[2].fbuf;
|
||||||
@@ -551,6 +558,7 @@
|
@@ -553,6 +560,7 @@
|
||||||
if (!(mpeg2dec->sequence.flags & SEQ_FLAG_PROGRESSIVE_SEQUENCE)) {
|
if (!(mpeg2dec->sequence.flags & SEQ_FLAG_PROGRESSIVE_SEQUENCE)) {
|
||||||
picture->nb_fields = (buffer[3] & 2) ? 3 : 2;
|
picture->nb_fields = (buffer[3] & 2) ? 3 : 2;
|
||||||
flags |= (buffer[3] & 128) ? PIC_FLAG_TOP_FIELD_FIRST : 0;
|
flags |= (buffer[3] & 128) ? PIC_FLAG_TOP_FIELD_FIRST : 0;
|
||||||
@ -153,7 +152,7 @@
|
|||||||
} else
|
} else
|
||||||
picture->nb_fields = (buffer[3]&2) ? ((buffer[3]&128) ? 6 : 4) : 2;
|
picture->nb_fields = (buffer[3]&2) ? ((buffer[3]&128) ? 6 : 4) : 2;
|
||||||
break;
|
break;
|
||||||
@@ -799,6 +807,7 @@
|
@@ -801,6 +809,7 @@
|
||||||
mpeg2dec->scaled[index] = mpeg2dec->q_scale_type;
|
mpeg2dec->scaled[index] = mpeg2dec->q_scale_type;
|
||||||
for (i = 0; i < 32; i++) {
|
for (i = 0; i < 32; i++) {
|
||||||
k = mpeg2dec->q_scale_type ? non_linear_scale[i] : (i << 1);
|
k = mpeg2dec->q_scale_type ? non_linear_scale[i] : (i << 1);
|
||||||
@ -163,7 +162,28 @@
|
|||||||
k * mpeg2dec->quantizer_matrix[index][j];
|
k * mpeg2dec->quantizer_matrix[index][j];
|
||||||
--- libmpeg2/idct.c (revision 26652)
|
--- libmpeg2/idct.c (revision 26652)
|
||||||
+++ libmpeg2/idct.c (working copy)
|
+++ libmpeg2/idct.c (working copy)
|
||||||
@@ -250,7 +254,7 @@
|
@@ -235,30 +239,40 @@
|
||||||
|
|
||||||
|
void mpeg2_idct_init (uint32_t accel)
|
||||||
|
{
|
||||||
|
-#ifdef ARCH_X86
|
||||||
|
+#ifdef HAVE_SSE2
|
||||||
|
+ if (accel & MPEG2_ACCEL_X86_SSE2) {
|
||||||
|
+ mpeg2_idct_copy = mpeg2_idct_copy_sse2;
|
||||||
|
+ mpeg2_idct_add = mpeg2_idct_add_sse2;
|
||||||
|
+ mpeg2_idct_mmx_init ();
|
||||||
|
+ } else
|
||||||
|
+#elif HAVE_MMX2
|
||||||
|
if (accel & MPEG2_ACCEL_X86_MMXEXT) {
|
||||||
|
mpeg2_idct_copy = mpeg2_idct_copy_mmxext;
|
||||||
|
mpeg2_idct_add = mpeg2_idct_add_mmxext;
|
||||||
|
mpeg2_idct_mmx_init ();
|
||||||
|
- } else if (accel & MPEG2_ACCEL_X86_MMX) {
|
||||||
|
+ } else
|
||||||
|
+#elif HAVE_MMX
|
||||||
|
+ if (accel & MPEG2_ACCEL_X86_MMX) {
|
||||||
|
mpeg2_idct_copy = mpeg2_idct_copy_mmx;
|
||||||
|
mpeg2_idct_add = mpeg2_idct_add_mmx;
|
||||||
mpeg2_idct_mmx_init ();
|
mpeg2_idct_mmx_init ();
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
@ -172,6 +192,22 @@
|
|||||||
if (accel & MPEG2_ACCEL_PPC_ALTIVEC) {
|
if (accel & MPEG2_ACCEL_PPC_ALTIVEC) {
|
||||||
mpeg2_idct_copy = mpeg2_idct_copy_altivec;
|
mpeg2_idct_copy = mpeg2_idct_copy_altivec;
|
||||||
mpeg2_idct_add = mpeg2_idct_add_altivec;
|
mpeg2_idct_add = mpeg2_idct_add_altivec;
|
||||||
|
mpeg2_idct_altivec_init ();
|
||||||
|
} else
|
||||||
|
#endif
|
||||||
|
-#ifdef ARCH_ALPHA
|
||||||
|
+#ifdef HAVE_VIS
|
||||||
|
if (accel & MPEG2_ACCEL_ALPHA_MVI) {
|
||||||
|
mpeg2_idct_copy = mpeg2_idct_copy_mvi;
|
||||||
|
mpeg2_idct_add = mpeg2_idct_add_mvi;
|
||||||
|
mpeg2_idct_alpha_init ();
|
||||||
|
- } else if (accel & MPEG2_ACCEL_ALPHA) {
|
||||||
|
+ } else
|
||||||
|
+#elif ARCH_ALPHA
|
||||||
|
+ if (accel & MPEG2_ACCEL_ALPHA) {
|
||||||
|
int i;
|
||||||
|
|
||||||
|
mpeg2_idct_copy = mpeg2_idct_copy_alpha;
|
||||||
--- libmpeg2/idct_mmx.c 2006-06-16 20:12:26.000000000 +0200
|
--- libmpeg2/idct_mmx.c 2006-06-16 20:12:26.000000000 +0200
|
||||||
+++ libmpeg2/idct_mmx.c 2006-06-16 20:12:50.000000000 +0200
|
+++ libmpeg2/idct_mmx.c 2006-06-16 20:12:50.000000000 +0200
|
||||||
@@ -23,7 +27,7 @@
|
@@ -23,7 +27,7 @@
|
||||||
@ -185,7 +221,25 @@
|
|||||||
|
|
||||||
--- libmpeg2/motion_comp.c 2006-06-16 20:12:26.000000000 +0200
|
--- libmpeg2/motion_comp.c 2006-06-16 20:12:26.000000000 +0200
|
||||||
+++ libmpeg2/motion_comp.c 2006-06-16 20:12:50.000000000 +0200
|
+++ libmpeg2/motion_comp.c 2006-06-16 20:12:50.000000000 +0200
|
||||||
@@ -46,7 +46,7 @@
|
@@ -33,16 +37,22 @@
|
||||||
|
|
||||||
|
void mpeg2_mc_init (uint32_t accel)
|
||||||
|
{
|
||||||
|
-#ifdef ARCH_X86
|
||||||
|
+#ifdef HAVE_MMX2
|
||||||
|
if (accel & MPEG2_ACCEL_X86_MMXEXT)
|
||||||
|
mpeg2_mc = mpeg2_mc_mmxext;
|
||||||
|
- else if (accel & MPEG2_ACCEL_X86_3DNOW)
|
||||||
|
+ else
|
||||||
|
+#endif
|
||||||
|
+#ifdef HAVE_3DNOW
|
||||||
|
+ if (accel & MPEG2_ACCEL_X86_3DNOW)
|
||||||
|
mpeg2_mc = mpeg2_mc_3dnow;
|
||||||
|
- else if (accel & MPEG2_ACCEL_X86_MMX)
|
||||||
|
+ else
|
||||||
|
+#endif
|
||||||
|
+#ifdef HAVE_MMX
|
||||||
|
+ if (accel & MPEG2_ACCEL_X86_MMX)
|
||||||
mpeg2_mc = mpeg2_mc_mmx;
|
mpeg2_mc = mpeg2_mc_mmx;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@ -194,7 +248,13 @@
|
|||||||
if (accel & MPEG2_ACCEL_PPC_ALTIVEC)
|
if (accel & MPEG2_ACCEL_PPC_ALTIVEC)
|
||||||
mpeg2_mc = mpeg2_mc_altivec;
|
mpeg2_mc = mpeg2_mc_altivec;
|
||||||
else
|
else
|
||||||
@@ -61,6 +61,16 @@
|
@@ -52,11 +62,21 @@
|
||||||
|
mpeg2_mc = mpeg2_mc_alpha;
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
-#ifdef ARCH_SPARC
|
||||||
|
+#ifdef HAVE_VIS
|
||||||
|
if (accel & MPEG2_ACCEL_SPARC_VIS)
|
||||||
mpeg2_mc = mpeg2_mc_vis;
|
mpeg2_mc = mpeg2_mc_vis;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@ -232,7 +292,8 @@
|
|||||||
#define PIC_MASK_COMPOSITE_DISPLAY 0xfffff000
|
#define PIC_MASK_COMPOSITE_DISPLAY 0xfffff000
|
||||||
|
|
||||||
typedef struct mpeg2_picture_s {
|
typedef struct mpeg2_picture_s {
|
||||||
@@ -156,10 +160,13 @@
|
@@ -154,11 +159,14 @@
|
||||||
|
#define MPEG2_ACCEL_X86_MMX 1
|
||||||
#define MPEG2_ACCEL_X86_3DNOW 2
|
#define MPEG2_ACCEL_X86_3DNOW 2
|
||||||
#define MPEG2_ACCEL_X86_MMXEXT 4
|
#define MPEG2_ACCEL_X86_MMXEXT 4
|
||||||
+#define MPEG2_ACCEL_X86_SSE2 8
|
+#define MPEG2_ACCEL_X86_SSE2 8
|
||||||
@ -260,7 +321,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@@ -214,6 +224,9 @@
|
@@ -214,6 +223,9 @@
|
||||||
int8_t q_scale_type, scaled[4];
|
int8_t q_scale_type, scaled[4];
|
||||||
uint8_t quantizer_matrix[4][64];
|
uint8_t quantizer_matrix[4][64];
|
||||||
uint8_t new_quantizer_matrix[4][64];
|
uint8_t new_quantizer_matrix[4][64];
|
||||||
@ -270,7 +331,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@@ -312,3 +312,5 @@
|
@@ -298,3 +313,5 @@
|
||||||
extern mpeg2_mc_t mpeg2_mc_altivec;
|
extern mpeg2_mc_t mpeg2_mc_altivec;
|
||||||
extern mpeg2_mc_t mpeg2_mc_alpha;
|
extern mpeg2_mc_t mpeg2_mc_alpha;
|
||||||
extern mpeg2_mc_t mpeg2_mc_vis;
|
extern mpeg2_mc_t mpeg2_mc_vis;
|
||||||
@ -286,7 +347,7 @@
|
|||||||
|
|
||||||
decoder->quantizer_matrix[0] =
|
decoder->quantizer_matrix[0] =
|
||||||
decoder->quantizer_prescale[0][quantizer_scale_code];
|
decoder->quantizer_prescale[0][quantizer_scale_code];
|
||||||
@@ -1568,6 +1569,18 @@
|
@@ -1564,6 +1569,18 @@
|
||||||
|
|
||||||
#define NEXT_MACROBLOCK \
|
#define NEXT_MACROBLOCK \
|
||||||
do { \
|
do { \
|
||||||
@ -305,7 +366,7 @@
|
|||||||
decoder->offset += 16; \
|
decoder->offset += 16; \
|
||||||
if (decoder->offset == decoder->width) { \
|
if (decoder->offset == decoder->width) { \
|
||||||
do { /* just so we can use the break statement */ \
|
do { /* just so we can use the break statement */ \
|
||||||
@@ -1604,6 +1604,12 @@
|
@@ -1587,6 +1604,12 @@
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
@ -318,7 +379,7 @@
|
|||||||
void mpeg2_init_fbuf (mpeg2_decoder_t * decoder, uint8_t * current_fbuf[3],
|
void mpeg2_init_fbuf (mpeg2_decoder_t * decoder, uint8_t * current_fbuf[3],
|
||||||
uint8_t * forward_fbuf[3], uint8_t * backward_fbuf[3])
|
uint8_t * forward_fbuf[3], uint8_t * backward_fbuf[3])
|
||||||
{
|
{
|
||||||
@@ -1661,7 +1667,9 @@
|
@@ -1644,7 +1667,9 @@
|
||||||
|
|
||||||
if (decoder->mpeg1) {
|
if (decoder->mpeg1) {
|
||||||
decoder->motion_parser[0] = motion_zero_420;
|
decoder->motion_parser[0] = motion_zero_420;
|
||||||
|
@ -37,12 +37,18 @@ mpeg2_mc_t mpeg2_mc;
|
|||||||
|
|
||||||
void mpeg2_mc_init (uint32_t accel)
|
void mpeg2_mc_init (uint32_t accel)
|
||||||
{
|
{
|
||||||
#ifdef ARCH_X86
|
#ifdef HAVE_MMX2
|
||||||
if (accel & MPEG2_ACCEL_X86_MMXEXT)
|
if (accel & MPEG2_ACCEL_X86_MMXEXT)
|
||||||
mpeg2_mc = mpeg2_mc_mmxext;
|
mpeg2_mc = mpeg2_mc_mmxext;
|
||||||
else if (accel & MPEG2_ACCEL_X86_3DNOW)
|
else
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_3DNOW
|
||||||
|
if (accel & MPEG2_ACCEL_X86_3DNOW)
|
||||||
mpeg2_mc = mpeg2_mc_3dnow;
|
mpeg2_mc = mpeg2_mc_3dnow;
|
||||||
else if (accel & MPEG2_ACCEL_X86_MMX)
|
else
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_MMX
|
||||||
|
if (accel & MPEG2_ACCEL_X86_MMX)
|
||||||
mpeg2_mc = mpeg2_mc_mmx;
|
mpeg2_mc = mpeg2_mc_mmx;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@ -56,7 +62,7 @@ void mpeg2_mc_init (uint32_t accel)
|
|||||||
mpeg2_mc = mpeg2_mc_alpha;
|
mpeg2_mc = mpeg2_mc_alpha;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
#ifdef ARCH_SPARC
|
#ifdef HAVE_VIS
|
||||||
if (accel & MPEG2_ACCEL_SPARC_VIS)
|
if (accel & MPEG2_ACCEL_SPARC_VIS)
|
||||||
mpeg2_mc = mpeg2_mc_vis;
|
mpeg2_mc = mpeg2_mc_vis;
|
||||||
else
|
else
|
||||||
|
@ -35,22 +35,22 @@
|
|||||||
|
|
||||||
#define FAST_BGR2YV12 // use 7-bit instead of 15-bit coefficients
|
#define FAST_BGR2YV12 // use 7-bit instead of 15-bit coefficients
|
||||||
|
|
||||||
void (*rgb24to32)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb24to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb24to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb32to24)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb32tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb32to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb32to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb32to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb32to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb15to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb15to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb15to24)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb15tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb15to32)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb15to32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb16to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb16to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb16to24)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb16tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb16to32)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb16to32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
//void (*rgb24tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
//void (*rgb24tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb24tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24to16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb24to15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb32tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb32tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
//void (*rgb32tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
//void (*rgb32tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
void (*rgb32tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
void (*rgb32tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
@ -65,6 +65,9 @@ void (*yv12touyvy)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc
|
|||||||
void (*yuv422ptoyuy2)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
void (*yuv422ptoyuy2)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
||||||
long width, long height,
|
long width, long height,
|
||||||
long lumStride, long chromStride, long dstStride);
|
long lumStride, long chromStride, long dstStride);
|
||||||
|
void (*yuv422ptouyvy)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
||||||
|
long width, long height,
|
||||||
|
long lumStride, long chromStride, long dstStride);
|
||||||
void (*yuy2toyv12)(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
void (*yuy2toyv12)(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
||||||
long width, long height,
|
long width, long height,
|
||||||
long lumStride, long chromStride, long srcStride);
|
long lumStride, long chromStride, long srcStride);
|
||||||
@ -330,7 +333,7 @@ void palette8tobgr15(const uint8_t *src, uint8_t *dst, long num_pixels, const ui
|
|||||||
((uint16_t *)dst)[i] = bswap_16(((const uint16_t *)palette)[src[i]]);
|
((uint16_t *)dst)[i] = bswap_16(((const uint16_t *)palette)[src[i]]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void rgb32tobgr24(const uint8_t *src, uint8_t *dst, long src_size)
|
void rgb32to24(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
long i;
|
long i;
|
||||||
long num_pixels = src_size >> 2;
|
long num_pixels = src_size >> 2;
|
||||||
@ -349,7 +352,7 @@ void rgb32tobgr24(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void rgb24tobgr32(const uint8_t *src, uint8_t *dst, long src_size)
|
void rgb24to32(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
long i;
|
long i;
|
||||||
for (i=0; 3*i<src_size; i++)
|
for (i=0; 3*i<src_size; i++)
|
||||||
@ -393,7 +396,7 @@ void rgb16tobgr32(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void rgb16tobgr24(const uint8_t *src, uint8_t *dst, long src_size)
|
void rgb16to24(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint16_t *end;
|
const uint16_t *end;
|
||||||
uint8_t *d = dst;
|
uint8_t *d = dst;
|
||||||
@ -416,13 +419,8 @@ void rgb16tobgr16(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
|
|
||||||
for (i=0; i<num_pixels; i++)
|
for (i=0; i<num_pixels; i++)
|
||||||
{
|
{
|
||||||
unsigned b,g,r;
|
unsigned rgb = ((const uint16_t*)src)[i];
|
||||||
register uint16_t rgb;
|
((uint16_t*)dst)[i] = (rgb>>11) | (rgb&0x7E0) | (rgb<<11);
|
||||||
rgb = src[2*i];
|
|
||||||
r = rgb&0x1F;
|
|
||||||
g = (rgb&0x7E0)>>5;
|
|
||||||
b = (rgb&0xF800)>>11;
|
|
||||||
dst[2*i] = (b&0x1F) | ((g&0x3F)<<5) | ((r&0x1F)<<11);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -433,13 +431,8 @@ void rgb16tobgr15(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
|
|
||||||
for (i=0; i<num_pixels; i++)
|
for (i=0; i<num_pixels; i++)
|
||||||
{
|
{
|
||||||
unsigned b,g,r;
|
unsigned rgb = ((const uint16_t*)src)[i];
|
||||||
register uint16_t rgb;
|
((uint16_t*)dst)[i] = (rgb>>11) | ((rgb&0x7C0)>>1) | ((rgb&0x1F)<<10);
|
||||||
rgb = src[2*i];
|
|
||||||
r = rgb&0x1F;
|
|
||||||
g = (rgb&0x7E0)>>5;
|
|
||||||
b = (rgb&0xF800)>>11;
|
|
||||||
dst[2*i] = (b&0x1F) | ((g&0x1F)<<5) | ((r&0x1F)<<10);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -467,7 +460,7 @@ void rgb15tobgr32(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void rgb15tobgr24(const uint8_t *src, uint8_t *dst, long src_size)
|
void rgb15to24(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint16_t *end;
|
const uint16_t *end;
|
||||||
uint8_t *d = dst;
|
uint8_t *d = dst;
|
||||||
@ -490,13 +483,8 @@ void rgb15tobgr16(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
|
|
||||||
for (i=0; i<num_pixels; i++)
|
for (i=0; i<num_pixels; i++)
|
||||||
{
|
{
|
||||||
unsigned b,g,r;
|
unsigned rgb = ((const uint16_t*)src)[i];
|
||||||
register uint16_t rgb;
|
((uint16_t*)dst)[i] = ((rgb&0x7C00)>>10) | ((rgb&0x3E0)<<1) | (rgb<<11);
|
||||||
rgb = src[2*i];
|
|
||||||
r = rgb&0x1F;
|
|
||||||
g = (rgb&0x3E0)>>5;
|
|
||||||
b = (rgb&0x7C00)>>10;
|
|
||||||
dst[2*i] = (b&0x1F) | ((g&0x3F)<<5) | ((r&0x1F)<<11);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -507,17 +495,14 @@ void rgb15tobgr15(const uint8_t *src, uint8_t *dst, long src_size)
|
|||||||
|
|
||||||
for (i=0; i<num_pixels; i++)
|
for (i=0; i<num_pixels; i++)
|
||||||
{
|
{
|
||||||
unsigned b,g,r;
|
unsigned br;
|
||||||
register uint16_t rgb;
|
unsigned rgb = ((const uint16_t*)src)[i];
|
||||||
rgb = src[2*i];
|
br = rgb&0x7c1F;
|
||||||
r = rgb&0x1F;
|
((uint16_t*)dst)[i] = (br>>10) | (rgb&0x3E0) | (br<<10);
|
||||||
g = (rgb&0x3E0)>>5;
|
|
||||||
b = (rgb&0x7C00)>>10;
|
|
||||||
dst[2*i] = (b&0x1F) | ((g&0x1F)<<5) | ((r&0x1F)<<10);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void rgb8tobgr8(const uint8_t *src, uint8_t *dst, long src_size)
|
void bgr8torgb8(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
long i;
|
long i;
|
||||||
long num_pixels = src_size;
|
long num_pixels = src_size;
|
||||||
|
@ -29,36 +29,36 @@
|
|||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
|
|
||||||
/* A full collection of RGB to RGB(BGR) converters */
|
/* A full collection of RGB to RGB(BGR) converters */
|
||||||
extern void (*rgb24to32) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb24to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb24to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32to24) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb15to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb15to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb15to24) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb15tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb15to32) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb15to32) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb16to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb16to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb16to24) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb16tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb16to32) (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb16to32) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb24tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24tobgr24)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24to16) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb24to15) (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32tobgr32)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32tobgr16)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void (*rgb32tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void (*rgb32tobgr15)(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
|
|
||||||
extern void rgb24tobgr32(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb24to32 (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb32tobgr24(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb32to24 (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb16tobgr32(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb16tobgr32(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb16tobgr24(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb16to24 (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb16tobgr16(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb16tobgr16(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb16tobgr15(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb16tobgr15(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb15tobgr32(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb15tobgr32(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb15tobgr24(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb15to24 (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb15tobgr16(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb15tobgr16(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb15tobgr15(const uint8_t *src, uint8_t *dst, long src_size);
|
extern void rgb15tobgr15(const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
extern void rgb8tobgr8 (const uint8_t *src, uint8_t *dst, long src_size);
|
extern void bgr8torgb8 (const uint8_t *src, uint8_t *dst, long src_size);
|
||||||
|
|
||||||
|
|
||||||
extern void palette8torgb32(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette);
|
extern void palette8torgb32(const uint8_t *src, uint8_t *dst, long num_pixels, const uint8_t *palette);
|
||||||
@ -74,7 +74,7 @@ extern void palette8tobgr15(const uint8_t *src, uint8_t *dst, long num_pixels, c
|
|||||||
* Height should be a multiple of 2 and width should be a multiple of 16.
|
* Height should be a multiple of 2 and width should be a multiple of 16.
|
||||||
* (If this is a problem for anyone then tell me, and I will fix it.)
|
* (If this is a problem for anyone then tell me, and I will fix it.)
|
||||||
* Chrominance data is only taken from every second line, others are ignored.
|
* Chrominance data is only taken from every second line, others are ignored.
|
||||||
* FIXME: Write HQ version.
|
* FIXME: Write high quality version.
|
||||||
*/
|
*/
|
||||||
//void uyvytoyv12(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
//void uyvytoyv12(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
||||||
|
|
||||||
@ -109,11 +109,18 @@ extern void (*yv12touyvy)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_
|
|||||||
long width, long height,
|
long width, long height,
|
||||||
long lumStride, long chromStride, long dstStride);
|
long lumStride, long chromStride, long dstStride);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Width should be a multiple of 16.
|
||||||
|
*/
|
||||||
|
extern void (*yuv422ptouyvy)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
||||||
|
long width, long height,
|
||||||
|
long lumStride, long chromStride, long dstStride);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Height should be a multiple of 2 and width should be a multiple of 2.
|
* Height should be a multiple of 2 and width should be a multiple of 2.
|
||||||
* (If this is a problem for anyone then tell me, and I will fix it.)
|
* (If this is a problem for anyone then tell me, and I will fix it.)
|
||||||
* Chrominance data is only taken from every second line, others are ignored.
|
* Chrominance data is only taken from every second line, others are ignored.
|
||||||
* FIXME: Write HQ version.
|
* FIXME: Write high quality version.
|
||||||
*/
|
*/
|
||||||
extern void (*rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
extern void (*rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
||||||
long width, long height,
|
long width, long height,
|
||||||
|
@ -82,7 +82,7 @@
|
|||||||
#define SFENCE " # nop"
|
#define SFENCE " # nop"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static inline void RENAME(rgb24to32)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb24tobgr32)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
uint8_t *dest = dst;
|
uint8_t *dest = dst;
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
@ -142,7 +142,7 @@ static inline void RENAME(rgb24to32)(const uint8_t *src, uint8_t *dst, long src_
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb32to24)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb32tobgr24)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
uint8_t *dest = dst;
|
uint8_t *dest = dst;
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
@ -657,7 +657,7 @@ static inline void RENAME(rgb32tobgr15)(const uint8_t *src, uint8_t *dst, long s
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb24to16)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
const uint8_t *end;
|
const uint8_t *end;
|
||||||
@ -720,7 +720,7 @@ static inline void RENAME(rgb24to16)(const uint8_t *src, uint8_t *dst, long src_
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb24to16)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
const uint8_t *end;
|
const uint8_t *end;
|
||||||
@ -783,7 +783,7 @@ static inline void RENAME(rgb24tobgr16)(const uint8_t *src, uint8_t *dst, long s
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb24to15)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
const uint8_t *end;
|
const uint8_t *end;
|
||||||
@ -846,7 +846,7 @@ static inline void RENAME(rgb24to15)(const uint8_t *src, uint8_t *dst, long src_
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb24to15)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint8_t *s = src;
|
const uint8_t *s = src;
|
||||||
const uint8_t *end;
|
const uint8_t *end;
|
||||||
@ -930,7 +930,7 @@ static inline void RENAME(rgb24tobgr15)(const uint8_t *src, uint8_t *dst, long s
|
|||||||
|
|
|
|
||||||
original bits
|
original bits
|
||||||
*/
|
*/
|
||||||
static inline void RENAME(rgb15to24)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb15tobgr24)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint16_t *end;
|
const uint16_t *end;
|
||||||
#ifdef HAVE_MMX
|
#ifdef HAVE_MMX
|
||||||
@ -1072,7 +1072,7 @@ static inline void RENAME(rgb15to24)(const uint8_t *src, uint8_t *dst, long src_
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void RENAME(rgb16to24)(const uint8_t *src, uint8_t *dst, long src_size)
|
static inline void RENAME(rgb16tobgr24)(const uint8_t *src, uint8_t *dst, long src_size)
|
||||||
{
|
{
|
||||||
const uint16_t *end;
|
const uint16_t *end;
|
||||||
#ifdef HAVE_MMX
|
#ifdef HAVE_MMX
|
||||||
@ -1755,6 +1755,16 @@ static inline void RENAME(yv12touyvy)(const uint8_t *ysrc, const uint8_t *usrc,
|
|||||||
RENAME(yuvPlanartouyvy)(ysrc, usrc, vsrc, dst, width, height, lumStride, chromStride, dstStride, 2);
|
RENAME(yuvPlanartouyvy)(ysrc, usrc, vsrc, dst, width, height, lumStride, chromStride, dstStride, 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Width should be a multiple of 16.
|
||||||
|
*/
|
||||||
|
static inline void RENAME(yuv422ptouyvy)(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
||||||
|
long width, long height,
|
||||||
|
long lumStride, long chromStride, long dstStride)
|
||||||
|
{
|
||||||
|
RENAME(yuvPlanartouyvy)(ysrc, usrc, vsrc, dst, width, height, lumStride, chromStride, dstStride, 1);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Width should be a multiple of 16.
|
* Width should be a multiple of 16.
|
||||||
*/
|
*/
|
||||||
@ -2707,19 +2717,19 @@ static inline void RENAME(yvu9_to_yuy2)(const uint8_t *src1, const uint8_t *src2
|
|||||||
|
|
||||||
static inline void RENAME(rgb2rgb_init)(void){
|
static inline void RENAME(rgb2rgb_init)(void){
|
||||||
rgb15to16 = RENAME(rgb15to16);
|
rgb15to16 = RENAME(rgb15to16);
|
||||||
rgb15to24 = RENAME(rgb15to24);
|
rgb15tobgr24 = RENAME(rgb15tobgr24);
|
||||||
rgb15to32 = RENAME(rgb15to32);
|
rgb15to32 = RENAME(rgb15to32);
|
||||||
rgb16to24 = RENAME(rgb16to24);
|
rgb16tobgr24 = RENAME(rgb16tobgr24);
|
||||||
rgb16to32 = RENAME(rgb16to32);
|
rgb16to32 = RENAME(rgb16to32);
|
||||||
rgb16to15 = RENAME(rgb16to15);
|
rgb16to15 = RENAME(rgb16to15);
|
||||||
rgb24to16 = RENAME(rgb24to16);
|
rgb24tobgr16 = RENAME(rgb24tobgr16);
|
||||||
rgb24to15 = RENAME(rgb24to15);
|
rgb24tobgr15 = RENAME(rgb24tobgr15);
|
||||||
rgb24to32 = RENAME(rgb24to32);
|
rgb24tobgr32 = RENAME(rgb24tobgr32);
|
||||||
rgb32to16 = RENAME(rgb32to16);
|
rgb32to16 = RENAME(rgb32to16);
|
||||||
rgb32to15 = RENAME(rgb32to15);
|
rgb32to15 = RENAME(rgb32to15);
|
||||||
rgb32to24 = RENAME(rgb32to24);
|
rgb32tobgr24 = RENAME(rgb32tobgr24);
|
||||||
rgb24tobgr15 = RENAME(rgb24tobgr15);
|
rgb24to15 = RENAME(rgb24to15);
|
||||||
rgb24tobgr16 = RENAME(rgb24tobgr16);
|
rgb24to16 = RENAME(rgb24to16);
|
||||||
rgb24tobgr24 = RENAME(rgb24tobgr24);
|
rgb24tobgr24 = RENAME(rgb24tobgr24);
|
||||||
rgb32tobgr32 = RENAME(rgb32tobgr32);
|
rgb32tobgr32 = RENAME(rgb32tobgr32);
|
||||||
rgb32tobgr16 = RENAME(rgb32tobgr16);
|
rgb32tobgr16 = RENAME(rgb32tobgr16);
|
||||||
@ -2727,6 +2737,7 @@ static inline void RENAME(rgb2rgb_init)(void){
|
|||||||
yv12toyuy2 = RENAME(yv12toyuy2);
|
yv12toyuy2 = RENAME(yv12toyuy2);
|
||||||
yv12touyvy = RENAME(yv12touyvy);
|
yv12touyvy = RENAME(yv12touyvy);
|
||||||
yuv422ptoyuy2 = RENAME(yuv422ptoyuy2);
|
yuv422ptoyuy2 = RENAME(yuv422ptoyuy2);
|
||||||
|
yuv422ptouyvy = RENAME(yuv422ptouyvy);
|
||||||
yuy2toyv12 = RENAME(yuy2toyv12);
|
yuy2toyv12 = RENAME(yuy2toyv12);
|
||||||
// uyvytoyv12 = RENAME(uyvytoyv12);
|
// uyvytoyv12 = RENAME(uyvytoyv12);
|
||||||
// yvu9toyv12 = RENAME(yvu9toyv12);
|
// yvu9toyv12 = RENAME(yvu9toyv12);
|
||||||
|
@ -139,6 +139,7 @@ static int doTest(uint8_t *ref[3], int refStride[3], int w, int h, int srcFormat
|
|||||||
sws_format_name(dstFormat), dstW, dstH,
|
sws_format_name(dstFormat), dstW, dstH,
|
||||||
flags,
|
flags,
|
||||||
ssdY, ssdU, ssdV);
|
ssdY, ssdU, ssdV);
|
||||||
|
fflush(stdout);
|
||||||
}
|
}
|
||||||
|
|
||||||
end:
|
end:
|
||||||
@ -170,6 +171,7 @@ static void selfTest(uint8_t *src[3], int stride[3], int w, int h){
|
|||||||
printf("%s -> %s\n",
|
printf("%s -> %s\n",
|
||||||
sws_format_name(srcFormat),
|
sws_format_name(srcFormat),
|
||||||
sws_format_name(dstFormat));
|
sws_format_name(dstFormat));
|
||||||
|
fflush(stdout);
|
||||||
|
|
||||||
srcW= w;
|
srcW= w;
|
||||||
srcH= h;
|
srcH= h;
|
||||||
|
@ -22,7 +22,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
supported Input formats: YV12, I420/IYUV, YUY2, UYVY, BGR32, BGR24, BGR16, BGR15, RGB32, RGB24, Y8/Y800, YVU9/IF09, PAL8
|
supported Input formats: YV12, I420/IYUV, YUY2, UYVY, BGR32, BGR32_1, BGR24, BGR16, BGR15, RGB32, RGB32_1, RGB24, Y8/Y800, YVU9/IF09, PAL8
|
||||||
supported output formats: YV12, I420/IYUV, YUY2, UYVY, {BGR,RGB}{1,4,8,15,16,24,32}, Y8/Y800, YVU9/IF09
|
supported output formats: YV12, I420/IYUV, YUY2, UYVY, {BGR,RGB}{1,4,8,15,16,24,32}, Y8/Y800, YVU9/IF09
|
||||||
{BGR,RGB}{1,4,8,15,16} support dithering
|
{BGR,RGB}{1,4,8,15,16} support dithering
|
||||||
|
|
||||||
@ -54,6 +54,7 @@ untested special converters
|
|||||||
BGR24 -> YV12
|
BGR24 -> YV12
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define _SVID_SOURCE //needed for MAP_ANONYMOUS
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
@ -104,10 +105,12 @@ unsigned swscale_version(void)
|
|||||||
|| (x)==PIX_FMT_YUYV422 \
|
|| (x)==PIX_FMT_YUYV422 \
|
||||||
|| (x)==PIX_FMT_UYVY422 \
|
|| (x)==PIX_FMT_UYVY422 \
|
||||||
|| (x)==PIX_FMT_RGB32 \
|
|| (x)==PIX_FMT_RGB32 \
|
||||||
|
|| (x)==PIX_FMT_RGB32_1 \
|
||||||
|| (x)==PIX_FMT_BGR24 \
|
|| (x)==PIX_FMT_BGR24 \
|
||||||
|| (x)==PIX_FMT_BGR565 \
|
|| (x)==PIX_FMT_BGR565 \
|
||||||
|| (x)==PIX_FMT_BGR555 \
|
|| (x)==PIX_FMT_BGR555 \
|
||||||
|| (x)==PIX_FMT_BGR32 \
|
|| (x)==PIX_FMT_BGR32 \
|
||||||
|
|| (x)==PIX_FMT_BGR32_1 \
|
||||||
|| (x)==PIX_FMT_RGB24 \
|
|| (x)==PIX_FMT_RGB24 \
|
||||||
|| (x)==PIX_FMT_RGB565 \
|
|| (x)==PIX_FMT_RGB565 \
|
||||||
|| (x)==PIX_FMT_RGB555 \
|
|| (x)==PIX_FMT_RGB555 \
|
||||||
@ -149,7 +152,7 @@ unsigned swscale_version(void)
|
|||||||
|| isBGR(x) \
|
|| isBGR(x) \
|
||||||
)
|
)
|
||||||
|
|
||||||
#define RGB2YUV_SHIFT 16
|
#define RGB2YUV_SHIFT 15
|
||||||
#define BY ((int)( 0.098*(1<<RGB2YUV_SHIFT)+0.5))
|
#define BY ((int)( 0.098*(1<<RGB2YUV_SHIFT)+0.5))
|
||||||
#define BV ((int)(-0.071*(1<<RGB2YUV_SHIFT)+0.5))
|
#define BV ((int)(-0.071*(1<<RGB2YUV_SHIFT)+0.5))
|
||||||
#define BU ((int)( 0.439*(1<<RGB2YUV_SHIFT)+0.5))
|
#define BU ((int)( 0.439*(1<<RGB2YUV_SHIFT)+0.5))
|
||||||
@ -162,6 +165,17 @@ unsigned swscale_version(void)
|
|||||||
|
|
||||||
extern const int32_t Inverse_Table_6_9[8][4];
|
extern const int32_t Inverse_Table_6_9[8][4];
|
||||||
|
|
||||||
|
static const double rgb2yuv_table[8][9]={
|
||||||
|
{0.7152, 0.0722, 0.2126, -0.386, 0.5, -0.115, -0.454, -0.046, 0.5},
|
||||||
|
{0.7152, 0.0722, 0.2126, -0.386, 0.5, -0.115, -0.454, -0.046, 0.5},
|
||||||
|
{0.587 , 0.114 , 0.299 , -0.331, 0.5, -0.169, -0.419, -0.081, 0.5},
|
||||||
|
{0.587 , 0.114 , 0.299 , -0.331, 0.5, -0.169, -0.419, -0.081, 0.5},
|
||||||
|
{0.59 , 0.11 , 0.30 , -0.331, 0.5, -0.169, -0.421, -0.079, 0.5}, //FCC
|
||||||
|
{0.587 , 0.114 , 0.299 , -0.331, 0.5, -0.169, -0.419, -0.081, 0.5},
|
||||||
|
{0.587 , 0.114 , 0.299 , -0.331, 0.5, -0.169, -0.419, -0.081, 0.5}, //SMPTE 170M
|
||||||
|
{0.701 , 0.087 , 0.212 , -0.384, 0.5 -0.116, -0.445, -0.055, 0.5}, //SMPTE 240M
|
||||||
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
NOTES
|
NOTES
|
||||||
Special versions: fast Y 1:1 scaling (no interpolation in y direction)
|
Special versions: fast Y 1:1 scaling (no interpolation in y direction)
|
||||||
@ -223,6 +237,20 @@ DECLARE_ALIGNED(8, const uint64_t, ff_bgr2VCoeff) = 0x00003831D0E6F6EAULL;
|
|||||||
DECLARE_ALIGNED(8, const uint64_t, ff_bgr2YOffset) = 0x1010101010101010ULL;
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr2YOffset) = 0x1010101010101010ULL;
|
||||||
DECLARE_ALIGNED(8, const uint64_t, ff_bgr2UVOffset) = 0x8080808080808080ULL;
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr2UVOffset) = 0x8080808080808080ULL;
|
||||||
DECLARE_ALIGNED(8, const uint64_t, ff_w1111) = 0x0001000100010001ULL;
|
DECLARE_ALIGNED(8, const uint64_t, ff_w1111) = 0x0001000100010001ULL;
|
||||||
|
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr24toY1Coeff) = 0x0C88000040870C88ULL;
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr24toY2Coeff) = 0x20DE4087000020DEULL;
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_rgb24toY1Coeff) = 0x20DE0000408720DEULL;
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_rgb24toY2Coeff) = 0x0C88408700000C88ULL;
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr24toYOffset) = 0x0008400000084000ULL;
|
||||||
|
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr24toUV[2][4]) = {
|
||||||
|
{0x38380000DAC83838ULL, 0xECFFDAC80000ECFFULL, 0xF6E40000D0E3F6E4ULL, 0x3838D0E300003838ULL},
|
||||||
|
{0xECFF0000DAC8ECFFULL, 0x3838DAC800003838ULL, 0x38380000D0E33838ULL, 0xF6E4D0E30000F6E4ULL},
|
||||||
|
};
|
||||||
|
|
||||||
|
DECLARE_ALIGNED(8, const uint64_t, ff_bgr24toUVOffset)= 0x0040400000404000ULL;
|
||||||
|
|
||||||
#endif /* defined(ARCH_X86) */
|
#endif /* defined(ARCH_X86) */
|
||||||
|
|
||||||
// clipping helper table for C implementations:
|
// clipping helper table for C implementations:
|
||||||
@ -442,6 +470,31 @@ static inline void yuv2nv12XinC(int16_t *lumFilter, int16_t **lumSrc, int lumFil
|
|||||||
else if (V<0) V=0; \
|
else if (V<0) V=0; \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define YSCALE_YUV_2_GRAY16_C(type) \
|
||||||
|
for (i=0; i<(dstW>>1); i++){\
|
||||||
|
int j;\
|
||||||
|
int Y1 = 1<<18;\
|
||||||
|
int Y2 = 1<<18;\
|
||||||
|
int U = 1<<18;\
|
||||||
|
int V = 1<<18;\
|
||||||
|
type av_unused *r, *b, *g;\
|
||||||
|
const int i2= 2*i;\
|
||||||
|
\
|
||||||
|
for (j=0; j<lumFilterSize; j++)\
|
||||||
|
{\
|
||||||
|
Y1 += lumSrc[j][i2] * lumFilter[j];\
|
||||||
|
Y2 += lumSrc[j][i2+1] * lumFilter[j];\
|
||||||
|
}\
|
||||||
|
Y1>>=11;\
|
||||||
|
Y2>>=11;\
|
||||||
|
if ((Y1|Y2|U|V)&65536)\
|
||||||
|
{\
|
||||||
|
if (Y1>65535) Y1=65535; \
|
||||||
|
else if (Y1<0)Y1=0; \
|
||||||
|
if (Y2>65535) Y2=65535; \
|
||||||
|
else if (Y2<0)Y2=0; \
|
||||||
|
}
|
||||||
|
|
||||||
#define YSCALE_YUV_2_RGBX_C(type) \
|
#define YSCALE_YUV_2_RGBX_C(type) \
|
||||||
YSCALE_YUV_2_PACKEDX_C(type) \
|
YSCALE_YUV_2_PACKEDX_C(type) \
|
||||||
r = (type *)c->table_rV[V]; \
|
r = (type *)c->table_rV[V]; \
|
||||||
@ -456,6 +509,12 @@ static inline void yuv2nv12XinC(int16_t *lumFilter, int16_t **lumSrc, int lumFil
|
|||||||
int U= (uvbuf0[i ]*uvalpha1+uvbuf1[i ]*uvalpha)>>19; \
|
int U= (uvbuf0[i ]*uvalpha1+uvbuf1[i ]*uvalpha)>>19; \
|
||||||
int V= (uvbuf0[i+VOFW]*uvalpha1+uvbuf1[i+VOFW]*uvalpha)>>19; \
|
int V= (uvbuf0[i+VOFW]*uvalpha1+uvbuf1[i+VOFW]*uvalpha)>>19; \
|
||||||
|
|
||||||
|
#define YSCALE_YUV_2_GRAY16_2_C \
|
||||||
|
for (i=0; i<(dstW>>1); i++){ \
|
||||||
|
const int i2= 2*i; \
|
||||||
|
int Y1= (buf0[i2 ]*yalpha1+buf1[i2 ]*yalpha)>>11; \
|
||||||
|
int Y2= (buf0[i2+1]*yalpha1+buf1[i2+1]*yalpha)>>11; \
|
||||||
|
|
||||||
#define YSCALE_YUV_2_RGB2_C(type) \
|
#define YSCALE_YUV_2_RGB2_C(type) \
|
||||||
YSCALE_YUV_2_PACKED2_C\
|
YSCALE_YUV_2_PACKED2_C\
|
||||||
type *r, *b, *g;\
|
type *r, *b, *g;\
|
||||||
@ -471,6 +530,12 @@ static inline void yuv2nv12XinC(int16_t *lumFilter, int16_t **lumSrc, int lumFil
|
|||||||
int U= (uvbuf1[i ])>>7;\
|
int U= (uvbuf1[i ])>>7;\
|
||||||
int V= (uvbuf1[i+VOFW])>>7;\
|
int V= (uvbuf1[i+VOFW])>>7;\
|
||||||
|
|
||||||
|
#define YSCALE_YUV_2_GRAY16_1_C \
|
||||||
|
for (i=0; i<(dstW>>1); i++){\
|
||||||
|
const int i2= 2*i;\
|
||||||
|
int Y1= buf0[i2 ]<<1;\
|
||||||
|
int Y2= buf0[i2+1]<<1;\
|
||||||
|
|
||||||
#define YSCALE_YUV_2_RGB1_C(type) \
|
#define YSCALE_YUV_2_RGB1_C(type) \
|
||||||
YSCALE_YUV_2_PACKED1_C\
|
YSCALE_YUV_2_PACKED1_C\
|
||||||
type *r, *b, *g;\
|
type *r, *b, *g;\
|
||||||
@ -493,11 +558,13 @@ static inline void yuv2nv12XinC(int16_t *lumFilter, int16_t **lumSrc, int lumFil
|
|||||||
g = (type *)(c->table_gU[U] + c->table_gV[V]);\
|
g = (type *)(c->table_gU[U] + c->table_gV[V]);\
|
||||||
b = (type *)c->table_bU[U];\
|
b = (type *)c->table_bU[U];\
|
||||||
|
|
||||||
#define YSCALE_YUV_2_ANYRGB_C(func, func2)\
|
#define YSCALE_YUV_2_ANYRGB_C(func, func2, func_g16)\
|
||||||
switch(c->dstFormat)\
|
switch(c->dstFormat)\
|
||||||
{\
|
{\
|
||||||
case PIX_FMT_RGB32:\
|
case PIX_FMT_RGB32:\
|
||||||
case PIX_FMT_BGR32:\
|
case PIX_FMT_BGR32:\
|
||||||
|
case PIX_FMT_RGB32_1:\
|
||||||
|
case PIX_FMT_BGR32_1:\
|
||||||
func(uint32_t)\
|
func(uint32_t)\
|
||||||
((uint32_t*)dest)[i2+0]= r[Y1] + g[Y1] + b[Y1];\
|
((uint32_t*)dest)[i2+0]= r[Y1] + g[Y1] + b[Y1];\
|
||||||
((uint32_t*)dest)[i2+1]= r[Y2] + g[Y2] + b[Y2];\
|
((uint32_t*)dest)[i2+1]= r[Y2] + g[Y2] + b[Y2];\
|
||||||
@ -668,6 +735,22 @@ static inline void yuv2nv12XinC(int16_t *lumFilter, int16_t **lumSrc, int lumFil
|
|||||||
((uint8_t*)dest)[2*i2+3]= Y2;\
|
((uint8_t*)dest)[2*i2+3]= Y2;\
|
||||||
} \
|
} \
|
||||||
break;\
|
break;\
|
||||||
|
case PIX_FMT_GRAY16BE:\
|
||||||
|
func_g16\
|
||||||
|
((uint8_t*)dest)[2*i2+0]= Y1>>8;\
|
||||||
|
((uint8_t*)dest)[2*i2+1]= Y1;\
|
||||||
|
((uint8_t*)dest)[2*i2+2]= Y2>>8;\
|
||||||
|
((uint8_t*)dest)[2*i2+3]= Y2;\
|
||||||
|
} \
|
||||||
|
break;\
|
||||||
|
case PIX_FMT_GRAY16LE:\
|
||||||
|
func_g16\
|
||||||
|
((uint8_t*)dest)[2*i2+0]= Y1;\
|
||||||
|
((uint8_t*)dest)[2*i2+1]= Y1>>8;\
|
||||||
|
((uint8_t*)dest)[2*i2+2]= Y2;\
|
||||||
|
((uint8_t*)dest)[2*i2+3]= Y2>>8;\
|
||||||
|
} \
|
||||||
|
break;\
|
||||||
}\
|
}\
|
||||||
|
|
||||||
|
|
||||||
@ -680,6 +763,8 @@ static inline void yuv2packedXinC(SwsContext *c, int16_t *lumFilter, int16_t **l
|
|||||||
{
|
{
|
||||||
case PIX_FMT_BGR32:
|
case PIX_FMT_BGR32:
|
||||||
case PIX_FMT_RGB32:
|
case PIX_FMT_RGB32:
|
||||||
|
case PIX_FMT_BGR32_1:
|
||||||
|
case PIX_FMT_RGB32_1:
|
||||||
YSCALE_YUV_2_RGBX_C(uint32_t)
|
YSCALE_YUV_2_RGBX_C(uint32_t)
|
||||||
((uint32_t*)dest)[i2+0]= r[Y1] + g[Y1] + b[Y1];
|
((uint32_t*)dest)[i2+0]= r[Y1] + g[Y1] + b[Y1];
|
||||||
((uint32_t*)dest)[i2+1]= r[Y2] + g[Y2] + b[Y2];
|
((uint32_t*)dest)[i2+1]= r[Y2] + g[Y2] + b[Y2];
|
||||||
@ -819,6 +904,22 @@ static inline void yuv2packedXinC(SwsContext *c, int16_t *lumFilter, int16_t **l
|
|||||||
((uint8_t*)dest)[2*i2+3]= Y2;
|
((uint8_t*)dest)[2*i2+3]= Y2;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case PIX_FMT_GRAY16BE:
|
||||||
|
YSCALE_YUV_2_GRAY16_C(void)
|
||||||
|
((uint8_t*)dest)[2*i2+0]= Y1>>8;
|
||||||
|
((uint8_t*)dest)[2*i2+1]= Y1;
|
||||||
|
((uint8_t*)dest)[2*i2+2]= Y2>>8;
|
||||||
|
((uint8_t*)dest)[2*i2+3]= Y2;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case PIX_FMT_GRAY16LE:
|
||||||
|
YSCALE_YUV_2_GRAY16_C(void)
|
||||||
|
((uint8_t*)dest)[2*i2+0]= Y1;
|
||||||
|
((uint8_t*)dest)[2*i2+1]= Y1>>8;
|
||||||
|
((uint8_t*)dest)[2*i2+2]= Y2;
|
||||||
|
((uint8_t*)dest)[2*i2+3]= Y2>>8;
|
||||||
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1217,7 +1318,7 @@ static inline int initFilter(int16_t **outFilter, int16_t **filterPos, int *outF
|
|||||||
filterSize= (minFilterSize +(filterAlign-1)) & (~(filterAlign-1));
|
filterSize= (minFilterSize +(filterAlign-1)) & (~(filterAlign-1));
|
||||||
assert(filterSize > 0);
|
assert(filterSize > 0);
|
||||||
filter= av_malloc(filterSize*dstW*sizeof(double));
|
filter= av_malloc(filterSize*dstW*sizeof(double));
|
||||||
if (filterSize >= MAX_FILTER_SIZE || !filter)
|
if (filterSize >= MAX_FILTER_SIZE*16/((flags&SWS_ACCURATE_RND) ? APCK_SIZE : 16) || !filter)
|
||||||
goto error;
|
goto error;
|
||||||
*outFilterSize= filterSize;
|
*outFilterSize= filterSize;
|
||||||
|
|
||||||
@ -1573,7 +1674,25 @@ static int PlanarToUyvyWrapper(SwsContext *c, uint8_t* src[], int srcStride[], i
|
|||||||
return srcSliceH;
|
return srcSliceH;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* {RGB,BGR}{15,16,24,32} -> {RGB,BGR}{15,16,24,32} */
|
static int YUV422PToYuy2Wrapper(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
||||||
|
int srcSliceH, uint8_t* dstParam[], int dstStride[]){
|
||||||
|
uint8_t *dst=dstParam[0] + dstStride[0]*srcSliceY;
|
||||||
|
|
||||||
|
yuv422ptoyuy2(src[0],src[1],src[2],dst,c->srcW,srcSliceH,srcStride[0],srcStride[1],dstStride[0]);
|
||||||
|
|
||||||
|
return srcSliceH;
|
||||||
|
}
|
||||||
|
|
||||||
|
static int YUV422PToUyvyWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
||||||
|
int srcSliceH, uint8_t* dstParam[], int dstStride[]){
|
||||||
|
uint8_t *dst=dstParam[0] + dstStride[0]*srcSliceY;
|
||||||
|
|
||||||
|
yuv422ptouyvy(src[0],src[1],src[2],dst,c->srcW,srcSliceH,srcStride[0],srcStride[1],dstStride[0]);
|
||||||
|
|
||||||
|
return srcSliceH;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* {RGB,BGR}{15,16,24,32,32_1} -> {RGB,BGR}{15,16,24,32} */
|
||||||
static int rgb2rgbWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
static int rgb2rgbWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
||||||
int srcSliceH, uint8_t* dst[], int dstStride[]){
|
int srcSliceH, uint8_t* dst[], int dstStride[]){
|
||||||
const int srcFormat= c->srcFormat;
|
const int srcFormat= c->srcFormat;
|
||||||
@ -1632,12 +1751,15 @@ static int rgb2rgbWrapper(SwsContext *c, uint8_t* src[], int srcStride[], int sr
|
|||||||
|
|
||||||
if(conv)
|
if(conv)
|
||||||
{
|
{
|
||||||
|
uint8_t *srcPtr= src[0];
|
||||||
|
if(srcFormat == PIX_FMT_RGB32_1 || srcFormat == PIX_FMT_BGR32_1)
|
||||||
|
srcPtr += ALT32_CORR;
|
||||||
|
|
||||||
if (dstStride[0]*srcBpp == srcStride[0]*dstBpp && srcStride[0] > 0)
|
if (dstStride[0]*srcBpp == srcStride[0]*dstBpp && srcStride[0] > 0)
|
||||||
conv(src[0], dst[0] + dstStride[0]*srcSliceY, srcSliceH*srcStride[0]);
|
conv(srcPtr, dst[0] + dstStride[0]*srcSliceY, srcSliceH*srcStride[0]);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
uint8_t *srcPtr= src[0];
|
|
||||||
uint8_t *dstPtr= dst[0] + dstStride[0]*srcSliceY;
|
uint8_t *dstPtr= dst[0] + dstStride[0]*srcSliceY;
|
||||||
|
|
||||||
for (i=0; i<srcSliceH; i++)
|
for (i=0; i<srcSliceH; i++)
|
||||||
@ -1887,7 +2009,6 @@ int sws_setColorspaceDetails(SwsContext *c, const int inv_table[4], int srcRange
|
|||||||
int64_t cy = 1<<16;
|
int64_t cy = 1<<16;
|
||||||
int64_t oy = 0;
|
int64_t oy = 0;
|
||||||
|
|
||||||
if (isYUV(c->dstFormat) || isGray(c->dstFormat)) return -1;
|
|
||||||
memcpy(c->srcColorspaceTable, inv_table, sizeof(int)*4);
|
memcpy(c->srcColorspaceTable, inv_table, sizeof(int)*4);
|
||||||
memcpy(c->dstColorspaceTable, table, sizeof(int)*4);
|
memcpy(c->dstColorspaceTable, table, sizeof(int)*4);
|
||||||
|
|
||||||
@ -1896,6 +2017,7 @@ int sws_setColorspaceDetails(SwsContext *c, const int inv_table[4], int srcRange
|
|||||||
c->saturation= saturation;
|
c->saturation= saturation;
|
||||||
c->srcRange = srcRange;
|
c->srcRange = srcRange;
|
||||||
c->dstRange = dstRange;
|
c->dstRange = dstRange;
|
||||||
|
if (isYUV(c->dstFormat) || isGray(c->dstFormat)) return 0;
|
||||||
|
|
||||||
c->uOffset= 0x0400040004000400LL;
|
c->uOffset= 0x0400040004000400LL;
|
||||||
c->vOffset= 0x0400040004000400LL;
|
c->vOffset= 0x0400040004000400LL;
|
||||||
@ -2093,7 +2215,8 @@ SwsContext *sws_getContext(int srcW, int srcH, int srcFormat, int dstW, int dstH
|
|||||||
if ((isBGR(srcFormat) || isRGB(srcFormat)) && !(flags&SWS_FULL_CHR_H_INP)
|
if ((isBGR(srcFormat) || isRGB(srcFormat)) && !(flags&SWS_FULL_CHR_H_INP)
|
||||||
&& srcFormat!=PIX_FMT_RGB8 && srcFormat!=PIX_FMT_BGR8
|
&& srcFormat!=PIX_FMT_RGB8 && srcFormat!=PIX_FMT_BGR8
|
||||||
&& srcFormat!=PIX_FMT_RGB4 && srcFormat!=PIX_FMT_BGR4
|
&& srcFormat!=PIX_FMT_RGB4 && srcFormat!=PIX_FMT_BGR4
|
||||||
&& srcFormat!=PIX_FMT_RGB4_BYTE && srcFormat!=PIX_FMT_BGR4_BYTE)
|
&& srcFormat!=PIX_FMT_RGB4_BYTE && srcFormat!=PIX_FMT_BGR4_BYTE
|
||||||
|
&& ((dstW>>c->chrDstHSubSample) <= (srcW>>1) || (flags&(SWS_FAST_BILINEAR|SWS_POINT))))
|
||||||
c->chrSrcHSubSample=1;
|
c->chrSrcHSubSample=1;
|
||||||
|
|
||||||
if (param){
|
if (param){
|
||||||
@ -2116,7 +2239,7 @@ SwsContext *sws_getContext(int srcW, int srcH, int srcFormat, int dstW, int dstH
|
|||||||
sws_setColorspaceDetails(c, Inverse_Table_6_9[SWS_CS_DEFAULT], srcRange, Inverse_Table_6_9[SWS_CS_DEFAULT] /* FIXME*/, dstRange, 0, 1<<16, 1<<16);
|
sws_setColorspaceDetails(c, Inverse_Table_6_9[SWS_CS_DEFAULT], srcRange, Inverse_Table_6_9[SWS_CS_DEFAULT] /* FIXME*/, dstRange, 0, 1<<16, 1<<16);
|
||||||
|
|
||||||
/* unscaled special Cases */
|
/* unscaled special Cases */
|
||||||
if (unscaled && !usesHFilter && !usesVFilter)
|
if (unscaled && !usesHFilter && !usesVFilter && (srcRange == dstRange || isBGR(dstFormat) || isRGB(dstFormat)))
|
||||||
{
|
{
|
||||||
/* yv12_to_nv12 */
|
/* yv12_to_nv12 */
|
||||||
if (srcFormat == PIX_FMT_YUV420P && (dstFormat == PIX_FMT_NV12 || dstFormat == PIX_FMT_NV21))
|
if (srcFormat == PIX_FMT_YUV420P && (dstFormat == PIX_FMT_NV12 || dstFormat == PIX_FMT_NV21))
|
||||||
@ -2150,36 +2273,38 @@ SwsContext *sws_getContext(int srcW, int srcH, int srcFormat, int dstW, int dstH
|
|||||||
&& srcFormat != PIX_FMT_BGR4_BYTE && dstFormat != PIX_FMT_BGR4_BYTE
|
&& srcFormat != PIX_FMT_BGR4_BYTE && dstFormat != PIX_FMT_BGR4_BYTE
|
||||||
&& srcFormat != PIX_FMT_RGB4_BYTE && dstFormat != PIX_FMT_RGB4_BYTE
|
&& srcFormat != PIX_FMT_RGB4_BYTE && dstFormat != PIX_FMT_RGB4_BYTE
|
||||||
&& srcFormat != PIX_FMT_MONOBLACK && dstFormat != PIX_FMT_MONOBLACK
|
&& srcFormat != PIX_FMT_MONOBLACK && dstFormat != PIX_FMT_MONOBLACK
|
||||||
&& !needsDither)
|
&& dstFormat != PIX_FMT_RGB32_1
|
||||||
|
&& dstFormat != PIX_FMT_BGR32_1
|
||||||
|
&& (!needsDither || (c->flags&(SWS_FAST_BILINEAR|SWS_POINT))))
|
||||||
c->swScale= rgb2rgbWrapper;
|
c->swScale= rgb2rgbWrapper;
|
||||||
|
|
||||||
|
if (srcFormat == PIX_FMT_YUV422P)
|
||||||
|
{
|
||||||
|
if (dstFormat == PIX_FMT_YUYV422)
|
||||||
|
c->swScale= YUV422PToYuy2Wrapper;
|
||||||
|
else if (dstFormat == PIX_FMT_UYVY422)
|
||||||
|
c->swScale= YUV422PToUyvyWrapper;
|
||||||
|
}
|
||||||
|
|
||||||
/* LQ converters if -sws 0 or -sws 4*/
|
/* LQ converters if -sws 0 or -sws 4*/
|
||||||
if (c->flags&(SWS_FAST_BILINEAR|SWS_POINT)){
|
if (c->flags&(SWS_FAST_BILINEAR|SWS_POINT)){
|
||||||
/* rgb/bgr -> rgb/bgr (dither needed forms) */
|
|
||||||
if ( (isBGR(srcFormat) || isRGB(srcFormat))
|
|
||||||
&& (isBGR(dstFormat) || isRGB(dstFormat))
|
|
||||||
&& needsDither)
|
|
||||||
c->swScale= rgb2rgbWrapper;
|
|
||||||
|
|
||||||
/* yv12_to_yuy2 */
|
/* yv12_to_yuy2 */
|
||||||
if (srcFormat == PIX_FMT_YUV420P &&
|
if (srcFormat == PIX_FMT_YUV420P)
|
||||||
(dstFormat == PIX_FMT_YUYV422 || dstFormat == PIX_FMT_UYVY422))
|
|
||||||
{
|
{
|
||||||
if (dstFormat == PIX_FMT_YUYV422)
|
if (dstFormat == PIX_FMT_YUYV422)
|
||||||
c->swScale= PlanarToYuy2Wrapper;
|
c->swScale= PlanarToYuy2Wrapper;
|
||||||
else
|
else if (dstFormat == PIX_FMT_UYVY422)
|
||||||
c->swScale= PlanarToUyvyWrapper;
|
c->swScale= PlanarToUyvyWrapper;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef COMPILE_ALTIVEC
|
#ifdef COMPILE_ALTIVEC
|
||||||
if ((c->flags & SWS_CPU_CAPS_ALTIVEC) &&
|
if ((c->flags & SWS_CPU_CAPS_ALTIVEC) &&
|
||||||
((srcFormat == PIX_FMT_YUV420P &&
|
srcFormat == PIX_FMT_YUV420P) {
|
||||||
(dstFormat == PIX_FMT_YUYV422 || dstFormat == PIX_FMT_UYVY422)))) {
|
|
||||||
// unscaled YV12 -> packed YUV, we want speed
|
// unscaled YV12 -> packed YUV, we want speed
|
||||||
if (dstFormat == PIX_FMT_YUYV422)
|
if (dstFormat == PIX_FMT_YUYV422)
|
||||||
c->swScale= yv12toyuy2_unscaled_altivec;
|
c->swScale= yv12toyuy2_unscaled_altivec;
|
||||||
else
|
else if (dstFormat == PIX_FMT_UYVY422)
|
||||||
c->swScale= yv12touyvy_unscaled_altivec;
|
c->swScale= yv12touyvy_unscaled_altivec;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -2507,6 +2632,12 @@ int sws_scale(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
|||||||
int i;
|
int i;
|
||||||
uint8_t* src2[4]= {src[0], src[1], src[2]};
|
uint8_t* src2[4]= {src[0], src[1], src[2]};
|
||||||
uint32_t pal[256];
|
uint32_t pal[256];
|
||||||
|
int use_pal= c->srcFormat == PIX_FMT_PAL8
|
||||||
|
|| c->srcFormat == PIX_FMT_BGR4_BYTE
|
||||||
|
|| c->srcFormat == PIX_FMT_RGB4_BYTE
|
||||||
|
|| c->srcFormat == PIX_FMT_BGR8
|
||||||
|
|| c->srcFormat == PIX_FMT_RGB8;
|
||||||
|
|
||||||
if (c->sliceDir == 0 && srcSliceY != 0 && srcSliceY + srcSliceH != c->srcH) {
|
if (c->sliceDir == 0 && srcSliceY != 0 && srcSliceY + srcSliceH != c->srcH) {
|
||||||
av_log(c, AV_LOG_ERROR, "Slices start in the middle!\n");
|
av_log(c, AV_LOG_ERROR, "Slices start in the middle!\n");
|
||||||
return 0;
|
return 0;
|
||||||
@ -2515,15 +2646,34 @@ int sws_scale(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
|||||||
if (srcSliceY == 0) c->sliceDir = 1; else c->sliceDir = -1;
|
if (srcSliceY == 0) c->sliceDir = 1; else c->sliceDir = -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (c->srcFormat == PIX_FMT_PAL8){
|
if (use_pal){
|
||||||
for (i=0; i<256; i++){
|
for (i=0; i<256; i++){
|
||||||
int p= ((uint32_t*)(src[1]))[i];
|
int p, r, g, b,y,u,v;
|
||||||
int r= (p>>16)&0xFF;
|
if(c->srcFormat == PIX_FMT_PAL8){
|
||||||
int g= (p>> 8)&0xFF;
|
p=((uint32_t*)(src[1]))[i];
|
||||||
int b= p &0xFF;
|
r= (p>>16)&0xFF;
|
||||||
int y= av_clip_uint8(((RY*r + GY*g + BY*b)>>RGB2YUV_SHIFT) + 16 );
|
g= (p>> 8)&0xFF;
|
||||||
int u= av_clip_uint8(((RU*r + GU*g + BU*b)>>RGB2YUV_SHIFT) + 128);
|
b= p &0xFF;
|
||||||
int v= av_clip_uint8(((RV*r + GV*g + BV*b)>>RGB2YUV_SHIFT) + 128);
|
}else if(c->srcFormat == PIX_FMT_RGB8){
|
||||||
|
r= (i>>5 )*36;
|
||||||
|
g= ((i>>2)&7)*36;
|
||||||
|
b= (i&3 )*85;
|
||||||
|
}else if(c->srcFormat == PIX_FMT_BGR8){
|
||||||
|
b= (i>>6 )*85;
|
||||||
|
g= ((i>>3)&7)*36;
|
||||||
|
r= (i&7 )*36;
|
||||||
|
}else if(c->srcFormat == PIX_FMT_RGB4_BYTE){
|
||||||
|
r= (i>>3 )*255;
|
||||||
|
g= ((i>>1)&3)*85;
|
||||||
|
b= (i&1 )*255;
|
||||||
|
}else if(c->srcFormat == PIX_FMT_BGR4_BYTE){
|
||||||
|
b= (i>>3 )*255;
|
||||||
|
g= ((i>>1)&3)*85;
|
||||||
|
r= (i&1 )*255;
|
||||||
|
}
|
||||||
|
y= av_clip_uint8((RY*r + GY*g + BY*b + ( 33<<(RGB2YUV_SHIFT-1)))>>RGB2YUV_SHIFT);
|
||||||
|
u= av_clip_uint8((RU*r + GU*g + BU*b + (257<<(RGB2YUV_SHIFT-1)))>>RGB2YUV_SHIFT);
|
||||||
|
v= av_clip_uint8((RV*r + GV*g + BV*b + (257<<(RGB2YUV_SHIFT-1)))>>RGB2YUV_SHIFT);
|
||||||
pal[i]= y + (u<<8) + (v<<16);
|
pal[i]= y + (u<<8) + (v<<16);
|
||||||
}
|
}
|
||||||
src2[1]= (uint8_t*)pal;
|
src2[1]= (uint8_t*)pal;
|
||||||
@ -2544,7 +2694,7 @@ int sws_scale(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
|
|||||||
int dstStride2[4]= {-dstStride[0], -dstStride[1], -dstStride[2]};
|
int dstStride2[4]= {-dstStride[0], -dstStride[1], -dstStride[2]};
|
||||||
|
|
||||||
src2[0] += (srcSliceH-1)*srcStride[0];
|
src2[0] += (srcSliceH-1)*srcStride[0];
|
||||||
if (c->srcFormat != PIX_FMT_PAL8)
|
if (!use_pal)
|
||||||
src2[1] += ((srcSliceH>>c->chrSrcVSubSample)-1)*srcStride[1];
|
src2[1] += ((srcSliceH>>c->chrSrcVSubSample)-1)*srcStride[1];
|
||||||
src2[2] += ((srcSliceH>>c->chrSrcVSubSample)-1)*srcStride[2];
|
src2[2] += ((srcSliceH>>c->chrSrcVSubSample)-1)*srcStride[2];
|
||||||
|
|
||||||
|
@ -29,11 +29,29 @@
|
|||||||
|
|
||||||
#include "libavutil/avutil.h"
|
#include "libavutil/avutil.h"
|
||||||
|
|
||||||
|
#define STR(s) AV_TOSTRING(s) //AV_STRINGIFY is too long
|
||||||
|
|
||||||
#define MAX_FILTER_SIZE 256
|
#define MAX_FILTER_SIZE 256
|
||||||
|
|
||||||
#define VOFW 2048
|
#define VOFW 2048
|
||||||
#define VOF (VOFW*2)
|
#define VOF (VOFW*2)
|
||||||
|
|
||||||
|
#ifdef WORDS_BIGENDIAN
|
||||||
|
#define ALT32_CORR (-1)
|
||||||
|
#else
|
||||||
|
#define ALT32_CORR 1
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef ARCH_X86_64
|
||||||
|
# define APCK_PTR2 8
|
||||||
|
# define APCK_COEF 16
|
||||||
|
# define APCK_SIZE 24
|
||||||
|
#else
|
||||||
|
# define APCK_PTR2 4
|
||||||
|
# define APCK_COEF 8
|
||||||
|
# define APCK_SIZE 16
|
||||||
|
#endif
|
||||||
|
|
||||||
typedef int (*SwsFunc)(struct SwsContext *context, uint8_t* src[], int srcStride[], int srcSliceY,
|
typedef int (*SwsFunc)(struct SwsContext *context, uint8_t* src[], int srcStride[], int srcSliceY,
|
||||||
int srcSliceH, uint8_t* dst[], int dstStride[]);
|
int srcSliceH, uint8_t* dst[], int dstStride[]);
|
||||||
|
|
||||||
@ -221,7 +239,8 @@ const char *sws_format_name(int format);
|
|||||||
|| (x)==PIX_FMT_GRAY16LE \
|
|| (x)==PIX_FMT_GRAY16LE \
|
||||||
)
|
)
|
||||||
#define isRGB(x) ( \
|
#define isRGB(x) ( \
|
||||||
(x)==PIX_FMT_BGR32 \
|
(x)==PIX_FMT_RGB32 \
|
||||||
|
|| (x)==PIX_FMT_RGB32_1 \
|
||||||
|| (x)==PIX_FMT_RGB24 \
|
|| (x)==PIX_FMT_RGB24 \
|
||||||
|| (x)==PIX_FMT_RGB565 \
|
|| (x)==PIX_FMT_RGB565 \
|
||||||
|| (x)==PIX_FMT_RGB555 \
|
|| (x)==PIX_FMT_RGB555 \
|
||||||
@ -231,7 +250,8 @@ const char *sws_format_name(int format);
|
|||||||
|| (x)==PIX_FMT_MONOBLACK \
|
|| (x)==PIX_FMT_MONOBLACK \
|
||||||
)
|
)
|
||||||
#define isBGR(x) ( \
|
#define isBGR(x) ( \
|
||||||
(x)==PIX_FMT_RGB32 \
|
(x)==PIX_FMT_BGR32 \
|
||||||
|
|| (x)==PIX_FMT_BGR32_1 \
|
||||||
|| (x)==PIX_FMT_BGR24 \
|
|| (x)==PIX_FMT_BGR24 \
|
||||||
|| (x)==PIX_FMT_BGR565 \
|
|| (x)==PIX_FMT_BGR565 \
|
||||||
|| (x)==PIX_FMT_BGR555 \
|
|| (x)==PIX_FMT_BGR555 \
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -600,16 +600,16 @@ SwsFunc yuv2rgb_get_func_ptr (SwsContext *c)
|
|||||||
switch(c->dstFormat){
|
switch(c->dstFormat){
|
||||||
case PIX_FMT_RGB32: return yuv420_rgb32_MMX2;
|
case PIX_FMT_RGB32: return yuv420_rgb32_MMX2;
|
||||||
case PIX_FMT_BGR24: return yuv420_rgb24_MMX2;
|
case PIX_FMT_BGR24: return yuv420_rgb24_MMX2;
|
||||||
case PIX_FMT_BGR565: return yuv420_rgb16_MMX2;
|
case PIX_FMT_RGB565: return yuv420_rgb16_MMX2;
|
||||||
case PIX_FMT_BGR555: return yuv420_rgb15_MMX2;
|
case PIX_FMT_RGB555: return yuv420_rgb15_MMX2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (c->flags & SWS_CPU_CAPS_MMX){
|
if (c->flags & SWS_CPU_CAPS_MMX){
|
||||||
switch(c->dstFormat){
|
switch(c->dstFormat){
|
||||||
case PIX_FMT_RGB32: return yuv420_rgb32_MMX;
|
case PIX_FMT_RGB32: return yuv420_rgb32_MMX;
|
||||||
case PIX_FMT_BGR24: return yuv420_rgb24_MMX;
|
case PIX_FMT_BGR24: return yuv420_rgb24_MMX;
|
||||||
case PIX_FMT_BGR565: return yuv420_rgb16_MMX;
|
case PIX_FMT_RGB565: return yuv420_rgb16_MMX;
|
||||||
case PIX_FMT_BGR555: return yuv420_rgb15_MMX;
|
case PIX_FMT_RGB555: return yuv420_rgb15_MMX;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -644,6 +644,8 @@ SwsFunc yuv2rgb_get_func_ptr (SwsContext *c)
|
|||||||
av_log(c, AV_LOG_WARNING, "No accelerated colorspace conversion found.\n");
|
av_log(c, AV_LOG_WARNING, "No accelerated colorspace conversion found.\n");
|
||||||
|
|
||||||
switch(c->dstFormat){
|
switch(c->dstFormat){
|
||||||
|
case PIX_FMT_BGR32_1:
|
||||||
|
case PIX_FMT_RGB32_1:
|
||||||
case PIX_FMT_BGR32:
|
case PIX_FMT_BGR32:
|
||||||
case PIX_FMT_RGB32: return yuv2rgb_c_32;
|
case PIX_FMT_RGB32: return yuv2rgb_c_32;
|
||||||
case PIX_FMT_RGB24: return yuv2rgb_c_24_rgb;
|
case PIX_FMT_RGB24: return yuv2rgb_c_24_rgb;
|
||||||
@ -675,9 +677,17 @@ static int div_round (int dividend, int divisor)
|
|||||||
|
|
||||||
int yuv2rgb_c_init_tables (SwsContext *c, const int inv_table[4], int fullRange, int brightness, int contrast, int saturation)
|
int yuv2rgb_c_init_tables (SwsContext *c, const int inv_table[4], int fullRange, int brightness, int contrast, int saturation)
|
||||||
{
|
{
|
||||||
const int isRgb = isBGR(c->dstFormat);
|
const int isRgb = c->dstFormat==PIX_FMT_RGB32
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB32_1
|
||||||
|
|| c->dstFormat==PIX_FMT_BGR24
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB565
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB555
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB8
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB4
|
||||||
|
|| c->dstFormat==PIX_FMT_RGB4_BYTE
|
||||||
|
|| c->dstFormat==PIX_FMT_MONOBLACK;
|
||||||
const int bpp = fmt_depth(c->dstFormat);
|
const int bpp = fmt_depth(c->dstFormat);
|
||||||
int i;
|
int i, base;
|
||||||
uint8_t table_Y[1024];
|
uint8_t table_Y[1024];
|
||||||
uint32_t *table_32 = 0;
|
uint32_t *table_32 = 0;
|
||||||
uint16_t *table_16 = 0;
|
uint16_t *table_16 = 0;
|
||||||
@ -726,6 +736,7 @@ int yuv2rgb_c_init_tables (SwsContext *c, const int inv_table[4], int fullRange,
|
|||||||
switch (bpp) {
|
switch (bpp) {
|
||||||
case 32:
|
case 32:
|
||||||
table_start= table_32 = av_malloc ((197 + 2*682 + 256 + 132) * sizeof (uint32_t));
|
table_start= table_32 = av_malloc ((197 + 2*682 + 256 + 132) * sizeof (uint32_t));
|
||||||
|
base= (c->dstFormat == PIX_FMT_RGB32_1 || c->dstFormat == PIX_FMT_BGR32_1) ? 8 : 0;
|
||||||
|
|
||||||
entry_size = sizeof (uint32_t);
|
entry_size = sizeof (uint32_t);
|
||||||
table_r = table_32 + 197;
|
table_r = table_32 + 197;
|
||||||
@ -733,11 +744,11 @@ int yuv2rgb_c_init_tables (SwsContext *c, const int inv_table[4], int fullRange,
|
|||||||
table_g = table_32 + 197 + 2*682;
|
table_g = table_32 + 197 + 2*682;
|
||||||
|
|
||||||
for (i = -197; i < 256+197; i++)
|
for (i = -197; i < 256+197; i++)
|
||||||
((uint32_t *)table_r)[i] = table_Y[i+384] << (isRgb ? 16 : 0);
|
((uint32_t *)table_r)[i] = table_Y[i+384] << ((isRgb ? 16 : 0) + base);
|
||||||
for (i = -132; i < 256+132; i++)
|
for (i = -132; i < 256+132; i++)
|
||||||
((uint32_t *)table_g)[i] = table_Y[i+384] << 8;
|
((uint32_t *)table_g)[i] = table_Y[i+384] << (8 + base);
|
||||||
for (i = -232; i < 256+232; i++)
|
for (i = -232; i < 256+232; i++)
|
||||||
((uint32_t *)table_b)[i] = table_Y[i+384] << (isRgb ? 0 : 16);
|
((uint32_t *)table_b)[i] = table_Y[i+384] << ((isRgb ? 0 : 16) + base);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 24:
|
case 24:
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
/* testapp for aspect.[ch] by Atmos
|
/* test app for aspect.[ch] by Atmos */
|
||||||
* gcc aspecttest.c aspect.c -o aspecttest -DASPECT_TEST [-DASPECT_DEBUG]
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
@ -1,4 +1,22 @@
|
|||||||
/* This file (C) Mark Zealey <mark@zealos.org> 2002, released under GPL */
|
/*
|
||||||
|
* copyright (C) 2002 Mark Zealey <mark@zealos.org>
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
@ -1,4 +1,23 @@
|
|||||||
/* This file (C) Mark Zealey <mark@zealos.org 2002, released under GPL */
|
/*
|
||||||
|
* copyright (C) 2002 Mark Zealey <mark@zealos.org>
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
#ifndef MPLAYER_GEOMETRY_H
|
#ifndef MPLAYER_GEOMETRY_H
|
||||||
#define MPLAYER_GEOMETRY_H
|
#define MPLAYER_GEOMETRY_H
|
||||||
|
|
||||||
|
@ -1,13 +1,32 @@
|
|||||||
|
/*
|
||||||
|
* common OpenGL routines
|
||||||
|
*
|
||||||
|
* copyleft (C) 2005 Reimar Döffinger <Reimar.Doeffinger@stud.uni-karlsruhe.de>
|
||||||
|
* Special thanks go to the xine team and Matthias Hopf, whose video_out_opengl.c
|
||||||
|
* gave me lots of good ideas.
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \file gl_common.c
|
* \file gl_common.c
|
||||||
* \brief OpenGL helper functions used by vo_gl.c and vo_gl2.c
|
* \brief OpenGL helper functions used by vo_gl.c and vo_gl2.c
|
||||||
*
|
|
||||||
* Common OpenGL routines.
|
|
||||||
* Copyleft (C) Reimar Döffinger <Reimar.Doeffinger@stud.uni-karlsruhe.de>, 2005
|
|
||||||
* Licensed under the GNU GPL v2 or later.
|
|
||||||
* Special thanks go to the xine team and Matthias Hopf, whose video_out_opengl.c
|
|
||||||
* gave me lots of good ideas.
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
23
libvo/gtf.c
23
libvo/gtf.c
@ -1,11 +1,24 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (C) 2002 Rudolf Marek <r.marek@assembler.cz>
|
|
||||||
*
|
|
||||||
* You can redistribute this file under terms and conditions
|
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
*
|
|
||||||
* GTF calculations formulas are taken from GTF_V1R1.xls
|
* GTF calculations formulas are taken from GTF_V1R1.xls
|
||||||
* created by ANDY.MORRISH@NSC.COM
|
* created by ANDY.MORRISH@NSC.COM
|
||||||
|
*
|
||||||
|
* copyright (C) 2002 Rudolf Marek <r.marek@assembler.cz>
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
//Version 0.4
|
//Version 0.4
|
||||||
|
@ -1,13 +1,24 @@
|
|||||||
/*
|
/*
|
||||||
* vesa_lvo.c
|
* vo_vesa interface to Linux Video Overlay
|
||||||
|
* (partly based on vo_mga.c)
|
||||||
*
|
*
|
||||||
* Copyright (C) Nick Kurshev <nickols_k@mail.ru> - Oct 2001
|
* copyright (C) 2001 Nick Kurshev <nickols_k@mail.ru>
|
||||||
*
|
*
|
||||||
* You can redistribute this file under terms and conditions
|
* This file is part of MPlayer.
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
*
|
*
|
||||||
* This file contains vo_vesa interface to Linux Video Overlay.
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
* (Partly based on vo_mga.c from mplayer's package)
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
|
@ -1,12 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
* vesa_lvo.c
|
* vo_vesa interface to Linux Video Overlay
|
||||||
*
|
*
|
||||||
* Copyright (C) Nick Kurshev <nickols_k@mail.ru> - Oct 2001
|
* copyright (C) 2001 Nick Kurshev <nickols_k@mail.ru>
|
||||||
*
|
*
|
||||||
* You can redistribute this file under terms and conditions
|
* This file is part of MPlayer.
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
*
|
*
|
||||||
* This file contains vo_vesa interface to Linux Video Overlay.
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef MPLAYER_VESA_LVO_H
|
#ifndef MPLAYER_VESA_LVO_H
|
||||||
|
@ -1,21 +1,30 @@
|
|||||||
/*
|
/*
|
||||||
* vo_bl.c - playback using the Blinkenlights UPD protocol (and to files)
|
* playback using the Blinkenlights UDP protocol (and to files)
|
||||||
*
|
*
|
||||||
* UDP socket handling copied from bsender.c part of blib-0.6:
|
* UDP socket handling copied from bsender.c part of blib-0.6:
|
||||||
* http://sven.gimp.org/blinkenlights/
|
* http://sven.gimp.org/blinkenlights/
|
||||||
* Copyright (c) 2001-2001 The Blinkenlights Crew:
|
* copyright (c) 2001-2001 The Blinkenlights Crew:
|
||||||
* Sven Neumann <sven@gimp.org>
|
* Sven Neumann <sven@gimp.org>
|
||||||
* Michael Natterer <mitch@gimp.org>
|
* Michael Natterer <mitch@gimp.org>
|
||||||
* Daniel Mack <daniel@yoobay.net>
|
* Daniel Mack <daniel@yoobay.net>
|
||||||
* (these portions are licensed under GNU GPL v2 or "(at your option)
|
* copyright (C) 2004 Stefan Schuermans <1stein@schuermans.info>
|
||||||
* any later version")
|
* other stuff: copyright (C) 2002 Rik Snel
|
||||||
*
|
*
|
||||||
* Other stuff: Copyright (C) Rik Snel 2002, License GNU GPL v2 or later
|
* This file is part of MPlayer.
|
||||||
*
|
*
|
||||||
* patch from Stefan Schuermans <1stein@schuermans.info>:
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
* - correction of "maxval" in Blinkenlights UDP protcol
|
* it under the terms of the GNU General Public License as published by
|
||||||
* - new scheme for new HDL
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
* - new scheme for grayscale in arbitrary size
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* PPM/PGM/PGMYUV video output driver
|
* PPM/PGM/PGMYUV video output driver
|
||||||
*
|
*
|
||||||
* Written by Ivo van Poorten. (C) Copyright 2004, 2005.
|
* copyright (C) 2004, 2005 Ivo van Poorten
|
||||||
*
|
*
|
||||||
* This file is part of MPlayer.
|
* This file is part of MPlayer.
|
||||||
*
|
*
|
||||||
|
@ -1,9 +1,26 @@
|
|||||||
/* Copyright (C) Mark Sanderson, 2006, <mmp@kiora.ath.cx>.
|
/*
|
||||||
* Released under the terms and conditions of the GPL.
|
* copyright (C) 2006 Mark Sanderson <mmp@kiora.ath.cx>
|
||||||
*
|
*
|
||||||
* 30-Mar-2006 Modified from tdfxfb.c by Mark Zealey
|
* 30-Mar-2006 Modified from tdfxfb.c by Mark Zealey
|
||||||
*
|
*
|
||||||
* Hints and tricks:
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* Hints and tricks:
|
||||||
* - Use -dr to get direct rendering
|
* - Use -dr to get direct rendering
|
||||||
* - Use -vf yuy2 to get yuy2 rendering, *MUCH* faster than yv12
|
* - Use -vf yuy2 to get yuy2 rendering, *MUCH* faster than yv12
|
||||||
*/
|
*/
|
||||||
|
@ -1,14 +1,12 @@
|
|||||||
/*
|
/*
|
||||||
* vo_tdfx_vid.c
|
* copyright (C) 2003 Alban Bedel
|
||||||
*
|
*
|
||||||
* Copyright (C) Alban Bedel - 03/2003
|
* This file is part of MPlayer.
|
||||||
*
|
|
||||||
* This file is part of MPlayer, a free movie player.
|
|
||||||
*
|
*
|
||||||
* MPlayer is free software; you can redistribute it and/or modify
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 2, or (at your option)
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
* any later version.
|
* (at your option) any later version.
|
||||||
*
|
*
|
||||||
* MPlayer is distributed in the hope that it will be useful,
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
@ -1,6 +1,24 @@
|
|||||||
/* Copyright (C) Mark Zealey, 2002, <mark@zealos.org>. Released under the terms
|
/*
|
||||||
* and conditions of the GPL.
|
* copyright (C) 2002 Mark Zealey <mark@zealos.org>
|
||||||
*
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
* 30/03/02: An almost total rewrite, added DR support and support for modes
|
* 30/03/02: An almost total rewrite, added DR support and support for modes
|
||||||
* other than 16bpp. Fixed the crash when playing multiple files
|
* other than 16bpp. Fixed the crash when playing multiple files
|
||||||
* 07/04/02: Fixed DR support, added YUY2 support, fixed OSD stuff.
|
* 07/04/02: Fixed DR support, added YUY2 support, fixed OSD stuff.
|
||||||
|
@ -1,11 +1,22 @@
|
|||||||
/*
|
/*
|
||||||
* video_out_vesa.c
|
* copyright (C) 2001 Nick Kurshev <nickols_k@mail.ru>
|
||||||
*
|
|
||||||
* Copyright (C) Nick Kurshev <nickols_k@mail.ru> - Oct 2001
|
|
||||||
*
|
|
||||||
* You can redistribute this file under terms and conditions
|
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
* This file is partly based on vbetest.c from lrmi distributive.
|
* This file is partly based on vbetest.c from lrmi distributive.
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1,6 +1,22 @@
|
|||||||
/*
|
/*
|
||||||
* vo_zr.c - playback on zoran cards
|
* playback on Zoran cards
|
||||||
* Copyright (C) Rik Snel 2001,2002, License GNU GPL v2 or later
|
* copyright (C) 2001, 2003 Rik Snel
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
|
@ -1,7 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
* vo_zr2.c - playback on zoran cards
|
* playback on Zoran cards, based on vo_zr.c
|
||||||
* Based on vo_zr.c,v 1.27
|
*
|
||||||
* Copyright (C) Rik Snel 2001-2005, License GNU GPL v2 or later
|
* copyright (C) 2001-2005 Rik Snel
|
||||||
|
*
|
||||||
|
* This file is part of MPlayer.
|
||||||
|
*
|
||||||
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
|
@ -1,14 +1,25 @@
|
|||||||
/*
|
/*
|
||||||
* vosub_vidix.c
|
* vidix interface to any mplayer vo driver
|
||||||
|
* (partly based on vesa_lvo.c)
|
||||||
*
|
*
|
||||||
* Copyright (C) Nick Kurshev <nickols_k@mail.ru> - 2002
|
* copyright (C) 2002 Nick Kurshev <nickols_k@mail.ru>
|
||||||
* Copyright (C) Alex Beregszaszi
|
* copyright (C) Alex Beregszaszi
|
||||||
*
|
*
|
||||||
* You can redistribute this file under terms and conditions
|
* This file is part of MPlayer.
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
*
|
*
|
||||||
* This file contains vidix interface to any mplayer's VO plugin.
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
* (Partly based on vesa_lvo.c from mplayer's package)
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
|
@ -1,12 +1,23 @@
|
|||||||
/*
|
/*
|
||||||
* vosub_vidix.h
|
* vosub_vidix interface to any mplayer vo driver
|
||||||
*
|
*
|
||||||
* Copyright (C) Nick Kurshev <nickols_k@mail.ru> - 2002
|
* copyright (C) 2002 Nick Kurshev <nickols_k@mail.ru>
|
||||||
*
|
*
|
||||||
* You can redistribute this file under terms and conditions
|
* This file is part of MPlayer.
|
||||||
* of GNU General Public licence v2 or later.
|
|
||||||
*
|
*
|
||||||
* This file contains vosub_vidix interface to any mplayer's VO driver
|
* MPlayer is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* MPlayer is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef MPLAYER_VOSUB_VIDIX_H
|
#ifndef MPLAYER_VOSUB_VIDIX_H
|
||||||
|
Loading…
Reference in New Issue
Block a user