Package org.nuxeo.ecm.platform.video
Class VideoInfo
- java.lang.Object
-
- org.nuxeo.ecm.platform.video.VideoInfo
-
- All Implemented Interfaces:
Serializable
public final class VideoInfo extends Object implements Serializable
Object containing info about a video file.- Since:
- 5.5
- Author:
- Thomas Roger
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static Pattern
BIT_RATE_PATTERN
static String
DURATION
static Pattern
DURATION_PATTERN
static VideoInfo
EMPTY_INFO
static String
FORMAT
static Pattern
FORMAT_PATTERN
static String
FRAME_RATE
static Pattern
FRAME_RATE_PATTERN
static String
HEIGHT
static Pattern
METADATA_ROTATE_PATTERN
static Pattern
SIZE_PATTERN
static Pattern
STREAM_PATTERN
static String
STREAMS
static String
WIDTH
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static VideoInfo
fromFFmpegOutput(List<String> output)
Build aVideoInfo
from a FFmpeg output.static VideoInfo
fromMap(Map<String,Serializable> map)
Build aVideoInfo
from aMap
of attributes.double
getDuration()
Returns the duration of the video.String
getFormat()
Returns the format of the video.double
getFrameRate()
Returns the frame rate of the video.long
getHeight()
Returns the height of the video.List<Stream>
getStreams()
Returns all theStream
s of the video.long
getWidth()
Returns the width of the video.Map<String,Serializable>
toMap()
Returns aMap
of attributes for thisVideoInfo
.
-
-
-
Field Detail
-
FORMAT_PATTERN
public static final Pattern FORMAT_PATTERN
-
DURATION_PATTERN
public static final Pattern DURATION_PATTERN
-
STREAM_PATTERN
public static final Pattern STREAM_PATTERN
-
SIZE_PATTERN
public static final Pattern SIZE_PATTERN
-
FRAME_RATE_PATTERN
public static final Pattern FRAME_RATE_PATTERN
-
BIT_RATE_PATTERN
public static final Pattern BIT_RATE_PATTERN
-
METADATA_ROTATE_PATTERN
public static final Pattern METADATA_ROTATE_PATTERN
- Since:
- 11.1
-
EMPTY_INFO
public static final VideoInfo EMPTY_INFO
-
DURATION
public static final String DURATION
- See Also:
- Constant Field Values
-
WIDTH
public static final String WIDTH
- See Also:
- Constant Field Values
-
HEIGHT
public static final String HEIGHT
- See Also:
- Constant Field Values
-
FRAME_RATE
public static final String FRAME_RATE
- See Also:
- Constant Field Values
-
FORMAT
public static final String FORMAT
- See Also:
- Constant Field Values
-
STREAMS
public static final String STREAMS
- See Also:
- Constant Field Values
-
-
Method Detail
-
fromMap
public static VideoInfo fromMap(Map<String,Serializable> map)
Build aVideoInfo
from aMap
of attributes.Used when creating a
VideoInfo
from aDocumentModel
property.
-
fromFFmpegOutput
public static VideoInfo fromFFmpegOutput(List<String> output)
Build aVideoInfo
from a FFmpeg output.
-
getDuration
public double getDuration()
Returns the duration of the video.
-
getWidth
public long getWidth()
Returns the width of the video.
-
getHeight
public long getHeight()
Returns the height of the video.
-
getFormat
public String getFormat()
Returns the format of the video.
-
getFrameRate
public double getFrameRate()
Returns the frame rate of the video.
-
toMap
public Map<String,Serializable> toMap()
Returns aMap
of attributes for thisVideoInfo
.Used when saving this
Stream
to aDocumentModel
property.
-
-