Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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
vlc-1.1
Commits
fe65cde1
Commit
fe65cde1
authored
Mar 28, 2006
by
Antoine Cellerier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Export stats in http interface
parent
de6aa435
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
48 additions
and
0 deletions
+48
-0
modules/control/http/http.c
modules/control/http/http.c
+33
-0
share/http/requests/status.xml
share/http/requests/status.xml
+15
-0
No files found.
modules/control/http/http.c
View file @
fe65cde1
...
...
@@ -489,6 +489,7 @@ static void ParseExecute( httpd_file_sys_t *p_args, char *p_buffer,
audio_volume_t
i_volume
;
char
volume
[
5
];
char
state
[
8
];
char
stats
[
20
];
#define p_sys p_args->p_intf->p_sys
if
(
p_sys
->
p_input
)
...
...
@@ -548,6 +549,38 @@ static void ParseExecute( httpd_file_sys_t *p_args, char *p_buffer,
E_
(
mvar_AppendNewVar
)(
p_args
->
vars
,
"stream_state"
,
state
);
E_
(
mvar_AppendNewVar
)(
p_args
->
vars
,
"charset"
,
((
intf_sys_t
*
)
p_args
->
p_intf
->
p_sys
)
->
psz_charset
);
/* Stats */
#define p_sys p_args->p_intf->p_sys
if
(
p_sys
->
p_input
)
{
input_item_t
*
p_item
=
p_sys
->
p_input
->
input
.
p_item
;
if
(
p_item
)
{
vlc_mutex_lock
(
&
p_item
->
p_stats
->
lock
);
#define STATS_INT( n ) sprintf( stats, "%d", p_item->p_stats->i_ ## n ); \
E_(mvar_AppendNewVar)( p_args->vars, #n, stats );
#define STATS_FLOAT( n ) sprintf( stats, "%f", p_item->p_stats->f_ ## n ); \
E_(mvar_AppendNewVar)( p_args->vars, #n, stats );
STATS_INT
(
read_bytes
)
STATS_FLOAT
(
input_bitrate
)
STATS_INT
(
demux_read_bytes
)
STATS_FLOAT
(
demux_bitrate
)
STATS_INT
(
decoded_video
)
STATS_INT
(
displayed_pictures
)
STATS_INT
(
lost_pictures
)
STATS_INT
(
decoded_audio
)
STATS_INT
(
played_abuffers
)
STATS_INT
(
lost_abuffers
)
STATS_INT
(
sent_packets
)
STATS_INT
(
sent_bytes
)
STATS_FLOAT
(
send_bitrate
)
#undef STATS_INT
#undef STATS_FLOAT
vlc_mutex_unlock
(
&
p_item
->
p_stats
->
lock
);
}
}
#undef p_sys
E_
(
SSInit
)(
&
p_args
->
stack
);
/* allocate output */
...
...
share/http/requests/status.xml
View file @
fe65cde1
...
...
@@ -118,4 +118,19 @@
</category>
<vlc
id=
"end"
/>
</information>
<stats>
<readbytes><vlc
id=
"value"
param1=
"read_bytes"
/></readbytes>
<inputbitrate><vlc
id=
"value"
param1=
"input_bitrate"
/></inputbitrate>
<demuxreadbytes><vlc
id=
"value"
param1=
"demux_read_bytes"
/></demuxreadbytes>
<demuxbitrate><vlc
id=
"value"
param1=
"demux_bitrate"
/></demuxbitrate>
<decodedvideo><vlc
id=
"value"
param1=
"decoded_video"
/></decodedvideo>
<displayedpictures><vlc
id=
"value"
param1=
"displayed_pictures"
/></displayedpictures>
<lostpictures><vlc
id=
"value"
param1=
"lost_pictures"
/></lostpictures>
<decodedaudio><vlc
id=
"value"
param1=
"decoded_audio"
/></decodedaudio>
<playedabuffers><vlc
id=
"value"
param1=
"played_abuffers"
/></playedabuffers>
<lostabuffers><vlc
id=
"value"
param1=
"lost_abuffers"
/></lostabuffers>
<sentpackets><vlc
id=
"value"
param1=
"sent_packets"
/></sentpackets>
<sentbytes><vlc
id=
"value"
param1=
"sent_bytes"
/></sentbytes>
<sendbitrate><vlc
id=
"value"
param1=
"send_bitrate"
/></sendbitrate>
</stats>
</root>
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