public class FrameGrab extends Object
Constructor and Description |
---|
FrameGrab(SeekableDemuxerTrack videoTrack,
ContainerAdaptor decoder) |
Modifier and Type | Method and Description |
---|---|
static FrameGrab |
createFrameGrab(SeekableByteChannel _in) |
ContainerAdaptor |
getDecoder() |
static Picture |
getFrameAtSec(File file,
double second)
Get frame at a specified second as JCodec image
|
static Picture |
getFrameFromChannel(SeekableByteChannel file,
int frameNumber)
Get frame at a specified frame number as JCodec image
|
static Picture |
getFrameFromChannelAtSec(SeekableByteChannel file,
double second)
Get frame at a specified second as JCodec image
|
static Picture |
getFrameFromFile(File file,
int frameNumber)
Get frame at a specified frame number as JCodec image
|
MediaInfo |
getMediaInfo()
Gets info about the media
|
Picture |
getNativeFrame()
Get frame at current position in JCodec native image
|
static Picture |
getNativeFrameAtFrame(SeekableDemuxerTrack vt,
ContainerAdaptor decoder,
int frameNumber)
Get a specified frame by number from an already open demuxer track
|
static Picture |
getNativeFrameAtSec(SeekableDemuxerTrack vt,
ContainerAdaptor decoder,
double second)
Get a specified frame by second from an already open demuxer track
|
static Picture |
getNativeFrameAtSecSloppy(SeekableDemuxerTrack vt,
ContainerAdaptor decoder,
double second)
Get a specified frame by second from an already open demuxer track (
sloppy mode, i.e.
|
static Picture |
getNativeFrameSloppy(SeekableDemuxerTrack vt,
ContainerAdaptor decoder,
int frameNumber)
Get a specified frame by number from an already open demuxer track (
sloppy mode, i.e.
|
PictureWithMetadata |
getNativeFrameWithMetadata()
Get frame at current position in JCodec native image
|
SeekableDemuxerTrack |
getVideoTrack() |
FrameGrab |
seekToFramePrecise(int frameNumber)
Position frame grabber to a specific frame in a movie.
|
FrameGrab |
seekToFrameSloppy(int frameNumber)
Position frame grabber to a specific frame in a movie
Performs a sloppy seek, meaning that it may actually not seek to exact
frame requested, instead it will seek to the closest key frame
NOTE: fast, as it just seeks to the closest previous key frame and
doesn't try to decode frames in the middle
|
FrameGrab |
seekToSecondPrecise(double second)
Position frame grabber to a specific second in a movie.
|
FrameGrab |
seekToSecondSloppy(double second)
Position frame grabber to a specific second in a movie.
|
public FrameGrab(SeekableDemuxerTrack videoTrack, ContainerAdaptor decoder)
public static FrameGrab createFrameGrab(SeekableByteChannel _in) throws IOException, JCodecException
IOException
JCodecException
public FrameGrab seekToSecondPrecise(double second) throws IOException, JCodecException
second
- IOException
JCodecException
public FrameGrab seekToFramePrecise(int frameNumber) throws IOException, JCodecException
frameNumber
- IOException
JCodecException
public FrameGrab seekToSecondSloppy(double second) throws IOException, JCodecException
second
- IOException
JCodecException
public FrameGrab seekToFrameSloppy(int frameNumber) throws IOException, JCodecException
frameNumber
- IOException
JCodecException
public PictureWithMetadata getNativeFrameWithMetadata() throws IOException
IOException
public Picture getNativeFrame() throws IOException
IOException
public static Picture getFrameAtSec(File file, double second) throws IOException, JCodecException
file
- second
- IOException
JCodecException
public static Picture getFrameFromChannelAtSec(SeekableByteChannel file, double second) throws JCodecException, IOException
file
- second
- IOException
JCodecException
public static Picture getFrameFromFile(File file, int frameNumber) throws IOException, JCodecException
file
- second
- IOException
JCodecException
public static Picture getFrameFromChannel(SeekableByteChannel file, int frameNumber) throws JCodecException, IOException
file
- second
- IOException
JCodecException
public static Picture getNativeFrameAtFrame(SeekableDemuxerTrack vt, ContainerAdaptor decoder, int frameNumber) throws IOException, JCodecException
vt
- decoder
- frameNumber
- IOException
JCodecException
public static Picture getNativeFrameAtSec(SeekableDemuxerTrack vt, ContainerAdaptor decoder, double second) throws IOException, JCodecException
vt
- decoder
- frameNumber
- IOException
JCodecException
public static Picture getNativeFrameSloppy(SeekableDemuxerTrack vt, ContainerAdaptor decoder, int frameNumber) throws IOException, JCodecException
vt
- decoder
- frameNumber
- IOException
JCodecException
public static Picture getNativeFrameAtSecSloppy(SeekableDemuxerTrack vt, ContainerAdaptor decoder, double second) throws IOException, JCodecException
vt
- decoder
- frameNumber
- IOException
JCodecException
public MediaInfo getMediaInfo()
public SeekableDemuxerTrack getVideoTrack()
public ContainerAdaptor getDecoder()
Copyright © 2019. All rights reserved.