未验证 提交 dbcb7b17 编写于 作者: O openharmony_ci 提交者: Gitee

!2801 修改音频编码资源文件测试代码+代码整改

Merge pull request !2801 from ling990/OpenHarmony-3.1-Release
......@@ -28,7 +28,6 @@ describe('AudioDecoderEnum', function () {
afterEach(function() {
console.info('afterEach case');
wait(2000);
})
afterAll(function() {
......
......@@ -538,8 +538,7 @@ describe('AudioDecoderReliabilityCallback', function () {
}
}
else{
writeFile(savepath, outputobject.data, outputobject.length);
console.info("write to file success");
console.info("not last frame, continue");
}
audioDecodeProcessor.freeOutputBuffer(outputobject, () => {
console.info('release output success');
......
......@@ -541,8 +541,7 @@ describe('AudioDecoderReliabilityPromise', function () {
}
}
else{
writeFile(savapath, outputobject.data, outputobject.length);
console.info("write to file success");
console.info("not last frame, continue");
}
audioDecodeProcessor.freeOutputBuffer(outputobject).then(() => {
console.info('release output success');
......
{
"description": "Configuration for audioPlayer Tests",
"description": "Configuration for audioEncoder Tests",
"driver": {
"type": "JSUnitTest",
"test-timeout": "2000000",
......@@ -19,8 +19,7 @@
"pre-push": [
],
"push": [
"./resource/audio/audioEncode/S32LE.pcm ->/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/",
"./resource/audio/audioEncode/S32LE_2.pcm ->/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/"
"./resource/audio/audioEncode/S16LE.pcm ->/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/"
]
},
{
......
......@@ -19,8 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from '
describe('AudioEncoderFuncCallback', function () {
const RESOURCEPATH = '/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/'
const AUDIOPATH = RESOURCEPATH + 'S32LE.pcm';
const AUDIOPATH2 = RESOURCEPATH + 'S32LE_2.pcm';
const AUDIOPATH = RESOURCEPATH + 'S16LE.pcm';
const BASIC_PATH = RESOURCEPATH + 'results/encode_func_callback_';
let audioEncodeProcessor;
let readStreamSync;
......@@ -61,7 +60,7 @@ describe('AudioEncoderFuncCallback', function () {
sawOutputEOS = false;
inputQueue = [];
outputQueue = [];
ES_LENGTH = 2000;
ES_LENGTH = 1500;
})
afterEach(async function() {
......@@ -139,8 +138,8 @@ describe('AudioEncoderFuncCallback', function () {
console.info("start add ADTS to Packet");
let packetLen = len + 7; // 7: head length
let profile = 2; // 2: AAC LC
let freqIdx = 3; // 3: 48000HZ
let chanCfg = 1; // 1: 1 channel
let freqIdx = 4; // 4: 44100HZ
let chanCfg = 2; // 2: 2 channel
view[0] = 0xFF;
view[1] = 0xF9;
view[2] = ((profile - 1) << 6) + (freqIdx << 2) + (chanCfg >> 2);
......@@ -163,7 +162,11 @@ describe('AudioEncoderFuncCallback', function () {
expect(err).assertUndefined();
console.info("case reset success");
if (needrelease) {
audioEncodeProcessor = null
audioEncodeProcessor.release((err) => {
expect(err).assertUndefined();
console.info("case release success");
audioEncodeProcessor = null;
})
}
})
}
......@@ -299,14 +302,14 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let mediaDescription2 = {
"codec_mime": 'audio/mp4a-latm',
}
let savepath = BASIC_PATH + 'callback0000.es';
let savepath = BASIC_PATH + '0000.aac';
needGetMediaDes = true;
workdoneAtEOS = true;
eventEmitter.on('getAudioEncoderCaps', () => {
......@@ -382,11 +385,11 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0100.es';
let savepath = BASIC_PATH + '0100.aac';
eosframenum = 500;
workdoneAtEOS = true;
eventEmitter.on('getAudioEncoderCaps', () => {
......@@ -440,11 +443,11 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0200.es';
let savepath = BASIC_PATH + '0200.aac';
workdoneAtEOS = true;
eventEmitter.on('getAudioEncoderCaps', () => {
audioEncodeProcessor.getAudioEncoderCaps((err, Audiocaps) => {
......@@ -506,11 +509,11 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0300.es';
let savepath = BASIC_PATH + '0300.aac';
eosframenum = 500;
flushAtEOS = true;
eventEmitter.on('getAudioEncoderCaps', () => {
......@@ -564,11 +567,11 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0400.es';
let savepath = BASIC_PATH + '0400.aac';
eventEmitter.on('getAudioEncoderCaps', () => {
audioEncodeProcessor.getAudioEncoderCaps((err, Audiocaps) => {
expect(err).assertUndefined();
......@@ -646,11 +649,11 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0500.es';
let savepath = BASIC_PATH + '0500.aac';
eosframenum = 100;
eventEmitter.on('getAudioEncoderCaps', () => {
audioEncodeProcessor.getAudioEncoderCaps((err, Audiocaps) => {
......@@ -725,17 +728,17 @@ describe('AudioEncoderFuncCallback', function () {
let events = require('events');
let eventEmitter = new events.EventEmitter();
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + 'callback0600.es';
let savepath = BASIC_PATH + '0600.aac';
eosframenum = 100;
resetAtEOS = true;
let mediaDescription2 = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let hasreconfigured = false;
eventEmitter.on('getAudioEncoderCaps', () => {
......@@ -777,8 +780,8 @@ describe('AudioEncoderFuncCallback', function () {
expect(err).assertUndefined();
console.info(`case configure 2`);
resetParam();
readFile(AUDIOPATH2)
savepath = BASIC_PATH + 'callback0601.es';
readFile(AUDIOPATH)
savepath = BASIC_PATH + '0601.aac';
workdoneAtEOS = true;
hasreconfigured = true;
eventEmitter.emit('prepare');
......
......@@ -19,8 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from '
describe('AudioEncoderFuncPromise', function () {
const RESOURCEPATH = '/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/'
const AUDIOPATH = RESOURCEPATH + 'S32LE.pcm';
const AUDIOPATH2 = RESOURCEPATH + 'S32LE_2.pcm';
const AUDIOPATH = RESOURCEPATH + 'S16LE.pcm';
const BASIC_PATH = RESOURCEPATH + 'results/encode_func_promise_';
let audioEncodeProcessor;
let readStreamSync;
......@@ -38,7 +37,7 @@ describe('AudioEncoderFuncPromise', function () {
let inputQueue = [];
let outputQueue = [];
const ES = [0, 4096];
let ES_LENGTH = 2000;
let ES_LENGTH = 1500;
beforeAll(function() {
console.info('beforeAll case');
......@@ -61,7 +60,7 @@ describe('AudioEncoderFuncPromise', function () {
sawOutputEOS = false;
inputQueue = [];
outputQueue = [];
ES_LENGTH = 2000;
ES_LENGTH = 1500;
})
afterEach(async function() {
......@@ -150,8 +149,8 @@ describe('AudioEncoderFuncPromise', function () {
console.info("start add ADTS to Packet");
let packetLen = len + 7; // 7: head length
let profile = 2; // 2: AAC LC
let freqIdx = 3; // 3: 48000HZ
let chanCfg = 1; // 1: 1 channel
let freqIdx = 4; // 4: 44100HZ
let chanCfg = 2; // 2: 2 channel
view[0] = 0xFF;
view[1] = 0xF9;
view[2] = ((profile - 1) << 6) + (freqIdx << 2) + (chanCfg >> 2);
......@@ -169,9 +168,12 @@ describe('AudioEncoderFuncPromise', function () {
async function resetWork() {
resetParam();
await audioEncodeProcessor.reset().then(() => {
await audioEncodeProcessor.reset().then(async() => {
console.info("case reset success");
if (needrelease) {
await audioEncodeProcessor.release().then(() => {
console.info("case release success");
}, failCallback).catch(failCatch);
audioEncodeProcessor = null;
}
}, failCallback).catch(failCatch);
......@@ -202,7 +204,6 @@ describe('AudioEncoderFuncPromise', function () {
audioEncodeProcessor = null;
}
function sleep(time) {
return new Promise((resolve) => setTimeout(resolve, time));
}
......@@ -304,14 +305,14 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_00_0100', 0, async function (done) {
console.info("case test set EOS after last frame and reset");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let mediaDescription2 = {
"codec_mime": 'audio/mp4a-latm',
}
let savepath = BASIC_PATH + '0000.es';
let savepath = BASIC_PATH + '0000.aac';
needgetMediaDes = true;
workdoneAtEOS = true;
await media.getMediaCapability().then((mediaCaps) => {
......@@ -369,11 +370,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0100', 0, async function (done) {
console.info("case test set EOS manually before last frame and reset");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0100.es';
let savepath = BASIC_PATH + '0100.aac';
eosframenum = 500;
workdoneAtEOS = true;
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
......@@ -408,11 +409,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0200', 0, async function (done) {
console.info("case test flush at running state");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0200.es';
let savepath = BASIC_PATH + '0200.aac';
workdoneAtEOS = true;
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
console.info("case create createAudioEncoder success");
......@@ -453,11 +454,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0300', 0, async function (done) {
console.info("case test flush at EOS state");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0300.es';
let savepath = BASIC_PATH + '0300.aac';
eosframenum = 500;
flushAtEOS = true;
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
......@@ -492,11 +493,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0400', 0, async function (done) {
console.info("case test stop at running state and reset");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0400.es';
let savepath = BASIC_PATH + '0400.aac';
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
console.info("case create createAudioEncoder success");
audioEncodeProcessor = processor;
......@@ -542,11 +543,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0500', 0, async function (done) {
console.info("case test stop and restart");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0500.es';
let savepath = BASIC_PATH + '0500.aac';
eosframenum = 100;
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
console.info("case create createAudioEncoder success");
......@@ -596,11 +597,11 @@ describe('AudioEncoderFuncPromise', function () {
it('SUB_MEDIA_AUDIO_ENCODER_FUNCTION_PROMISE_01_0600', 0, async function (done) {
console.info("case test reconfigure for new file with the same format");
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
let savepath = BASIC_PATH + '0600.es';
let savepath = BASIC_PATH + '0600.aac';
eosframenum = 100;
resetAtEOS = true;
await media.createAudioEncoderByMime('audio/mp4a-latm').then((processor) => {
......@@ -623,9 +624,9 @@ describe('AudioEncoderFuncPromise', function () {
console.info("case start success");
}, failCallback).catch(failCatch);
let mediaDescription2 = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
}
await sleep(10000).then(() => {
console.info("start configure 2");
......@@ -633,9 +634,9 @@ describe('AudioEncoderFuncPromise', function () {
await audioEncodeProcessor.configure(mediaDescription2).then(() => {
console.info("configure 2 success");
resetParam();
readFile(AUDIOPATH2);
readFile(AUDIOPATH);
}, failCallback).catch(failCatch);
let savepath2 = BASIC_PATH + '0601.es';
let savepath2 = BASIC_PATH + '0601.aac';
workdoneAtEOS = true;
setCallback(savepath2, done);
await audioEncodeProcessor.prepare().then(() => {
......
......@@ -19,7 +19,7 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from '
describe('AudioEncoderFuncPromise', function () {
const RESOURCEPATH = '/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/'
const AUDIOPATH = RESOURCEPATH + 'S32LE.pcm';
const AUDIOPATH = RESOURCEPATH + 'S16LE.pcm';
let readStreamSync;
let eosframenum = 0;
let stopAtEOS = false;
......@@ -35,7 +35,7 @@ describe('AudioEncoderFuncPromise', function () {
let inputQueue = [];
let outputQueue = [];
const ES = [0, 4096];
let ES_LENGTH = 2000;
let ES_LENGTH = 1500;
beforeAll(function() {
console.info('beforeAll case');
......@@ -57,7 +57,7 @@ describe('AudioEncoderFuncPromise', function () {
sawOutputEOS = false;
inputQueue = [];
outputQueue = [];
ES_LENGTH = 2000;
ES_LENGTH = 1500;
})
afterEach(function() {
......@@ -140,8 +140,8 @@ describe('AudioEncoderFuncPromise', function () {
console.info("start add ADTS to Packet");
let packetLen = len + 7; // 7: head length
let profile = 2; // 2: AAC LC
let freqIdx = 3; // 3: 48000HZ
let chanCfg = 1; // 1: 1 channel
let freqIdx = 4; // 4: 44100HZ
let chanCfg = 2; // 2: 2 channel
view[0] = 0xFF;
view[1] = 0xF9;
view[2] = ((profile - 1) << 6) + (freqIdx << 2) + (chanCfg >> 2);
......@@ -159,9 +159,12 @@ describe('AudioEncoderFuncPromise', function () {
async function resetWork(audioEncodeProcessor) {
resetParam();
await audioEncodeProcessor.reset().then(() => {
await audioEncodeProcessor.reset().then(async() => {
console.info("case reset success");
if (needrelease) {
await audioEncodeProcessor.release().then(() => {
console.info("case release success");
}, failCallback).catch(failCatch);
audioEncodeProcessor = null;
}
}, failCallback).catch(failCatch);
......@@ -309,8 +312,8 @@ describe('AudioEncoderFuncPromise', function () {
}, failCallback).catch(failCatch);
await array[j].release().then(() => {
console.info("case release success");
array[j] = null;
}, failCallback).catch(failCatch);
array[j] = null;
}
done();
})
......
......@@ -17,9 +17,9 @@ import media from '@ohos.multimedia.media'
import Fileio from '@ohos.fileio'
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'
describe('AudioEncoderSTTCallback', function () {
describe('AudioEncoderReliabilityCallback', function () {
const RESOURCEPATH = '/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/'
const AUDIOPATH = RESOURCEPATH + 'S32LE.pcm';
const AUDIOPATH = RESOURCEPATH + 'S16LE.pcm';
const BASIC_PATH = RESOURCEPATH + 'results/encode_reliability_callback_';
const END = 0;
const CONFIGURE = 1;
......@@ -54,9 +54,9 @@ describe('AudioEncoderSTTCallback', function () {
let ES_LENGTH = 200;
let mime = 'audio/mp4a-latm';
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
};
beforeAll(function() {
......@@ -86,8 +86,8 @@ describe('AudioEncoderSTTCallback', function () {
if (audioEncodeProcessor != null) {
await audioEncodeProcessor.release().then(() => {
console.info('audioEncodeProcessor release success');
audioEncodeProcessor = null;
}, failCallback).catch(failCatch);
audioEncodeProcessor = null;
}
})
......@@ -165,8 +165,8 @@ describe('AudioEncoderSTTCallback', function () {
console.info("start add ADTS to Packet");
let packetLen = len + 7; // 7: head length
let profile = 2; // 2: AAC LC
let freqIdx = 3; // 3: 48000HZ
let chanCfg = 1; // 1: 1 channel
let freqIdx = 4; // 4: 44100HZ
let chanCfg = 2; // 2: 2 channel
view[0] = 0xFF;
view[1] = 0xF9;
view[2] = ((profile - 1) << 6) + (freqIdx << 2) + (chanCfg >> 2);
......@@ -386,9 +386,7 @@ describe('AudioEncoderSTTCallback', function () {
}
}
else{
writeHead(savepath, outputobject.length);
writeFile(savepath, outputobject.data, outputobject.length);
console.info("write to file success");
console.info("not last frame, continue");
}
audioEncodeProcessor.freeOutputBuffer(outputobject, () => {
console.info('release output success');
......
......@@ -17,9 +17,9 @@ import media from '@ohos.multimedia.media'
import Fileio from '@ohos.fileio'
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index'
describe('AudioEncoderSTTPromise', function () {
describe('AudioEncoderReliabilityPromise', function () {
const RESOURCEPATH = '/data/accounts/account_0/appdata/ohos.acts.multimedia.audio.audioencoder/'
const AUDIOPATH = RESOURCEPATH + 'S32LE.pcm';
const AUDIOPATH = RESOURCEPATH + 'S16LE.pcm';
const BASIC_PATH = RESOURCEPATH + 'results/encode_reliability_promise_';
const END = 0;
const CONFIGURE = 1;
......@@ -54,9 +54,9 @@ describe('AudioEncoderSTTPromise', function () {
let ES_LENGTH = 200;
let mime = 'audio/mp4a-latm';
let mediaDescription = {
"channel_count": 1,
"sample_rate": 48000,
"audio_sample_format": 3,
"channel_count": 2,
"sample_rate": 44100,
"audio_sample_format": 1,
};
let expectError = false;
......@@ -88,8 +88,8 @@ describe('AudioEncoderSTTPromise', function () {
if (audioEncodeProcessor != null) {
await audioEncodeProcessor.release().then(() => {
console.info('audioEncodeProcessor release success');
audioEncodeProcessor = null;
}, failCallback).catch(failCatch);
audioEncodeProcessor = null;
}
})
......@@ -183,8 +183,8 @@ describe('AudioEncoderSTTPromise', function () {
console.info("start add ADTS to Packet");
let packetLen = len + 7; // 7: head length
let profile = 2; // 2: AAC LC
let freqIdx = 3; // 3: 48000HZ
let chanCfg = 1; // 1: 1 channel
let freqIdx = 4; // 4: 44100HZ
let chanCfg = 2; // 2: 2 channel
view[0] = 0xFF;
view[1] = 0xF9;
view[2] = ((profile - 1) << 6) + (freqIdx << 2) + (chanCfg >> 2);
......@@ -391,9 +391,7 @@ describe('AudioEncoderSTTPromise', function () {
}
}
else{
writeHead(savepath, outputobject.length);
writeFile(savepath, outputobject.data, outputobject.length);
console.info("write to file success");
console.info("not last frame, continue");
}
audioEncodeProcessor.freeOutputBuffer(outputobject).then(() => {
console.info('release output success');
......
......@@ -136,10 +136,8 @@ describe('VideoDecoderEnum', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs(){
async function enqueueInputs(inputObject) {
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, ES_FRAME_SIZE[frameCountIn]);
......@@ -171,13 +169,9 @@ describe('VideoDecoderEnum', function () {
console.info('in case: queueInput success ');
}, failCallback).catch(failCatch);
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep){
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject){
if (outputObject.flags == 1) {
nextStep();
return;
......@@ -187,7 +181,6 @@ describe('VideoDecoderEnum', function () {
console.log('in case: release output count:' + frameCountOut);
}, failCallback).catch(failCatch);
}
}
function setCallback(nextStep){
console.info('in case: setCallback in');
......@@ -204,8 +197,7 @@ describe('VideoDecoderEnum', function () {
console.info('in case: inputBufferAvailable inBuffer.flags: '+ inBuffer.flags);
expect(inBuffer.timeMs !== undefined).assertTrue();
console.info('in case: inputBufferAvailable inBuffer.timeMs: '+ inBuffer.timeMs);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
......@@ -213,8 +205,7 @@ describe('VideoDecoderEnum', function () {
videoDecodeProcessor.getOutputMediaDescription().then((MediaDescription) => {
console.info('get outputMediaDescription : ' + MediaDescription);
}, failCallback).catch(failCatch);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -177,10 +177,7 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs(){
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, ES_FRAME_SIZE[frameCountIn]);
......@@ -217,19 +214,15 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
})
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep){
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject){
if (outputObject.flags == 1 ) {
nextStep();
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject, (err) => {
videoDecodeProcessor.freeOutputBuffer(outputObject, (err) => {
if (typeof (err) == 'undefined') {
console.log('in case: release output count:' + frameCountOut);
} else {
......@@ -237,14 +230,12 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
})
}
}
function setCallback(nextStep){
console.info('in case: setCallback in');
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
......@@ -253,8 +244,7 @@ describe('VideoDecoderFuncCallbackTest', function () {
expect(err).assertUndefined();
console.info('get outputMediaDescription : ' + MediaDescription);
});
outputQueue.push(outBuffer);
dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -188,10 +188,7 @@ describe('VideoDecoderFuncPromiseTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs(){
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, ES_FRAME_SIZE[frameCountIn]);
......@@ -223,30 +220,24 @@ describe('VideoDecoderFuncPromiseTest', function () {
console.info('in case: queueInput success ');
}, failCallback).catch(failCatch);
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep){
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1) {
nextStep();
return;
}
frameCountOut++;
await videoDecodeProcessor.renderOutputData(outputObject).then(() => {
await videoDecodeProcessor.freeOutputBuffer(outputObject).then(() => {
console.log('in case: release output count:' + frameCountOut);
}, failCallback).catch(failCatch);
}
}
function setCallback(nextStep){
console.info('in case: setCallback in');
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
......@@ -254,8 +245,7 @@ describe('VideoDecoderFuncPromiseTest', function () {
videoDecodeProcessor.getOutputMediaDescription().then((MediaDescription) => {
console.info('get outputMediaDescription : ' + MediaDescription);
}, failCallback).catch(failCatch);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -172,10 +172,7 @@ describe('VideoDecoderReliCallbackTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs() {
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, position, ES_FRAME_SIZE[frameCountIn]);
......@@ -201,13 +198,9 @@ describe('VideoDecoderReliCallbackTest', function () {
console.info('in case: queueInput success ');
})
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep) {
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1 ) {
if (workdoneAtEOS) {
doneWork(nextStep);
......@@ -215,11 +208,10 @@ describe('VideoDecoderReliCallbackTest', function () {
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject, () => {
videoDecodeProcessor.freeOutputBuffer(outputObject, () => {
console.log('in case: release output count:' + frameCountOut);
})
}
}
function toConfigure(mySteps, done, expectFail) {
videoDecodeProcessor.configure(mediaDescription, (err) => {
......@@ -399,14 +391,12 @@ describe('VideoDecoderReliCallbackTest', function () {
function setCallback(nextStep){
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -177,10 +177,7 @@ describe('VideoDecoderReliPromiseTest', function () {
}
}
/* push inputbuffers into codec */
async function enqueueInputs() {
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, position, ES_FRAME_SIZE[frameCountIn]);
......@@ -206,13 +203,9 @@ describe('VideoDecoderReliPromiseTest', function () {
console.info('in case: queueInput success ');
}, caseCallback).catch(failCatch);
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep) {
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1 ) {
if (workdoneAtEOS) {
await doneWork();
......@@ -221,12 +214,11 @@ describe('VideoDecoderReliPromiseTest', function () {
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject).then(() => {
videoDecodeProcessor.freeOutputBuffer(outputObject).then(() => {
console.info('in case: release output success');
console.log('in case: release output count:' + frameCountOut);
}, caseCallback).catch(failCatch);
}
}
function toConfigure(mySteps, done, failureCallback, catchCallback) {
videoDecodeProcessor.configure(mediaDescription).then(() => {
......@@ -396,14 +388,12 @@ describe('VideoDecoderReliPromiseTest', function () {
function setCallback(nextStep){
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -189,10 +189,7 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs(){
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, ES_FRAME_SIZE[frameCountIn]);
......@@ -222,19 +219,15 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
})
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep){
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1 ) {
nextStep();
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject, (err) => {
videoDecodeProcessor.freeOutputBuffer(outputObject, (err) => {
if (typeof (err) == 'undefined') {
console.log('in case: release output count:' + frameCountOut);
} else {
......@@ -242,20 +235,17 @@ describe('VideoDecoderFuncCallbackTest', function () {
}
})
}
}
function setCallback(nextStep){
console.info('in case: setCallback in');
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -191,10 +191,7 @@ describe('VideoDecoderFuncPromiseTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs(){
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, ES_FRAME_SIZE[frameCountIn]);
......@@ -219,36 +216,29 @@ describe('VideoDecoderFuncPromiseTest', function () {
console.info('in case: queueInput success ');
}, failCallback).catch(failCatch);
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep){
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1) {
nextStep();
return;
}
frameCountOut++;
await videoDecodeProcessor.renderOutputData(outputObject).then(() => {
await videoDecodeProcessor.freeOutputBuffer(outputObject).then(() => {
console.log('in case: release output count:' + frameCountOut);
}, failCallback).catch(failCatch);
}
}
function setCallback(nextStep){
console.info('in case: setCallback in');
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -172,10 +172,7 @@ describe('VideoDecoderSoftwareReliCallbackTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs() {
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, position, ES_FRAME_SIZE[frameCountIn]);
......@@ -201,13 +198,9 @@ describe('VideoDecoderSoftwareReliCallbackTest', function () {
console.info('in case: queueInput success ');
})
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep) {
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1 ) {
if (workdoneAtEOS) {
doneWork(nextStep);
......@@ -215,11 +208,10 @@ describe('VideoDecoderSoftwareReliCallbackTest', function () {
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject, () => {
videoDecodeProcessor.freeOutputBuffer(outputObject, () => {
console.log('in case: release output count:' + frameCountOut);
})
}
}
function toConfigure(mySteps, done, expectFail) {
videoDecodeProcessor.configure(mediaDescription, (err) => {
......@@ -400,14 +392,12 @@ describe('VideoDecoderSoftwareReliCallbackTest', function () {
function setCallback(nextStep){
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
......@@ -179,10 +179,7 @@ describe('VideoDecoderSoftwareReliPromiseTest', function () {
}
/* push inputbuffers into codec */
async function enqueueInputs() {
console.info('in case: enqueueInputs in');
while (inputQueue.length > 0 && !inputEosFlag) {
let inputObject = inputQueue.shift();
async function enqueueInputs(inputObject) {
console.log('in case: inputObject.index: ' + inputObject.index);
if (frameCountIn < ES_FRAME_SIZE.length) {
getContent(inputObject.data, position, ES_FRAME_SIZE[frameCountIn]);
......@@ -208,13 +205,9 @@ describe('VideoDecoderSoftwareReliPromiseTest', function () {
console.info('in case: queueInput success ');
}, caseCallback).catch(failCatch);
}
}
/* get outputbuffers from codec */
async function dequeueOutputs(nextStep) {
console.log('outputQueue.length:' + outputQueue.length);
while (outputQueue.length > 0){
let outputObject = outputQueue.shift();
async function dequeueOutputs(nextStep, outputObject) {
if (outputObject.flags == 1 ) {
if (workdoneAtEOS) {
await doneWork();
......@@ -223,12 +216,11 @@ describe('VideoDecoderSoftwareReliPromiseTest', function () {
return;
}
frameCountOut++;
videoDecodeProcessor.renderOutputData(outputObject).then(() => {
videoDecodeProcessor.freeOutputBuffer(outputObject).then(() => {
console.info('in case: release output success');
console.log('in case: release output count:' + frameCountOut);
}, caseCallback).catch(failCatch);
}
}
function toConfigure(mySteps, done, failureCallback, catchCallback) {
videoDecodeProcessor.configure(mediaDescription).then(() => {
......@@ -399,14 +391,12 @@ describe('VideoDecoderSoftwareReliPromiseTest', function () {
function setCallback(nextStep){
videoDecodeProcessor.on('needInputData', async (inBuffer) => {
console.info('in case: inputBufferAvailable inBuffer.index: '+ inBuffer.index);
inputQueue.push(inBuffer);
await enqueueInputs();
enqueueInputs(inBuffer);
});
videoDecodeProcessor.on('newOutputData', async (outBuffer) => {
console.info('in case: outputBufferAvailable outBuffer.index: '+ outBuffer.index);
outputQueue.push(outBuffer);
await dequeueOutputs(nextStep);
dequeueOutputs(nextStep, outBuffer);
});
videoDecodeProcessor.on('error',(err) => {
......
{
"description": "Configuration for videoPlayer Tests",
"description": "Configuration for videoEncoder Tests",
"driver": {
"type": "JSUnitTest",
"test-timeout": "2000000",
......
......@@ -56,12 +56,6 @@ describe('videoEncoderSoftwareMultiInstances', function () {
afterEach(async function() {
console.info('afterEach case');
if (videoEncodeProcessor != null){
await videoEncodeProcessor.release().then(() => {
console.info("case release success");
videoEncodeProcessor = null;
}, failCallback).catch(failCatch);
}
})
afterAll(function() {
......@@ -255,8 +249,8 @@ describe('videoEncoderSoftwareMultiInstances', function () {
async function toRelease() {
await videoEncodeProcessor.release().then(() => {
console.info("case release success");
videoEncodeProcessor = null;
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
}
......@@ -287,10 +281,10 @@ describe('videoEncoderSoftwareMultiInstances', function () {
for (let j = 1; j < 3; j++) {
await array[j].release().then(() => {
console.info("case release encoder " + j);
array[j] = null;
}, failCallback).catch(failCatch);
array[j] = null;
}
console.info('release 16 encoders success');
console.info('release encoders success');
done();
});
async function runCase() {
......
......@@ -38,8 +38,10 @@ describe('VideoEncoderSoftwareFuncCallbackTest', function () {
console.info('beforeAll case');
})
beforeEach(function() {
beforeEach(async function() {
console.info('beforeEach case');
await msleep(1000).then(() => {
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
mediaTest = null;
surfaceID = '';
......@@ -74,6 +76,10 @@ describe('VideoEncoderSoftwareFuncCallbackTest', function () {
expect(err == undefined).assertTrue();
}
function msleep(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function writeFile(path, buf, len){
try {
let writestream = Fileio.createStreamSync(path, 'ab+');
......
......@@ -37,8 +37,10 @@ describe('videoSoftwareEncoderFuncPromise', function () {
console.info('beforeAll case');
})
beforeEach(function() {
beforeEach(async function() {
console.info('beforeEach case');
await msleep(1000).then(() => {
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
mediaTest = null;
surfaceID = '';
......@@ -76,6 +78,10 @@ describe('videoSoftwareEncoderFuncPromise', function () {
expect(err).assertUndefined();
}
function msleep(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function resetParam() {
outputQueue = [];
outputCnt = 0;
......
......@@ -64,6 +64,8 @@ describe('VideoEncoderSoftwareReliCallbackTest', function () {
beforeEach(async function() {
console.info('beforeEach case');
await msleep(1000).then(() => {
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
mediaTest = null;
surfaceID = '';
......@@ -98,6 +100,11 @@ describe('VideoEncoderSoftwareReliCallbackTest', function () {
console.error(`in case error failCatch called,errMessage is ${err.message}`);
expect(err == undefined).assertTrue();
}
function msleep(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function printError(err, expectFail) {
expect((err != undefined) == expectFail).assertTrue();
if (expectFail == false && err != undefined) {
......@@ -105,6 +112,7 @@ describe('VideoEncoderSoftwareReliCallbackTest', function () {
console.error(`in case error failCatch called,errMessage is ${err.message}`);
}
}
function writeFile(path, buf, len){
try {
let writestream = Fileio.createStreamSync(path, 'ab+');
......
......@@ -65,8 +65,10 @@ describe('videoEncoderReliabilityPromise', function () {
console.info('beforeAll case');
})
beforeEach(function() {
beforeEach(async function() {
console.info('beforeEach case');
await msleep(1000).then(() => {
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
surfaceID = '';
outputQueue = [];
......@@ -86,8 +88,8 @@ describe('videoEncoderReliabilityPromise', function () {
if (videoEncodeProcessor != null) {
await videoEncodeProcessor.release().then(() => {
console.info(`case release 1`);
videoEncodeProcessor = null;
}, failCallback).catch(failCatch);
videoEncodeProcessor = null;
}
})
......@@ -111,6 +113,10 @@ describe('videoEncoderReliabilityPromise', function () {
expect(err).assertUndefined();
}
function msleep(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function resetParam() {
outputQueue = [];
outputCnt = 0;
......@@ -1353,7 +1359,7 @@ describe('videoEncoderReliabilityPromise', function () {
it('SUB_MEDIA_VIDEO_SOFTWARE_ENCODER_API_EOS_PROMISE_0500', 0, async function (done) {
let savepath = BASIC_PATH + 'eos_0500.es';
let mySteps = new Array(CONFIGURE, GETSURFACE, SETSTREAMPARAM, PREPARE, START, STARTSTREAM, HOLDON,
JUDGE_EOS, STOP, START, STOP, STOPSTREAM, END);
JUDGE_EOS, STOP, START, STOP, STOPSTREAM, RELEASE, END);
frameTotal = 2;
createVideoEncoder(savepath, mySteps, done);
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册