18#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_PSTATCLIENT)
19 #error Buildsystem error: BUILDING_PANDA_PSTATCLIENT not defined
22ConfigureDef(config_pstatclient);
23NotifyCategoryDef(pstats,
"");
25ConfigureFn(config_pstatclient) {
30(
"pstats-name",
"Panda Stats");
33(
"pstats-max-rate", 1000.0,
34 PRC_DESC(
"The maximum number of packets per second, per thread, to send "
35 "to the remote PStats server. A packet is defined as a single "
36 "UDP packet, or each 1024 bytes of a TCP message. Set this to a "
37 "negative number to disable the limit."));
40(
"pstats-threaded-write",
true,
41 PRC_DESC(
"Set this true to write to the PStats channel in a sub-thread, if "
42 "threading is available. Can't think of any reason why you "
43 "wouldn't want this set true, unless you suspect something is "
44 "broken with the threaded network interfaces."));
47(
"pstats-max-queue-size", 4,
48 PRC_DESC(
"If pstats-threaded-write is true, this specifies the maximum "
49 "number of packets (generally, frames of data) that may be queued "
50 "up for the thread to process. If this is large, the writer "
51 "thread may fall behind and the output of PStats will lag. Keep "
52 "this small to drop missed packets on the floor instead, and "
53 "ensure that the frame data does not grow stale."));
56(
"pstats-tcp-ratio", 0.01,
57 PRC_DESC(
"This specifies the ratio of frame update messages that are eligible "
58 "for UDP that are sent via TCP instead. It does not count messages "
59 "that are too large for UDP and must be sent via TCP anyway. 1.0 "
60 "means all messages are sent TCP; 0.0 means all are sent UDP."));
63(
"pstats-host",
"localhost");
70(
"pstats-target-frame-rate", 30.0,
71 PRC_DESC(
"Specify the target frame rate to highlight on the PStats graph. "
72 "This frame rate is marked with a different-colored line; "
73 "otherwise, this setting has no effect."));
76(
"pstats-gpu-timing",
false,
77 PRC_DESC(
"Set this true to query the graphics library for the actual time "
78 "that graphics operations take to execute on the video card. "
79 "Enabling this will harm performance, but this information can "
80 "be more useful than the regular Draw information in tracking "
81 "down bottlenecks, because the CPU-based Draw collectors only "
82 "measure how long it takes for the API call to complete, which "
83 "is not usually an accurate reflectino of how long the actual "
84 "operation takes on the video card."));
87(
"pstats-python-profiler",
false,
88 PRC_DESC(
"Set this true to integrate with the Python profiler to show "
89 "detailed information about individual Python functions in "
90 "PStats, similar to the information offered by Python's built-in "
91 "profiler. This can be really useful to find bottlenecks in a "
92 "Python program, but enabling this will slow down the application "
93 "somewhat, and requires a recent version of the PStats server, so "
94 "it is not enabled by default."));
99(
"pstats-scroll-mode",
true);
101(
"pstats-history", 60.0);
103(
"pstats-average-time", 3.0);
106(
"pstats-mem-other",
true,
107 PRC_DESC(
"Set this true to collect memory categories smaller than 0.1% of "
108 "the total into a single \"Other\" category, or false to show "
109 "each nonzero memory category."));
119 static bool initialized =
false;
This is a convenience class to specialize ConfigVariable as a boolean type.
This is a convenience class to specialize ConfigVariable as a floating- point type.
This is a convenience class to specialize ConfigVariable as an integer type.
This is a convenience class to specialize ConfigVariable as a string type.
void init_libpstatclient()
Initializes the library.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.