clarify installation instructions about mediagoblin.ini
[mediagoblin.git] / docs / source / siteadmin / media-types.rst
index 3e8a94e9e5ade4156ed9c8188330dd009e067986..146e1aaeb7c749e659f3360dd066540f9c454beb 100644 (file)
@@ -1,6 +1,6 @@
 .. MediaGoblin Documentation
 
-   Written in 2011, 2012 by MediaGoblin contributors
+   Written in 2011, 2012, 2014, 2015 by MediaGoblin contributors
 
    To the extent possible under law, the author(s) have dedicated all
    copyright and related and neighboring rights to this software to
@@ -18,11 +18,11 @@ Media Types
 ====================
 
 In the future, there will be all sorts of media types you can enable,
-but in the meanwhile there are five additional media types: video, audio,
-ascii art, STL/3d models, PDF and Document.
+but in the meanwhile there are six additional media types: video, audio,
+raw image, ASCII art, STL/3D models, PDF and Document.
 
 First, you should probably read ":doc:`configuration`" to make sure
-you know how to modify the mediagoblin config file.
+you know how to modify the MediaGoblin config file.
 
 Enabling Media Types
 ====================
@@ -30,7 +30,7 @@ Enabling Media Types
 .. note::
     Media types are now plugins
 
-Media types are enabled in your mediagoblin configuration file, typically it is
+Media types are enabled in your MediaGoblin configuration file, typically it is
 created by copying ``mediagoblin.ini`` to ``mediagoblin_local.ini`` and then
 applying your changes to ``mediagoblin_local.ini``. If you don't already have a
 ``mediagoblin_local.ini``, create one in the way described.
@@ -69,22 +69,33 @@ The file-extension-based approach is used before the sniffing-based approach,
 if the file-extension-based approach finds a match, the sniffing-based approach
 will be skipped as it uses far more processing power.
 
+Configuring Media Types
+=======================
+
+Each media type has a ``config_spec.ini`` file with configurable
+options and comments explaining their intended side effect. For
+instance the ``video`` media type configuration can be found in
+``mediagoblin/media_types/video/config_spec.ini``.
+
 
 Video
 =====
 
