diff options
| author | Carl Hetherington <cth@carlh.net> | 2025-04-13 21:09:37 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-04-13 21:09:37 +0200 |
| commit | d16267be986c0994f05fc6a3889b83ba53a230b0 (patch) | |
| tree | 8f416cd12b06f2a334023c891bb78bd0996bb518 /src/wx/content_menu.cc | |
| parent | c325ab5f745c67e6381bcee582bf809018d809e0 (diff) | |
Don't bind a shared_ptr<PlayerVideo> to ImageChanged (#3013).
Otherwise if the GUI is busy when the emissions build up, each one holds
a reference to a potentially large image.
This caused enormous memory use when playing a DCP and verifying it at
the same time.
Diffstat (limited to 'src/wx/content_menu.cc')
| -rw-r--r-- | src/wx/content_menu.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wx/content_menu.cc b/src/wx/content_menu.cc index 62421a20b..559b57553 100644 --- a/src/wx/content_menu.cc +++ b/src/wx/content_menu.cc @@ -586,7 +586,7 @@ ContentMenu::auto_crop () }); /* Also update the dialog and view when we're looking at a different frame */ - _auto_crop_viewer_connection = _viewer.ImageChanged.connect([this, guess_crop_for_content, update_viewer](shared_ptr<PlayerVideo>) { + _auto_crop_viewer_connection = _viewer.ImageChanged.connect([this, guess_crop_for_content, update_viewer]() { auto const crop = guess_crop_for_content(); _auto_crop_dialog->set(crop); update_viewer(crop); |
