/* * Copyright (c) 2013 Vittorio Giovara <[email protected]> * * This file is part of FFmpeg. * * FFmpeg is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * FFmpeg 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 * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with FFmpeg; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ /** * @file * @ingroup lavu_video_stereo3d * Stereoscopic video */ #ifndef AVUTIL_STEREO3D_H #define AVUTIL_STEREO3D_H #include <stdint.h> #include "frame.h" /** * @defgroup lavu_video_stereo3d Stereo3D types and functions * @ingroup lavu_video * * A stereoscopic video file consists in multiple views embedded in a single * frame, usually describing two views of a scene. This file describes all * possible codec-independent view arrangements. * * @{ */ /** * List of possible 3D Types */ enum AVStereo3DType { … }; /** * List of possible view types. */ enum AVStereo3DView { … }; /** * Inverted views, Right/Bottom represents the left view. */ #define AV_STEREO3D_FLAG_INVERT … /** * Stereo 3D type: this structure describes how two videos are packed * within a single video surface, with additional information as needed. * * @note The struct must be allocated with av_stereo3d_alloc() and * its size is not a part of the public ABI. */ AVStereo3D; /** * Allocate an AVStereo3D structure and set its fields to default values. * The resulting struct can be freed using av_freep(). * * @return An AVStereo3D filled with default values or NULL on failure. */ AVStereo3D *av_stereo3d_alloc(void); /** * Allocate a complete AVFrameSideData and add it to the frame. * * @param frame The frame which side data is added to. * * @return The AVStereo3D structure to be filled by caller. */ AVStereo3D *av_stereo3d_create_side_data(AVFrame *frame); /** * Provide a human-readable name of a given stereo3d type. * * @param type The input stereo3d type value. * * @return The name of the stereo3d value, or "unknown". */ const char *av_stereo3d_type_name(unsigned int type); /** * Get the AVStereo3DType form a human-readable name. * * @param name The input string. * * @return The AVStereo3DType value, or -1 if not found. */ int av_stereo3d_from_name(const char *name); /** * @} */ #endif /* AVUTIL_STEREO3D_H */