Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
8a7eba01
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
8a7eba01
编写于
6月 02, 2023
作者:
D
dongxinli
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
camera上库
Signed-off-by:
N
dongxinli
<
dongxinli@huawei.com
>
上级
e21f53ab
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
45 addition
and
25 deletion
+45
-25
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraEnumTest.test.ets
..._standard/entry/src/main/ets/test/CameraEnumTest.test.ets
+14
-3
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraErrorCodeUsecaseTest.test.ets
...try/src/main/ets/test/CameraErrorCodeUsecaseTest.test.ets
+7
-3
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraJSUnitOutput.test.ets
...ndard/entry/src/main/ets/test/CameraJSUnitOutput.test.ets
+9
-4
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraManagerTest.test.ets
...andard/entry/src/main/ets/test/CameraManagerTest.test.ets
+2
-2
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionBaseTest.test.ets
...rd/entry/src/main/ets/test/CameraSessionBaseTest.test.ets
+2
-2
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionExposureTest.test.ets
...ntry/src/main/ets/test/CameraSessionExposureTest.test.ets
+3
-3
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionFlashTest.test.ets
...d/entry/src/main/ets/test/CameraSessionFlashTest.test.ets
+2
-2
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionFocusTest.test.ets
...d/entry/src/main/ets/test/CameraSessionFocusTest.test.ets
+2
-2
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionVideoStabilizationTest.test.ets
...ain/ets/test/CameraSessionVideoStabilizationTest.test.ets
+2
-2
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionZoomRatioTest.test.ets
...try/src/main/ets/test/CameraSessionZoomRatioTest.test.ets
+2
-2
未找到文件。
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraEnumTest.test.ets
浏览文件 @
8a7eba01
...
@@ -96,7 +96,7 @@ export default function cameraEnumTest() {
...
@@ -96,7 +96,7 @@ export default function cameraEnumTest() {
*/
*/
it('SUB_MULTIMEDIA_CAMERA_ENUM_CAMERATYPE_0100', 2, async function (done) {
it('SUB_MULTIMEDIA_CAMERA_ENUM_CAMERATYPE_0100', 2, async function (done) {
console.info("--------------SUB_MULTIMEDIA_CAMERA_ENUM_CAMERATYPE_0100--------------");
console.info("--------------SUB_MULTIMEDIA_CAMERA_ENUM_CAMERATYPE_0100--------------");
console.info("CameraType: "+ JSON.stringify(camera.CameraType));
console.info("CameraType: "
+ JSON.stringify(camera.CameraType));
expect(camera.CameraType.CAMERA_TYPE_DEFAULT == 0).assertTrue();
expect(camera.CameraType.CAMERA_TYPE_DEFAULT == 0).assertTrue();
expect(camera.CameraType.CAMERA_TYPE_WIDE_ANGLE == 1).assertTrue();
expect(camera.CameraType.CAMERA_TYPE_WIDE_ANGLE == 1).assertTrue();
expect(camera.CameraType.CAMERA_TYPE_ULTRA_WIDE == 2).assertTrue();
expect(camera.CameraType.CAMERA_TYPE_ULTRA_WIDE == 2).assertTrue();
...
@@ -301,16 +301,27 @@ export default function cameraEnumTest() {
...
@@ -301,16 +301,27 @@ export default function cameraEnumTest() {
* @tc.level : Level 2
* @tc.level : Level 2
*/
*/
it('SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100', 2, async function (done) {
it('SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100', 2, async function (done) {
console.info("--------------SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100--------------");
console.info(
TAG +
"--------------SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100--------------");
expect(camera.CameraErrorCode.INVALID_ARGUMENT == 7400101).assertTrue();
expect(camera.CameraErrorCode.INVALID_ARGUMENT == 7400101).assertTrue();
console.info(TAG + "--------------INVALID_ARGUMENT--------------");
expect(camera.CameraErrorCode.OPERATION_NOT_ALLOWED == 7400102).assertTrue();
expect(camera.CameraErrorCode.OPERATION_NOT_ALLOWED == 7400102).assertTrue();
console.info(TAG + "--------------OPERATION_NOT_ALLOWED--------------");
expect(camera.CameraErrorCode.SESSION_NOT_CONFIG == 7400103).assertTrue();
expect(camera.CameraErrorCode.SESSION_NOT_CONFIG == 7400103).assertTrue();
console.info(TAG + "--------------SESSION_NOT_CONFIG--------------");
expect(camera.CameraErrorCode.SESSION_NOT_RUNNING == 7400104).assertTrue();
expect(camera.CameraErrorCode.SESSION_NOT_RUNNING == 7400104).assertTrue();
console.info(TAG + "--------------SESSION_NOT_RUNNING--------------");
expect(camera.CameraErrorCode.SESSION_CONFIG_LOCKED == 7400105).assertTrue();
expect(camera.CameraErrorCode.SESSION_CONFIG_LOCKED == 7400105).assertTrue();
console.info(TAG + "--------------SESSION_CONFIG_LOCKED--------------");
expect(camera.CameraErrorCode.DEVICE_SETTING_LOCKED == 7400106).assertTrue();
expect(camera.CameraErrorCode.DEVICE_SETTING_LOCKED == 7400106).assertTrue();
expect(camera.CameraErrorCode.CONFLICT_CAMERA == 7400107).assertTrue();
console.info(TAG + "--------------DEVICE_SETTING_LOCKED--------------");
// expect(camera.CameraErrorCode.CONFLICT_CAMERA == 7400107).assertTrue();
// console.info(TAG + "--------------CONFLICT_CAMERA--------------");
expect(camera.CameraErrorCode.DEVICE_DISABLED == 7400108).assertTrue();
expect(camera.CameraErrorCode.DEVICE_DISABLED == 7400108).assertTrue();
console.info(TAG + "--------------DEVICE_DISABLED--------------");
expect(camera.CameraErrorCode.DEVICE_PREEMPTED == 7400109).assertTrue();
console.info(TAG + "--------------DEVICE_PREEMPTED --------------");
expect(camera.CameraErrorCode.SERVICE_FATAL_ERROR == 7400201).assertTrue();
expect(camera.CameraErrorCode.SERVICE_FATAL_ERROR == 7400201).assertTrue();
console.info(TAG + "--------------SERVICE_FATAL_ERROR--------------");
console.info(TAG + "Entering SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100 ends here");
console.info(TAG + "Entering SUB_MULTIMEDIA_CAMERA_ENUM_CAMERAERRORCODE_0100 ends here");
done();
done();
})
})
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraErrorCodeUsecaseTest.test.ets
浏览文件 @
8a7eba01
...
@@ -26,7 +26,7 @@ let videoProfile = {
...
@@ -26,7 +26,7 @@ let videoProfile = {
audioCodec
:
'audio/mp4a-latm'
,
audioCodec
:
'audio/mp4a-latm'
,
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -230,7 +230,7 @@ export default function CameraErrorCodeUsecaseTest() {
...
@@ -230,7 +230,7 @@ export default function CameraErrorCodeUsecaseTest() {
async
function
getvideosurface
()
{
async
function
getvideosurface
()
{
await
getFd
(
'ErrorCodeCameraOutput.mp4'
);
await
getFd
(
'ErrorCodeCameraOutput.mp4'
);
videoConfig
.
url
=
fdPath
;
videoConfig
.
url
=
fdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'createVideoRecorder called'
)
console
.
info
(
TAG
+
'createVideoRecorder called'
)
videoRecorder
=
recorder
videoRecorder
=
recorder
...
@@ -334,7 +334,7 @@ export default function CameraErrorCodeUsecaseTest() {
...
@@ -334,7 +334,7 @@ export default function CameraErrorCodeUsecaseTest() {
await
releaseInput
();
await
releaseInput
();
}
}
if
(
!
isEmpty
(
mCameraSession
))
{
if
(
!
isEmpty
(
mCameraSession
))
{
releaseCameraSessionInstance
();
await
releaseCameraSessionInstance
();
}
}
})
})
...
@@ -1712,6 +1712,10 @@ export default function CameraErrorCodeUsecaseTest() {
...
@@ -1712,6 +1712,10 @@ export default function CameraErrorCodeUsecaseTest() {
*/
*/
it
(
'SUB_MULTIMEDIA_CAMERA_ERROR_CODE_USECASE_CAPTURESESSION_GETFOCUSPOINT_0100'
,
0
,
async
function
(
done
)
{
it
(
'SUB_MULTIMEDIA_CAMERA_ERROR_CODE_USECASE_CAPTURESESSION_GETFOCUSPOINT_0100'
,
0
,
async
function
(
done
)
{
console
.
info
(
"--------------SUB_MULTIMEDIA_CAMERA_ERROR_CODE_USECASE_CAPTURESESSION_GETFOCUSPOINT_0100--------------"
);
console
.
info
(
"--------------SUB_MULTIMEDIA_CAMERA_ERROR_CODE_USECASE_CAPTURESESSION_GETFOCUSPOINT_0100--------------"
);
if
(
mCameraSession
){
mCameraSession
.
release
();
mCameraSession
=
null
;
}
await
createInput
(
0
);
await
createInput
(
0
);
createCameraSessionInstance
();
createCameraSessionInstance
();
mCameraSession
.
addInput
(
mCameraInput
);
mCameraSession
.
addInput
(
mCameraInput
);
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraJSUnitOutput.test.ets
浏览文件 @
8a7eba01
...
@@ -40,7 +40,7 @@ let videoProfile = {
...
@@ -40,7 +40,7 @@ let videoProfile = {
audioCodec
:
'audio/mp4a-latm'
,
audioCodec
:
'audio/mp4a-latm'
,
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -96,10 +96,12 @@ export default function cameraJSUnitOutput() {
...
@@ -96,10 +96,12 @@ export default function cameraJSUnitOutput() {
async
function
getFd
(
pathName
)
{
async
function
getFd
(
pathName
)
{
let
displayName
=
pathName
;
let
displayName
=
pathName
;
const
mediaTest
=
mediaLibrary
.
getMediaLibrary
();
const
mediaTest
=
mediaLibrary
.
getMediaLibrary
();
console
.
log
(
TAG
+
'mediaTest: '
+
JSON
.
stringify
(
mediaTest
))
let
fileKeyObj
=
mediaLibrary
.
FileKey
;
let
fileKeyObj
=
mediaLibrary
.
FileKey
;
let
mediaType
=
mediaLibrary
.
MediaType
.
VIDEO
;
let
mediaType
=
mediaLibrary
.
MediaType
.
VIDEO
;
let
publicPath
=
await
mediaTest
.
getPublicDirectory
(
mediaLibrary
.
DirectoryType
.
DIR_VIDEO
);
let
publicPath
=
await
mediaTest
.
getPublicDirectory
(
mediaLibrary
.
DirectoryType
.
DIR_VIDEO
);
let
dataUri
=
await
mediaTest
.
createAsset
(
mediaType
,
displayName
,
publicPath
);
let
dataUri
=
await
mediaTest
.
createAsset
(
mediaType
,
displayName
,
publicPath
);
console
.
log
(
TAG
+
'dataUri id: '
+
JSON
.
stringify
(
dataUri
))
if
(
dataUri
!=
undefined
)
{
if
(
dataUri
!=
undefined
)
{
let
args
=
dataUri
.
id
.
toString
();
let
args
=
dataUri
.
id
.
toString
();
let
fetchOp
=
{
let
fetchOp
=
{
...
@@ -109,6 +111,7 @@ export default function cameraJSUnitOutput() {
...
@@ -109,6 +111,7 @@ export default function cameraJSUnitOutput() {
let
fetchFileResult
=
await
mediaTest
.
getFileAssets
(
fetchOp
);
let
fetchFileResult
=
await
mediaTest
.
getFileAssets
(
fetchOp
);
fileAsset
=
await
fetchFileResult
.
getAllObject
();
fileAsset
=
await
fetchFileResult
.
getAllObject
();
fdNumber
=
await
fileAsset
[
0
]
.
open
(
'Rw'
);
fdNumber
=
await
fileAsset
[
0
]
.
open
(
'Rw'
);
console
.
log
(
TAG
+
'fdNumber id: '
+
JSON
.
stringify
(
fdNumber
))
fdPath
=
"fd://"
+
fdNumber
.
toString
();
fdPath
=
"fd://"
+
fdNumber
.
toString
();
}
}
}
}
...
@@ -127,8 +130,9 @@ export default function cameraJSUnitOutput() {
...
@@ -127,8 +130,9 @@ export default function cameraJSUnitOutput() {
async
function
getvideosurface
()
{
async
function
getvideosurface
()
{
await
getFd
(
'CameraOutput.mp4'
);
await
getFd
(
'CameraOutput.mp4'
);
videoConfig
.
url
=
fdPath
;
await
sleep
(
2000
);
media
.
createVideoRecorder
((
err
,
recorder
)
=>
{
videoConfig
.
url
=
fdPath
;
media
.
createAVRecorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'createVideoRecorder called'
)
console
.
info
(
TAG
+
'createVideoRecorder called'
)
videoRecorder
=
recorder
videoRecorder
=
recorder
...
@@ -152,7 +156,7 @@ export default function cameraJSUnitOutput() {
...
@@ -152,7 +156,7 @@ export default function cameraJSUnitOutput() {
})
})
}
}
else
{
else
{
console
.
info
(
TAG
+
'createVideoRecorder FAILED
'
)
console
.
info
(
TAG
+
'createVideoRecorder FAILED
,Code'
+
err
.
code
)
}
}
})
})
}
}
...
@@ -195,6 +199,7 @@ export default function cameraJSUnitOutput() {
...
@@ -195,6 +199,7 @@ export default function cameraJSUnitOutput() {
beforeAll
(
async
function
()
{
beforeAll
(
async
function
()
{
await
getImageReceiverSurfaceId
();
await
getImageReceiverSurfaceId
();
await
getvideosurface
();
await
getvideosurface
();
sleep
(
2000
);
console
.
info
(
'beforeAll case'
);
console
.
info
(
'beforeAll case'
);
})
})
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraManagerTest.test.ets
浏览文件 @
8a7eba01
...
@@ -42,7 +42,7 @@ let mVideoProfileCfg = {
...
@@ -42,7 +42,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -111,7 +111,7 @@ export default function cameraManagerTest() {
...
@@ -111,7 +111,7 @@ export default function cameraManagerTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraManager.mp4'
);
await
getFd
(
'CameraManager.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionBaseTest.test.ets
浏览文件 @
8a7eba01
...
@@ -51,7 +51,7 @@ let mVideoProfileCfg = {
...
@@ -51,7 +51,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -133,7 +133,7 @@ export default function cameraSessionTest() {
...
@@ -133,7 +133,7 @@ export default function cameraSessionTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionBase.mp4'
);
await
getFd
(
'CameraSessionBase.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionExposureTest.test.ets
浏览文件 @
8a7eba01
...
@@ -56,7 +56,7 @@ let mVideoProfileCfg = {
...
@@ -56,7 +56,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -188,7 +188,7 @@ export default function cameraSessionExposureTest() {
...
@@ -188,7 +188,7 @@ export default function cameraSessionExposureTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionExposure.mp4'
);
await
getFd
(
'CameraSessionExposure.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
@@ -1322,7 +1322,7 @@ export default function cameraSessionExposureTest() {
...
@@ -1322,7 +1322,7 @@ export default function cameraSessionExposureTest() {
for
(
let
i
=
0
;
i
<
mCameraNum
;
i
++
)
{
for
(
let
i
=
0
;
i
<
mCameraNum
;
i
++
)
{
console
.
info
(
TAG
+
"Entering SUB_MULTIMEDIA_CAMERA_SESSION_SET_GET_EXPOSURE_BIAS_PROMISE_0100 start for camera["
+
i
+
"]"
);
console
.
info
(
TAG
+
"Entering SUB_MULTIMEDIA_CAMERA_SESSION_SET_GET_EXPOSURE_BIAS_PROMISE_0100 start for camera["
+
i
+
"]"
);
let
exposureBias
=
mExposureBiasRangeArray
[
i
][
0
];
let
exposureBias
=
mExposureBiasRangeArray
[
i
][
0
];
if
(
exposureBias
==
0
)
{
if
(
exposureBias
==
0
||
isNaN
(
exposureBias
)
)
{
console
.
info
(
TAG
+
"Entering SUB_MULTIMEDIA_CAMERA_SESSION_SET_GET_EXPOSURE_BIAS_PROMISE_0100 exposureBias is 0"
);
console
.
info
(
TAG
+
"Entering SUB_MULTIMEDIA_CAMERA_SESSION_SET_GET_EXPOSURE_BIAS_PROMISE_0100 exposureBias is 0"
);
}
else
{
}
else
{
await
startCameraSession
(
i
);
await
startCameraSession
(
i
);
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionFlashTest.test.ets
浏览文件 @
8a7eba01
...
@@ -54,7 +54,7 @@ let mVideoProfileCfg = {
...
@@ -54,7 +54,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -139,7 +139,7 @@ export default function cameraSessionFlashTest() {
...
@@ -139,7 +139,7 @@ export default function cameraSessionFlashTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionFlush.mp4'
);
await
getFd
(
'CameraSessionFlush.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionFocusTest.test.ets
浏览文件 @
8a7eba01
...
@@ -53,7 +53,7 @@ let mVideoProfileCfg = {
...
@@ -53,7 +53,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -185,7 +185,7 @@ export default function cameraSessionFocusTest() {
...
@@ -185,7 +185,7 @@ export default function cameraSessionFocusTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionFocus.mp4'
);
await
getFd
(
'CameraSessionFocus.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionVideoStabilizationTest.test.ets
浏览文件 @
8a7eba01
...
@@ -53,7 +53,7 @@ let mVideoProfileCfg = {
...
@@ -53,7 +53,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -138,7 +138,7 @@ export default function cameraSessionVideoStabilizationTest() {
...
@@ -138,7 +138,7 @@ export default function cameraSessionVideoStabilizationTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionVideoStabilization.mp4'
);
await
getFd
(
'CameraSessionVideoStabilization.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
multimedia/camera/camera_js_standard/entry/src/main/ets/test/CameraSessionZoomRatioTest.test.ets
浏览文件 @
8a7eba01
...
@@ -55,7 +55,7 @@ let mVideoProfileCfg = {
...
@@ -55,7 +55,7 @@ let mVideoProfileCfg = {
audioSampleRate
:
48000
,
audioSampleRate
:
48000
,
durationTime
:
1000
,
durationTime
:
1000
,
fileFormat
:
'mp4'
,
fileFormat
:
'mp4'
,
videoBitrate
:
48
000
,
videoBitrate
:
2000
000
,
videoCodec
:
'video/mp4v-es'
,
videoCodec
:
'video/mp4v-es'
,
videoFrameWidth
:
640
,
videoFrameWidth
:
640
,
videoFrameHeight
:
480
,
videoFrameHeight
:
480
,
...
@@ -140,7 +140,7 @@ export default function cameraSessionZoomRatioTest() {
...
@@ -140,7 +140,7 @@ export default function cameraSessionZoomRatioTest() {
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
console
.
log
(
TAG
+
'Entering getVideoReceiveSurface'
)
await
getFd
(
'CameraSessionZoomRatio.mp4'
);
await
getFd
(
'CameraSessionZoomRatio.mp4'
);
mVideoConfig
.
url
=
mFdPath
;
mVideoConfig
.
url
=
mFdPath
;
media
.
create
Video
Recorder
((
err
,
recorder
)
=>
{
media
.
create
AV
Recorder
((
err
,
recorder
)
=>
{
if
(
!
err
)
{
if
(
!
err
)
{
console
.
info
(
TAG
+
'Entering create video receiver'
)
console
.
info
(
TAG
+
'Entering create video receiver'
)
mVideoRecorder
=
recorder
mVideoRecorder
=
recorder
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录