Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
P
ParaEncode
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ParaEncode
Commits
0e206d09
Commit
0e206d09
authored
May 06, 2022
by
Linshizhi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
457bca7d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
0 deletions
+37
-0
ENCH264Group.spec.js
tests/ENCH264Group.spec.js
+37
-0
No files found.
tests/ENCH264Group.spec.js
0 → 100644
View file @
0e206d09
import
{
sleep
}
from
'../src/utils.js'
;
import
{
H264EncWWGroup
,
H264GRP_OPTIONS
}
from
'../src/encGroup.js'
;
describe
(
"H264EncWWGroup Spec"
,
()
=>
{
it
(
"Instantiation"
,
async
()
=>
{
let
wg
=
new
H264EncWWGroup
(
"h264enc"
,
{
numOfWW
:
2
});
await
wg
.
start
();
await
sleep
(
1000
);
expect
(
wg
.
numOfWorker
()).
toBe
(
2
);
});
fit
(
"Encode by H264EncWWGroup Spec"
,
async
()
=>
{
const
RGBAFrameSize
=
1920
*
1080
*
4
;
let
grp
=
new
H264EncWWGroup
(
"h264enc"
,
{
numOfWW
:
8
,
encchnlsize
:
RGBAFrameSize
*
10
,
bridgechnlsize
:
Math
.
pow
(
2
,
25
)
});
await
grp
.
start
();
const
data
=
new
Uint8Array
([...
Array
(
RGBAFrameSize
).
keys
()]);
for
(
let
i
=
0
;
i
<
300
;
++
i
)
{
await
grp
.
dispatch
(
data
);
}
// Terminated
await
grp
.
dispatch
(
null
);
await
sleep
(
100000
);
},
300000
)
})
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