Deprecated: Creation of dynamic property GeneralSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: Creation of dynamic property AbstractSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: Creation of dynamic property UserSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_init_login.inc.php on line 81

Deprecated: Creation of dynamic property CollectionSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: Creation of dynamic property Item::$objtype is deprecated in /usr/share/b2evolution/inc/items/model/_itemlight.class.php on line 164

Deprecated: Creation of dynamic property Item::$datestart is deprecated in /usr/share/b2evolution/inc/items/model/_itemlight.class.php on line 175

Deprecated: Creation of dynamic property Item::$coll_to_cat is deprecated in /usr/share/b2evolution/inc/items/model/_itemlight.class.php on line 1260

Deprecated: Creation of dynamic property ItemList2::$filterset_name is deprecated in /usr/share/b2evolution/inc/items/model/_itemlistlight.class.php on line 114

Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated in /usr/share/b2evolution/inc/items/model/_itemlistlight.class.php on line 420

Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated in /usr/share/b2evolution/inc/_core/_param.funcs.php on line 1407

Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated in /usr/share/b2evolution/inc/_core/_param.funcs.php on line 1407

Deprecated: Creation of dynamic property ItemQuery::$dbtablename is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 78

Deprecated: Creation of dynamic property ItemQuery::$dbprefix is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 79

Deprecated: Creation of dynamic property ItemQuery::$dbIDname is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 80

Deprecated: Creation of dynamic property ItemQuery::$Blog is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 231

Deprecated: Creation of dynamic property ItemQuery::$cat_array is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 232

Deprecated: Creation of dynamic property ItemQuery::$cat_modifier is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 233

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: Creation of dynamic property ItemQuery::$assignees_logins is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 525

Deprecated: Creation of dynamic property ItemQuery::$author_assignee is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 557

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

Deprecated: Creation of dynamic property ItemQuery::$m is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 842

Deprecated: Creation of dynamic property ItemQuery::$w is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 843

Deprecated: Creation of dynamic property ItemSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: Creation of dynamic property Item::$switchable_params is deprecated in /usr/share/b2evolution/inc/items/model/_item.class.php on line 4737

Deprecated: Creation of dynamic property Item::$is_locked is deprecated in /usr/share/b2evolution/inc/items/model/_item.class.php on line 12180

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/skins/model/_skin.class.php on line 1509

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/_core/_template.funcs.php on line 40

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/_core/_template.funcs.php on line 405

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/_core/_template.funcs.php on line 406

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/_core/_template.funcs.php on line 407

Warning: Cannot modify header information - headers already sent by (output started at /usr/share/b2evolution/inc/_core/_misc.funcs.php:10542) in /usr/share/b2evolution/inc/_core/_template.funcs.php on line 408

Deprecated: Creation of dynamic property tinymce_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property wikitables_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Return type of ExplodeIterator::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /usr/share/b2evolution/plugins/wikitables_plugin/_string_utils.inc.php on line 529

Deprecated: Return type of ExplodeIterator::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /usr/share/b2evolution/plugins/wikitables_plugin/_string_utils.inc.php on line 540

Deprecated: Return type of ExplodeIterator::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /usr/share/b2evolution/plugins/wikitables_plugin/_string_utils.inc.php on line 533

Deprecated: Return type of ExplodeIterator::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /usr/share/b2evolution/plugins/wikitables_plugin/_string_utils.inc.php on line 558

Deprecated: Return type of ExplodeIterator::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /usr/share/b2evolution/plugins/wikitables_plugin/_string_utils.inc.php on line 511

Deprecated: Creation of dynamic property auto_anchors_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property twitter_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property PluginUserSettings::$count_col_key_names is deprecated in /usr/share/b2evolution/inc/settings/model/_abstractsettings.class.php on line 121

Deprecated: Creation of dynamic property PluginUserSettings::$plugin_ID is deprecated in /usr/share/b2evolution/inc/plugins/model/_pluginusersettings.class.php on line 36

Deprecated: Creation of dynamic property videoplug_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property html5_mediaelementjs_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /usr/share/b2evolution/plugins/html5_mediaelementjs_plugin/_html5_mediaelementjs.plugin.php on line 61

Deprecated: Creation of dynamic property html5_videojs_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property mermaid_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property widescroll_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413

