cvs: phpdoc /en/reference/oggvorbis book.xml constants.xml examples.xml reference.xml setup.xml
| From: | Philip Olson | Date: | Sun, 23 Dec 2007 20:01:14 +0000 |
| Subject: | cvs: phpdoc /en/reference/oggvorbis book.xml constants.xml examples.xml reference.xml setup.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-764@lists.php.net to get a copy of this message | ||
philip Sun Dec 23 20:01:14 2007 UTC
Removed files:
/phpdoc/en/reference/oggvorbis reference.xml
Modified files:
/phpdoc/en/reference/oggvorbis book.xml setup.xml examples.xml
constants.xml
Log:
MFB: Upgrade to the new-reference-structure
- Split reference.xml into book.xml, setup.xml, and examples.xml
- Moved from reference.xml to book.xml:
- The intro text (partintro), and link to various pages
- Moved from reference.xml to setup.xml:
- The other: requirements, installation, configuration, and resources
- Moved from reference.xml to examples.xml: the examples
- Removed the now empty reference.xml as this function contains no functions
- Changed the constants section to be an <appendix> (constants.xml)
- Changed the contexts section to be an <appendix> (contexts.xml)
- Changed the intro ID from <extname>.intro to intro.<extname>
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/oggvorbis/book.xml?r1=1.1&r2=1.2&diff_format=u
Index: phpdoc/en/reference/oggvorbis/book.xml
diff -u /dev/null phpdoc/en/reference/oggvorbis/book.xml:1.2
--- /dev/null Sun Dec 23 20:01:14 2007
+++ phpdoc/en/reference/oggvorbis/book.xml Sun Dec 23 20:01:14 2007
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- $Revision: 1.2 $ -->
+<!-- Purpose: utilspec.audio -->
+<!-- Membership: pecl, external -->
+
+<book xml:id="book.oggvorbis" xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink">
+ <title>OGG/Vorbis</title>
+ <titleabbrev>oggvorbis</titleabbrev>
+
+ <!-- {{{ preface -->
+ <preface xml:id="intro.oggvorbis">
+ &reftitle.intro;
+ <para>
+ The OGG/Vorbis file format, as defined by <link
+ xlink:href="&url.ogg.vorbis;">&url.ogg.vorbis;</link>, is a scheme
+ for compressing audio streams by multiple factors with a minimum of
+ quality loss. This extension adds Ogg Vorbis support to PHP's
+ <link linkend="wrappers">URL Wrappers</link>. When used in read mode,
+ compressed OGG/Vorbis data is expanded to raw PCM audio in one of six PCM
+ encoding formats listed below.
+ </para>
+ </preface>
+ <!-- }}} -->
+
+ &reference.oggvorbis.setup;
+ &reference.oggvorbis.constants;
+ &reference.oggvorbis.contexts;
+ &reference.oggvorbis.examples;
+
+</book>
+
+<!-- Keep this comment at the end of the file
+Local variables:
+mode: sgml
+sgml-omittag:t
+sgml-shorttag:t
+sgml-minimize-attributes:nil
+sgml-always-quote-attributes:t
+sgml-indent-step:1
+sgml-indent-data:t
+indent-tabs-mode:nil
+sgml-parent-document:nil
+sgml-default-dtd-file:"../../../manual.ced"
+sgml-exposed-tags:nil
+sgml-local-catalogs:nil
+sgml-local-ecat-files:nil
+End:
+vim600: syn=xml fen fdm=syntax fdl=2 si
+vim: et tw=78 syn=sgml
+vi: ts=1 sw=1
+-->
+
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/oggvorbis/setup.xml?r1=1.1&r2=1.2&diff_format=u
Index: phpdoc/en/reference/oggvorbis/setup.xml
diff -u /dev/null phpdoc/en/reference/oggvorbis/setup.xml:1.2
--- /dev/null Sun Dec 23 20:01:14 2007
+++ phpdoc/en/reference/oggvorbis/setup.xml Sun Dec 23 20:01:14 2007
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- $Revision: 1.2 $ -->
+
+<chapter xml:id="oggvorbis.setup" xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink">
+ &reftitle.setup;
+
+ <!-- {{{ Requirements -->
+ <section xml:id="oggvorbis.requirements">
+ &reftitle.required;
+ <para>
+ This extension requires <literal>PHP >= 4.3.0</literal>,
+ <link xlink:href="&url.ogg.vorbis.downloads;">libogg</link> >=
1.0, and
+ <link xlink:href="&url.ogg.vorbis.downloads;">libvorbis</link>
>= 1.0.
+ </para>
+ </section>
+ <!-- }}} -->
+
+ <!-- {{{ Installation -->
+ &reference.oggvorbis.configure;
+ <!-- }}} -->
+
+ <!-- {{{ Configuration -->
+ <section xml:id="oggvorbis.configuration">
+ &reftitle.runtime;
+ &no.config;
+ </section>
+ <!-- }}} -->
+
+ <!-- {{{ Resources -->
+ <section xml:id="oggvorbis.resources">
+ &reftitle.resources;
+ &no.resource;
+ </section>
+ <!-- }}} -->
+
+</chapter>
+
+<!-- Keep this comment at the end of the file
+Local variables:
+mode: sgml
+sgml-omittag:t
+sgml-shorttag:t
+sgml-minimize-attributes:nil
+sgml-always-quote-attributes:t
+sgml-indent-step:1
+sgml-indent-data:t
+indent-tabs-mode:nil
+sgml-parent-document:nil
+sgml-default-dtd-file:"../../../manual.ced"
+sgml-exposed-tags:nil
+sgml-local-catalogs:nil
+sgml-local-ecat-files:nil
+End:
+vim600: syn=xml fen fdm=syntax fdl=2 si
+vim: et tw=78 syn=sgml
+vi: ts=1 sw=1
+-->
+
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/oggvorbis/examples.xml?r1=1.1&r2=1.2&diff_format=u
Index: phpdoc/en/reference/oggvorbis/examples.xml
diff -u /dev/null phpdoc/en/reference/oggvorbis/examples.xml:1.2
--- /dev/null Sun Dec 23 20:01:14 2007
+++ phpdoc/en/reference/oggvorbis/examples.xml Sun Dec 23 20:01:14 2007
@@ -0,0 +1,98 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+<!-- $Revision: 1.2 $ -->
+
+<chapter xml:id="oggvorbis.examples" xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink">
+ &reftitle.examples;
+ <section xml:id="oggvorbis.examples-basisc">
+ <title>Examples on using the ogg:// wrapper.</title>
+ <para>
+ <example>
+ <title>Reading an OGG/Vorbis file</title>
+ <programlisting role="php">
+<![CDATA[
+<?php
+dl("oggvorbis.so");
+
+/* By default, ogg:// will decode to Signed 16-bit Little Endian */
+$fp = fopen('ogg://myaudio.ogg', 'r');
+
+/* Collect some information about the file. */
+$metadata = stream_get_meta_data($fp);
+
+/* Inspect the first song (usually the only song,
+ but OGG/Vorbis files may be chained) */
+$songdata = $metadata['wrapper_data'][0];
+
+echo "OGG/Vorbis file encoded by: {$songdata['vendor']}\n.";
+echo " {$songdata['channels']} channels of {$songdata['rate']}Hz sampling
encoded at {$songdata['bitrate_nominal']}bps.\n";
+foreach($songdata['comments'] as $comment) {
+ echo " $comment\n";
+}
+
+while ($audio_data = fread($fp, 8192)) {
+ /* Do something with the PCM audio we're extracting from the OGG.
+ Copying to /dev/dsp is a good target on linux systems,
+ just remember to setup the device for your sampling mode first. */
+}
+
+fclose($fp);
+
+?>
+]]>
+ </programlisting>
+ </example>
+ </para>
+
+ <para>
+ <example>
+ <title>Encode an audio file to OGG/Vorbis</title>
+ <programlisting role="php">
+<![CDATA[
+<?php
+dl('oggvorbis.so');
+
+$context = stream_context_create(array('ogg'=>array(
+ 'pcm_mode' => OGGVORBIS_PCM_S8, /* Signed 8bit audio */
+ 'rate' => 44100, /* 44kHz CD quality */
+ 'bitrate' => 0.5, /* Midquality VBR */
+ 'channels' => 1, /* Mono */
+ 'serialno' => 12345))); /* Unique within our stream */
+
+/* Open file for appending. This will "chain" a second OGG stream at the end of the
first. */
+$ogg = fopen('ogg://mysong.ogg', 'a', false, $context);
+
+$pcm = fopen('mysample.pcm', 'r');
+
+/* Compress the raw PCM audio from mysample.pcm into mysong.ogg */
+stream_copy_to_stream($pcm, $ogg);
+
+fclose($pcm);
+fclose($ogg);
+?>
+]]>
+ </programlisting>
+ </example>
+ </para>
+ </section>
+</chapter>
+
+<!-- Keep this comment at the end of the file
+Local variables:
+mode: sgml
+sgml-omittag:t
+sgml-shorttag:t
+sgml-minimize-attributes:nil
+sgml-always-quote-attributes:t
+sgml-indent-step:1
+sgml-indent-data:t
+sgml-parent-document:nil
+sgml-default-dtd-file:"../../../manual.ced"
+sgml-exposed-tags:nil
+sgml-local-catalogs:nil
+sgml-local-ecat-files:nil
+End:
+vim600: syn=xml fen fdm=syntax fdl=2 si
+vim: et tw=78 syn=sgml
+vi: ts=1 sw=1
+-->
+
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/oggvorbis/constants.xml?r1=1.2&r2=1.3&diff_format=u
Index: phpdoc/en/reference/oggvorbis/constants.xml
diff -u phpdoc/en/reference/oggvorbis/constants.xml:1.2
phpdoc/en/reference/oggvorbis/constants.xml:1.3
--- phpdoc/en/reference/oggvorbis/constants.xml:1.2 Wed Jun 20 22:25:08 2007
+++ phpdoc/en/reference/oggvorbis/constants.xml Sun Dec 23 20:01:14 2007
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.2 $ -->
-<section xml:id="oggvorbis.constants" xmlns="http://docbook.org/ns/docbook">
+<!-- $Revision: 1.3 $ -->
+<appendix xml:id="oggvorbis.constants" xmlns="http://docbook.org/ns/docbook">
&reftitle.constants;
&extension.constants;
<table>
@@ -40,7 +40,7 @@
</tbody>
</tgroup>
</table>
-</section>
+</appendix>
<!-- Keep this comment at the end of the file
Local variables: