-
-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new buffer format implementations
- Loading branch information
Showing
4 changed files
with
94 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 40 additions & 0 deletions
40
.../caprica/vlcj/player/embedded/videosurface/callback/format/StandardAlphaBufferFormat.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/* | ||
* This file is part of VLCJ. | ||
* | ||
* VLCJ is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* VLCJ 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 General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with VLCJ. If not, see <http://www.gnu.org/licenses/>. | ||
* | ||
* Copyright 2009-2024 Caprica Software Limited. | ||
*/ | ||
|
||
package uk.co.caprica.vlcj.player.embedded.videosurface.callback.format; | ||
|
||
import uk.co.caprica.vlcj.player.embedded.videosurface.callback.BufferFormat; | ||
|
||
/** | ||
* Implementation of a buffer format for RV32. | ||
* <p> | ||
* BGRA is used, a 32-bit BGR format with alpha in a single plane. | ||
*/ | ||
public class StandardAlphaBufferFormat extends BufferFormat { | ||
|
||
/** | ||
* Creates a RV32 buffer format with the given width and height. | ||
* | ||
* @param width width of the buffer | ||
* @param height height of the buffer | ||
*/ | ||
public StandardAlphaBufferFormat(int width, int height) { | ||
super("BGRA", width, height, 4); | ||
} | ||
} |
40 changes: 40 additions & 0 deletions
40
...caprica/vlcj/player/embedded/videosurface/callback/format/StandardOpaqueBufferFormat.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/* | ||
* This file is part of VLCJ. | ||
* | ||
* VLCJ is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* VLCJ 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 General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with VLCJ. If not, see <http://www.gnu.org/licenses/>. | ||
* | ||
* Copyright 2009-2024 Caprica Software Limited. | ||
*/ | ||
|
||
package uk.co.caprica.vlcj.player.embedded.videosurface.callback.format; | ||
|
||
import uk.co.caprica.vlcj.player.embedded.videosurface.callback.BufferFormat; | ||
|
||
/** | ||
* Implementation of a standard opaque buffer format. | ||
* <p> | ||
* RV24 is used, a 24-bit RGB format in a single plane. | ||
*/ | ||
public class StandardOpaqueBufferFormat extends BufferFormat { | ||
|
||
/** | ||
* Creates a RV32 buffer format with the given width and height. | ||
* | ||
* @param width width of the buffer | ||
* @param height height of the buffer | ||
*/ | ||
public StandardOpaqueBufferFormat(int width, int height) { | ||
super("RV24", width, height, 3); | ||
} | ||
} |