Deprecated: Creation of dynamic property table_contents_plugin::$classfile_path is deprecated in /usr/share/b2evolution/inc/plugins/model/_plugins.class.php on line 413
Using WindowRecording to Analyze Visual Pageload
  • Front Page

  • Deprecated: Calling get_class() without arguments is deprecated in /usr/share/b2evolution/inc/_core/model/dataobjects/_dataobjectcache.class.php on line 248

    Deprecated: Creation of dynamic property ItemListLight::$filterset_name is deprecated in /usr/share/b2evolution/inc/items/model/_itemlistlight.class.php on line 114

    Deprecated: Creation of dynamic property ItemQuery::$dbtablename is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 78

    Deprecated: Creation of dynamic property ItemQuery::$dbprefix is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 79

    Deprecated: Creation of dynamic property ItemQuery::$dbIDname is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 80

    Deprecated: Creation of dynamic property ItemQuery::$Blog is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 231

    Deprecated: Creation of dynamic property ItemQuery::$cat_array is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 232

    Deprecated: Creation of dynamic property ItemQuery::$cat_modifier is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 233

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: Creation of dynamic property ItemQuery::$assignees_logins is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 525

    Deprecated: Creation of dynamic property ItemQuery::$author_assignee is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 557

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10537

    Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /usr/share/b2evolution/inc/_core/_misc.funcs.php on line 10542

    Deprecated: Creation of dynamic property ItemQuery::$m is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 842

    Deprecated: Creation of dynamic property ItemQuery::$w is deprecated in /usr/share/b2evolution/inc/items/model/_itemquery.class.php on line 843
  • Contact
Bas
2019-04-04

Using WindowRecording to Analyze Visual Pageload

Window Recording


As of bug 1536174, I've added a mechanism for Firefox that uses an internal mechanism that can record content frames during composition. Note that this currently only works when on Windows using D3D11 composition. This is still in very early stages and will likely be getting some improvements over the longer term, but right now, basically this is how it works:

  1. Make sure you're on nightly, the keyboard shortcut we'll be using only works there.
  2. Before initiating the action you want to record, press 'Ctrl+Shift+4', this will begin recording
  3. Execute an action in the browser (for example load a page)
  4. Wait for whatever operation you wish to capture to finish
  5. Press 'Ctrl+Shift+4' again, this will end recording and generate output

You will now find a new directory in your working directory called windowrecording-<timestamp> which contains a list of PNGs, this list of PNGs uses the following naming convention:

frame-<framenumber>-<ms since recording start>.png

You will notice only the frames where actual content changes occurred (no scrolling, asynchronous animation, parent process changes, etc.), this will likely become more flexible in the future. The directory where the output is delivered can optionally be selected using the layers.windowrecording.path preference. Use a trailing slash for expected behavior.

There's a couple of caveats when using recording:

  • In order to minimize overhead during recording frames are stored uncompressed in memory, recordings more than a few seconds will consume very large amounts of memory
  • Lossless compression is used for the output, this means the recordings can be relatively large

Pageload Analysis


Recently I've been working on a script that can use the generated recordings to perform pageload analysis. The scripts can be found here and in this post I will attempt to describe the right way to use them. The scripts, as well as this entire description are meant to be used on windows, so these instructions will not be accurate on other platforms (and in any case, recording doesn't work there yet either, nor will most people have an open source PowerShell implementation installed). This is also in very early stages and not particularly user friendly, you probably shouldn't be using it yet and just skip to the demo video :-).

Prerequisites

Note that visualmetrics.py also expects ffmpeg and the imagemagick binary locations to be included in the path.

The next step is to modify the SetPaths.ps1 script to point to the correct binaries for your system, these are the binaries that the AnalyzeWindowRecording script will use.

Recording Pageload

The next step is recording a pageload. The first step would be to go to 'about:blank' to ensure a solid white reference frame to start from. A current weakness is that the timestamp of the video (and therefore the point in time the analysis will consider the 'beginning' of pageload) is the time when the recording begins, rather than navigation start. Therefore, it is best to navigate immediately after beginning the recording, this could be improved by scripting the recording and navigation start to occur at the same time, but for now we'll assume that a small offset may be considered acceptable.

First start the recording and immediately navigate to the desired page, wait for pageload to finish visually and then end the recording.

Analysis

The final step is to run the analysis script, this is done by executing the script as follows:

.\AnalyzeWindowRecording.ps1 <directory containing recording> <annotated output video>

Note that the script may take a while to execute, particularly on a slower machine. The script will output the recorded FirstVisualChange, LastVisualChange and SpeedIndex to stdout, as well as generate an annotated video that will display information at the stop about the current visual completeness and the different stages of the video.

It is important to note that the script will currently chop off the top 197 pixels of the frames, this was accurate for my recordings but most likely isn't for people recording using different DPI scaling, in the future I will make this parameter configurable or possibly even automatically detected, however for now you will have to manually adjust the $chop variable at the top of the AnalyzeWindowRecording script for your situation.

Finally, I realize these are lengthy instructions and usage of this functionality is currently not for the faint of heart. I wanted to make this information available as quickly as possible though and we expect to be improving on this in the future, let me know in the comments or on IRC if you have any questions or feedback.

No feedback yet


Form is loading...

May 2026
Mon Tue Wed Thu Fri Sat Sun
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
 << <   > >>