class: SimpleImageSequence
[124:7] extends: object
SimpleImageSequence wraps boofcv.io.image.SimpleImageSequence.
Members
- obj
Methods
-
SimpleImageSequence (
object Obj)Wraps a simple image sequence.
- @p
Objis an existing sequence object.
- @p
-
getWidth ()
Gets sequence width.
- @r
Widthin pixels.
- @r
-
getHeight ()
Gets sequence height.
- @r
Heightin pixels.
- @r
-
hasNext ()
Gets whether another frame is available.
- @r
Truewhen next can be called.
- @r
-
next ()
Gets the next BoofCV image.
- @r
Thenext image Java object.
- @r
-
getImage ()
Gets the current BoofCV image.
- @r
Thecurrent image Java object.
- @r
-
getGuiImage ()
Gets the current GUI image.
- @r
Thecurrent GUI image Java object.
- @r
-
getFrameNumber ()
Gets the frame number.
- @r
Thecurrent frame number.
- @r
-
setLoop (
bool On)Sets looping.
- @p
Ontrue enables looping when supported.
- @p
-
getImageType ()
Gets image type.
- @r
AnImageType wrapper.
- @r
-
reset ()
Resets the sequence.
-
close ()
Closes the sequence.
class: JCodecMediaManager
[74:7] extends: MediaManager
JCodecMediaManager wraps boofcv.io.jcodec.JCodecMediaManager.
Methods
-
JCodecMediaManager ()
Creates the JCodec media manager.
class: FfmpegVideoImageSequence
[108:7] extends: SimpleImageSequence
FfmpegVideoImageSequence wraps boofcv.io.ffmpeg.FfmpegVideoImageSequence.
This class needs the FFmpeg native libraries and this package does not
ship them, so calling the constructor as-is raises a runtime exception
reading no jniavutil in java.library.path. That is expected and does
not mean the install is broken.
The reason is licensing. The only prebuilt FFmpeg binaries matching the
API BoofCV was compiled against were built with the FFmpeg configure
flags enable-gpl and enable-nonfree. That combination puts GPL code
in the same binary as code the GPL forbids combining with, so the result
cannot be redistributed under any license. Bundling it would make this
whole package undistributable. Newer FFmpeg builds without those flags
exist but renamed their Java packages and no longer bind to BoofCV.
You can still use FFmpeg by supplying the binaries yourself. Download
the native jar for your platform from Maven Central under
org.bytedeco.javacpp-presets:ffmpeg:4.1-1.4.4, for example
ffmpeg-4.1-1.4.4-linux-x86_64.jar, then call
app.loadJar("lib/ffmpeg-4.1-1.4.4-linux-x86_64.jar") before creating a
sequence. The version must be 4.1-1.4.4; later versions will not bind.
Doing this makes you the party distributing those binaries, so their
license terms become yours to meet. See README.md for the full steps.
To avoid the question entirely, JCodecMediaManager reads video with no
native code at all. It handles fewer formats, mainly H.264 in MP4, but it
is included here and ready to use.
Methods
-
FfmpegVideoImageSequence (
string Path, object ImageType)Creates an FFmpeg video sequence. Requires the FFmpeg native jar to be loaded first. See the class documentation above for why it is not bundled and how to add it.
- @p
Pathis the video path. - @p
ImageTypeis an ImageType wrapper.
- @p
class: DefaultMediaManager
[62:7] extends: MediaManager
DefaultMediaManager wraps boofcv.io.wrapper.DefaultMediaManager.
Methods
-
DefaultMediaManager ()
Creates the default media manager.
class: MediaManager
[22:7] extends: object
MediaManager wraps boofcv.io.MediaManager.
Members
- obj
Methods
-
MediaManager (
object Obj)Wraps a media manager.
- @p
Objis an existing media manager Java object.
- @p
-
openVideo (
string Path, object ImageType)Opens video.
- @p
Pathis a file path or URL accepted by the concrete manager. - @p
ImageTypeis an ImageType wrapper. - @r
ASimpleImageSequence wrapper.
- @p
-
openCamera (
string Spec, int Width, int Height, object ImageType)Opens a camera.
- @p
Specis the concrete manager camera spec. - @p
Widthis requested width. - @p
Heightis requested height. - @p
ImageTypeis an ImageType wrapper. - @r
ASimpleImageSequence wrapper.
- @p
-
openImage (
string Path)Opens an image.
- @p
Pathis a file path or URL accepted by the manager. - @r
ABufferedImage Java object.
- @p
-
openFile (
string Path)Opens a text file.
- @p
Pathis a file path or URL accepted by the manager. - @r
AReader Java object.
- @p