-To enable video, first install gstreamer and the python-gstreamer
-bindings (as well as whatever gstremaer extensions you want,
+To enable video, first install GStreamer and the python-gstreamer
+bindings (as well as whatever GStreamer extensions you want,
 good/bad/ugly).  On Debianoid systems
 
 .. code-block:: bash
 
-    sudo apt-get install python-gst0.10 \
-        gstreamer0.10-plugins-base \
-        gstreamer0.10-plugins-bad \
-        gstreamer0.10-plugins-good \
-        gstreamer0.10-plugins-ugly \
-        gstreamer0.10-ffmpeg
+    sudo apt-get install python-gi python3-gi \
+        gstreamer1.0-tools \
+        gir1.2-gstreamer-1.0 \
+        gir1.2-gst-plugins-base-1.0 \
+        gstreamer1.0-plugins-good \
+        gstreamer1.0-plugins-ugly \
+        gstreamer1.0-plugins-bad \
+        gstreamer1.0-libav \
+        python-gst-1.0
 
 
 Add ``[[mediagoblin.media_types.video]]`` under the ``[plugins]`` section in
@@ -96,7 +107,7 @@ Run
 
     ./bin/gmg dbupdate
 
-Now you should be able to submit videos, and mediagoblin should
+Now you should be able to submit videos, and MediaGoblin should
 transcode them.
 
 .. note::
@@ -110,28 +121,18 @@ transcode them.
 Audio
 =====
 
-To enable audio, install the gstreamer and python-gstreamer bindings (as well
-as whatever gstreamer plugins you want, good/bad/ugly), scipy and numpy are
+To enable audio, install the GStreamer and python-gstreamer bindings (as well
+as whatever GStreamer plugins you want, good/bad/ugly), SciPy and NumPy are
 also needed for the audio spectrograms.
 To install these on Debianoid systems, run::
 
-    sudo apt-get install python-gst0.10 gstreamer0.10-plugins-{base,bad,good,ugly} \
-        gstreamer0.10-ffmpeg python-numpy python-scipy
-
-The ``scikits.audiolab`` package you will install in the next step depends on the
-``libsndfile1-dev`` package, so we should install it.
-On Debianoid systems, run
-
-.. code-block:: bash
-
-    sudo apt-get install libsndfile1-dev
+    sudo apt-get install python-gst-1.0 gstreamer1.0-plugins-{base,bad,good,ugly} \
+    gstreamer1.0-libav python-numpy python-scipy libsndfile1-dev libasound2-dev
 
 .. note::
     scikits.audiolab will display a warning every time it's imported if you do
     not compile it with alsa support. Alsa support is not necessary for the GNU
-    MediaGoblin application but if you do not wish the alsa warnings from
-    audiolab you should also install ``libasound2-dev`` before installing
-    scikits.audiolab.
+    MediaGoblin application.
 
 Then install ``scikits.audiolab`` for the spectrograms::
 
@@ -149,12 +150,34 @@ Run
 You should now be able to upload and listen to audio files!
 
 
-Ascii art
+Raw image
 =========
 
-To enable ascii art support, first install the
+To enable raw image you need to install pyexiv2.  On Debianoid systems
+
+.. code-block:: bash
+
+    sudo apt-get install python-pyexiv2
+
+Add ``[[mediagoblin.media_types.raw_image]]`` under the ``[plugins]``
+section in your ``mediagoblin_local.ini`` and restart MediaGoblin.
+
+Run
+
+.. code-block:: bash
+
+    ./bin/gmg dbupdate
+
+Now you should be able to submit raw images, and MediaGoblin should
+extract the JPEG preview from them.
+
+
+ASCII art
+=========
+
+To enable ASCII art support, first install the
 `chardet <http://pypi.python.org/pypi/chardet>`_
-library, which is necessary for creating thumbnails of ascii art
+library, which is necessary for creating thumbnails of ASCII art
 
 .. code-block:: bash
 
@@ -171,20 +194,20 @@ Run
 
     ./bin/gmg dbupdate
 
-Now any .txt file you uploaded will be processed as ascii art!
+Now any .txt file you uploaded will be processed as ASCII art!
 
 
-STL / 3d model support
+STL / 3D model support
 ======================
 
-To enable the "STL" 3d model support plugin, first make sure you have
-a recentish `Blender <http://blender.org>`_ installed and available on
+To enable the "STL" 3D model support plugin, first make sure you have
+a recent `Blender <http://blender.org>`_ installed and available on
 your execution path.  This feature has been tested with Blender 2.63.
 It may work on some earlier versions, but that is not guaranteed (and
 is surely not to work prior to Blender 2.5X).
 
 Add ``[[mediagoblin.media_types.stl]]`` under the ``[plugins]`` section in your
-``mediagoblin_local.ini`` and restart MediaGoblin. 
+``mediagoblin_local.ini`` and restart MediaGoblin.
 
 Run
 
@@ -200,9 +223,9 @@ PDF and Document
 
 To enable the "PDF and Document" support plugin, you need:
 
-1. pdftocairo and pdfinfo for pdf only support.
+1. pdftocairo and pdfinfo for PDF only support.
 
-2. unoconv with headless support to support converting libreoffice supported
+2. unoconv with headless support to support converting LibreOffice supported
    documents as well, such as doc/ppt/xls/odf/odg/odp and more.
    For the full list see mediagoblin/media_types/pdf/processing.py,
    unoconv_supported.
@@ -215,7 +238,7 @@ To install this on Fedora:
 
     sudo yum install -y poppler-utils unoconv libreoffice-headless
 
-Note: You can leave out unoconv and libreoffice-headless if you want only pdf
+Note: You can leave out unoconv and libreoffice-headless if you want only PDF
 support. This will result in a much smaller list of dependencies.
 
 pdf.js relies on git submodules, so be sure you have fetched them:
@@ -233,7 +256,7 @@ This feature has been tested on Fedora with:
 It may work on some earlier versions, but that is not guaranteed.
 
 Add ``[[mediagoblin.media_types.pdf]]`` under the ``[plugins]`` section in your
-``mediagoblin_local.ini`` and restart MediaGoblin. 
+``mediagoblin_local.ini`` and restart MediaGoblin.
 
 Run
 
@@ -242,3 +265,13 @@ Run
     ./bin/gmg dbupdate
 
 
+Blog (HIGHLY EXPERIMENTAL)
+==========================
+
+MediaGoblin has a blog media type, which you might notice by looking
+through the docs!  However, it is *highly experimental*.  We have not
+security reviewed this, and it acts in a way that is not like normal
+blogs (the blog posts are themselves media types!).
+
+So you can play with this, but it is not necessarily recommended yet
+for production use! :)