Class Frameset
- java.lang.Object
-
- org.schabi.newpipe.extractor.stream.Frameset
-
- All Implemented Interfaces:
java.io.Serializable
public final class Frameset extends java.lang.Object implements java.io.Serializable
Class to handle framesets / storyboards which summarize the stream content.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Frameset(java.util.List<java.lang.String> urls, int frameWidth, int frameHeight, int totalCount, int durationPerFrame, int framesPerPageX, int framesPerPageY)
Creates a new Frameset or set of storyboards.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getDurationPerFrame()
int[]
getFrameBoundsAt(long position)
Returns the information for the frame at stream position.int
getFrameHeight()
int
getFramesPerPageX()
int
getFramesPerPageY()
int
getFrameWidth()
int
getTotalCount()
java.util.List<java.lang.String>
getUrls()
-
-
-
Constructor Detail
-
Frameset
public Frameset(java.util.List<java.lang.String> urls, int frameWidth, int frameHeight, int totalCount, int durationPerFrame, int framesPerPageX, int framesPerPageY)
Creates a new Frameset or set of storyboards.- Parameters:
urls
- the URLs to the images with frames / storyboardsframeWidth
- the width of a single frame, in pixelsframeHeight
- the height of a single frame, in pixelstotalCount
- the total count of framesdurationPerFrame
- the duration per frame in millisecondsframesPerPageX
- the maximum count of frames per page by x / over the width of the imageframesPerPageY
- the maximum count of frames per page by y / over the height of the image
-
-
Method Detail
-
getUrls
public java.util.List<java.lang.String> getUrls()
- Returns:
- list of URLs to images with frames
-
getTotalCount
public int getTotalCount()
- Returns:
- total count of frames
-
getFramesPerPageX
public int getFramesPerPageX()
- Returns:
- maximum frames count by x
-
getFramesPerPageY
public int getFramesPerPageY()
- Returns:
- maximum frames count by y
-
getFrameWidth
public int getFrameWidth()
- Returns:
- width of a one frame, in pixels
-
getFrameHeight
public int getFrameHeight()
- Returns:
- height of a one frame, in pixels
-
getDurationPerFrame
public int getDurationPerFrame()
- Returns:
- duration per frame in milliseconds
-
getFrameBoundsAt
public int[] getFrameBoundsAt(long position)
Returns the information for the frame at stream position.- Parameters:
position
- Position in milliseconds- Returns:
- An
int
-array containing the bounds and URL where the indexes are specified as follows:0
: Index of the URL1
: Left bound2
: Top bound3
: Right bound4
: Bottom bound
-
-