|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectproject.android.imageprocessing.GLRenderer
project.android.imageprocessing.input.GLTextureOutputRenderer
project.android.imageprocessing.input.VideoResourceInput
public class VideoResourceInput
A video input extension of GLTextureOutputRenderer. This class takes advantage of the android MediaPlayer and SurfaceTexture to produce new textures for processing.
Note: This class requires an API level of at least 14.
Field Summary |
---|
Fields inherited from class project.android.imageprocessing.GLRenderer |
---|
ATTRIBUTE_POSITION, ATTRIBUTE_TEXCOORD, UNIFORM_TEXTURE0, VARYING_TEXCOORD |
Constructor Summary | |
---|---|
VideoResourceInput(android.opengl.GLSurfaceView view,
android.content.Context context,
int id)
Creates a VideoResourceInput which captures the camera preview with all the default camera parameters and settings. |
Method Summary | |
---|---|
void |
destroy()
Cleans up the opengl objects for this renderer. |
boolean |
isPlaying()
Returns whether or not the video is currently playing. |
void |
onFrameAvailable(android.graphics.SurfaceTexture arg0)
|
void |
setVideoSource(int id)
Sets the video to a new video source. |
void |
startWhenReady()
Starts the video player if the opengl context has initialized the video already. |
void |
stop()
Stops the video |
Methods inherited from class project.android.imageprocessing.input.GLTextureOutputRenderer |
---|
addTarget, getLockObject, getTargets, removeTarget |
Methods inherited from class project.android.imageprocessing.GLRenderer |
---|
getBackgroundAlpha, getBackgroundBlue, getBackgroundGreen, getBackgroundRed, getHeight, getWidth, onDrawFrame, reInitialize, rotateClockwise90Degrees, rotateCounterClockwise90Degrees, setBackgroundAlpha, setBackgroundBlue, setBackgroundColour, setBackgroundGreen, setBackgroundRed, setRenderSize |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public VideoResourceInput(android.opengl.GLSurfaceView view, android.content.Context context, int id)
context
- The context which contains the given resource id.id
- The resource id that points to the video that should be displayedMethod Detail |
---|
public void onFrameAvailable(android.graphics.SurfaceTexture arg0)
onFrameAvailable
in interface android.graphics.SurfaceTexture.OnFrameAvailableListener
public void setVideoSource(int id)
id
- The id that points to the video resourcepublic boolean isPlaying()
public void startWhenReady()
public void stop()
public void destroy()
GLRenderer
FastImageProcessingPipeline
.
destroy
in class GLTextureOutputRenderer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |