Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
fbe32b99
Commit
fbe32b99
authored
Dec 09, 2007
by
Philippe Morin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update snapshot method.
parent
181b5884
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
bindings/java/VLCExample.java
bindings/java/VLCExample.java
+1
-1
bindings/java/src/video-jni.cc
bindings/java/src/video-jni.cc
+5
-3
No files found.
bindings/java/VLCExample.java
View file @
fbe32b99
...
@@ -77,7 +77,7 @@ public class VLCExample
...
@@ -77,7 +77,7 @@ public class VLCExample
System
.
out
.
println
(
"real size."
);
System
.
out
.
println
(
"real size."
);
jvlc
.
video
.
setFullscreen
(
false
);
jvlc
.
video
.
setFullscreen
(
false
);
System
.
out
.
print
(
"Taking snapshot... "
);
System
.
out
.
print
(
"Taking snapshot... "
);
jvlc
.
video
.
getSnapshot
(
System
.
getProperty
(
"user.dir"
)
+
"/snap.png"
);
jvlc
.
video
.
getSnapshot
(
System
.
getProperty
(
"user.dir"
)
+
"/snap.png"
,
0
,
0
);
System
.
out
.
println
(
"taken. (see "
+
System
.
getProperty
(
"user.dir"
)
+
"/snap.png )"
);
System
.
out
.
println
(
"taken. (see "
+
System
.
getProperty
(
"user.dir"
)
+
"/snap.png )"
);
Thread
.
sleep
(
2000
);
Thread
.
sleep
(
2000
);
System
.
out
.
println
(
"Resizing to 300x300"
);
System
.
out
.
println
(
"Resizing to 300x300"
);
...
...
bindings/java/src/video-jni.cc
View file @
fbe32b99
...
@@ -25,14 +25,16 @@
...
@@ -25,14 +25,16 @@
/* These are a must*/
/* These are a must*/
#include <jni.h>
#include <jni.h>
#include <jawt.h>
#include <vlc/libvlc.h>
#include <vlc/libvlc.h>
#include <stdio.h>
/* JVLC internal imports, generated by gcjh */
/* JVLC internal imports, generated by gcjh */
#include "../includes/Video.h"
#include "../includes/Video.h"
#include "utils.h"
#include "utils.h"
#include <stdio.h>
JNIEXPORT
void
JNICALL
Java_org_videolan_jvlc_Video__1toggleFullscreen
(
JNIEnv
*
env
,
jobject
_this
)
JNIEXPORT
void
JNICALL
Java_org_videolan_jvlc_Video__1toggleFullscreen
(
JNIEnv
*
env
,
jobject
_this
)
{
{
...
@@ -104,7 +106,7 @@ JNIEXPORT jint JNICALL Java_org_videolan_jvlc_Video__1getWidth (JNIEnv *env, job
...
@@ -104,7 +106,7 @@ JNIEXPORT jint JNICALL Java_org_videolan_jvlc_Video__1getWidth (JNIEnv *env, job
return
res
;
return
res
;
}
}
JNIEXPORT
void
JNICALL
Java_org_videolan_jvlc_Video__1getSnapshot
(
JNIEnv
*
env
,
jobject
_this
,
jstring
filepath
)
JNIEXPORT
void
JNICALL
Java_org_videolan_jvlc_Video__1getSnapshot
(
JNIEnv
*
env
,
jobject
_this
,
jstring
filepath
,
jint
width
,
jint
height
)
{
{
INIT_FUNCTION
;
INIT_FUNCTION
;
...
@@ -112,7 +114,7 @@ JNIEXPORT void JNICALL Java_org_videolan_jvlc_Video__1getSnapshot (JNIEnv *env,
...
@@ -112,7 +114,7 @@ JNIEXPORT void JNICALL Java_org_videolan_jvlc_Video__1getSnapshot (JNIEnv *env,
GET_INPUT_THREAD
;
GET_INPUT_THREAD
;
libvlc_video_take_snapshot
(
input
,
(
char
*
)
psz_filepath
,
&
exception
);
libvlc_video_take_snapshot
(
input
,
(
char
*
)
psz_filepath
,
(
unsigned
int
)
width
,(
unsigned
int
)
height
,
&
exception
);
libvlc_media_instance_release
(
input
);
libvlc_media_instance_release
(
input
);
CHECK_EXCEPTION
;
CHECK_EXCEPTION
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment