Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libdvbpsi
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
libdvbpsi
Commits
c2e3f3fa
Commit
c2e3f3fa
authored
Jun 28, 2015
by
Daniel Kamil Kozar
Committed by
Jean-Paul Saman
Jan 12, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add tests for the smoothing buffer descriptor
Signed-off-by:
Jean-Paul Saman
<
jpsaman@videolan.org
>
parent
77962d1a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
0 deletions
+47
-0
misc/dr.dtd
misc/dr.dtd
+1
-0
misc/dr.xml
misc/dr.xml
+5
-0
misc/dr.xsl
misc/dr.xsl
+6
-0
misc/test_dr.c
misc/test_dr.c
+35
-0
No files found.
misc/dr.dtd
View file @
c2e3f3fa
...
...
@@ -18,6 +18,7 @@
<!ATTLIST descriptor sname CDATA #IMPLIED>
<!ATTLIST descriptor fname CDATA #IMPLIED>
<!ATTLIST descriptor msuffix CDATA #IMPLIED>
<!ATTLIST descriptor gen_args CDATA #IMPLIED>
<!ATTLIST integer name CDATA #IMPLIED>
<!ATTLIST integer bitcount CDATA #IMPLIED>
...
...
misc/dr.xml
View file @
c2e3f3fa
...
...
@@ -106,6 +106,11 @@
<descriptor
name=
"private data indicator"
sname=
"private_data"
fname=
"PrivateData"
>
<integer
name=
"i_private_data"
bitcount=
"32"
default=
"0"
/>
</descriptor>
<descriptor
name=
"smoothing buffer"
sname=
"smoothing_buffer"
fname=
"SmoothingBuffer"
gen_args=
"1"
>
<integer
name=
"i_sb_leak_rate"
bitcount=
"22"
default=
"0"
/>
<integer
name=
"i_sb_size"
bitcount=
"22"
default=
"0"
/>
</descriptor>
<!--
<descriptor name="stuffing" sname="stuffing" fname="Stuffing">
<insert>
...
...
misc/dr.xsl
View file @
c2e3f3fa
...
...
@@ -72,6 +72,12 @@ static int main_<xsl:value-of select="@sname" />_<xsl:value-of select="@msuffix"
BOZO_VARS(
<xsl:value-of
select=
"@sname"
/>
);
BOZO_START(
<xsl:value-of
select=
"@name"
/>
);
<!-- declare a macro for calling the one-argument generate functions -->
<xsl:if
test=
"@gen_args = 1"
>
#define dvbpsi_Gen
<xsl:value-of
select=
"@fname"
/>
Dr(x,y) \
dvbpsi_Gen
<xsl:value-of
select=
"@fname"
/>
Dr(x)
</xsl:if>
<xsl:apply-templates
mode=
"check"
/>
BOZO_END(
<xsl:value-of
select=
"@name"
/>
);
...
...
misc/test_dr.c
View file @
c2e3f3fa
...
...
@@ -660,6 +660,40 @@ static int main_private_data_(void)
return
i_err
;
}
/* smoothing buffer */
static
int
main_smoothing_buffer_
(
void
)
{
BOZO_VARS
(
smoothing_buffer
);
BOZO_START
(
smoothing
buffer
);
#define dvbpsi_GenSmoothingBufferDr(x,y) \
dvbpsi_GenSmoothingBufferDr(x)
/* check i_sb_leak_rate */
BOZO_init_integer
(
i_sb_leak_rate
,
0
);
BOZO_init_integer
(
i_sb_size
,
0
);
BOZO_begin_integer
(
i_sb_leak_rate
,
22
)
BOZO_DOJOB
(
SmoothingBuffer
);
BOZO_check_integer
(
i_sb_leak_rate
,
22
)
BOZO_CLEAN
();
BOZO_end_integer
(
i_sb_leak_rate
,
22
)
/* check i_sb_size */
BOZO_init_integer
(
i_sb_leak_rate
,
0
);
BOZO_init_integer
(
i_sb_size
,
0
);
BOZO_begin_integer
(
i_sb_size
,
22
)
BOZO_DOJOB
(
SmoothingBuffer
);
BOZO_check_integer
(
i_sb_size
,
22
)
BOZO_CLEAN
();
BOZO_end_integer
(
i_sb_size
,
22
)
BOZO_END
(
smoothing
buffer
);
return
i_err
;
}
/* service */
static
int
main_service_
(
void
)
{
...
...
@@ -705,6 +739,7 @@ int main(void)
i_err
|=
main_copyright_
();
i_err
|=
main_max_bitrate_
();
i_err
|=
main_private_data_
();
i_err
|=
main_smoothing_buffer_
();
i_err
|=
main_service_
();
if
(
i_err
)
...
...
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