@@ -73,15 +73,26 @@ the profiling machine:
73
73
74
74
pstats-host profiling-machine-ip-or-hostname
75
75
76
- If you are developing Python code, you may be interested in reporting the
77
- relative time spent within each Python task (by subdividing the total time spent
78
- in Python, as reported under "Show Code"). To do this, add the following lines
79
- to your Config.prc file before you start ShowBase:
76
+ .. only :: python
80
77
81
- .. code-block :: text
78
+ If you are developing Python code, you may be interested in reporting the
79
+ relative time spent within each Python task (by subdividing the total time
80
+ spent in Python, as reported under "Show Code"). To do this, add the
81
+ following line to your Config.prc file before you start ShowBase:
82
+
83
+ .. code-block :: text
84
+
85
+ pstats-tasks 1
86
+
87
+ As of Panda3D 1.10.13 and Python 3.6 or higher, it is also possible to get a
88
+ more detailed view of which specific Python modules, classes and functions
89
+ are taking up time in the application. Note that this may slow down your
90
+ application somewhat due to the fact that information is collected each time
91
+ a function is called. To enable this, add the following line:
92
+
93
+ .. code-block :: text
82
94
83
- task-timer-verbose 1
84
- pstats-tasks 1
95
+ pstats-python-profiler 1
85
96
86
97
Caveats
87
98
~~~~~~~
@@ -167,7 +178,8 @@ above the upper right corner of the graph. The labels on the guide bars on the
167
178
right are also shown in milliseconds; if you prefer to think about a target
168
179
frame rate rather than an elapsed time in milliseconds, you may find it useful
169
180
to select "Hz" from the Units pulldown menu, which changes the time units
170
- accordingly.
181
+ accordingly. As of Panda3D 1.10.13, a counter may also be shown in the top-right
182
+ corner keeping track of how many times during a frame the collector is started.
171
183
172
184
The running Panda client suggests its target frame rate, as well as the initial
173
185
vertical scale of the graph (that is, the height of the colored bars). You can
0 commit comments