Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
mediastreamer2
Commits
0981b952
Commit
0981b952
authored
Sep 30, 2011
by
Sylvain Berfini
Browse files
Activate AutoFocus modified
parent
041744e5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
java/src/org/linphone/mediastream/video/capture/AndroidVideoApi5JniWrapper.java
...mediastream/video/capture/AndroidVideoApi5JniWrapper.java
+4
-4
No files found.
java/src/org/linphone/mediastream/video/capture/AndroidVideoApi5JniWrapper.java
View file @
0981b952
...
...
@@ -78,8 +78,8 @@ public class AndroidVideoApi5JniWrapper {
static
public
void
activateAutoFocus
(
Object
cam
)
{
Log
.
d
(
"mediastreamer"
,
"Turning on autofocus on camera "
+
cam
);
Camera
camera
=
(
Camera
)
cam
;
if
(
camera
.
getParameters
().
getFocusMode
()
==
Parameters
.
FOCUS_MODE_AUTO
||
camera
.
getParameters
().
getFocusMode
()
==
Parameters
.
FOCUS_MODE_MACRO
)
camera
.
autoFocus
(
null
);
if
(
camera
!=
null
&&
(
camera
.
getParameters
().
getFocusMode
()
==
Parameters
.
FOCUS_MODE_AUTO
||
camera
.
getParameters
().
getFocusMode
()
==
Parameters
.
FOCUS_MODE_MACRO
)
)
camera
.
autoFocus
(
null
);
// We don't need to do anything after the focus finished, so we don't need a callback
}
public
static
Object
startRecording
(
int
cameraId
,
int
width
,
int
height
,
int
fps
,
int
rotation
,
final
long
nativePtr
)
{
...
...
@@ -93,8 +93,8 @@ public class AndroidVideoApi5JniWrapper {
// forward image data to JNI
putImage
(
nativePtr
,
data
);
}
});
});
camera
.
startPreview
();
Log
.
d
(
"mediastreamer"
,
"Returning camera object: "
+
camera
);
return
camera
;
...
...
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