MovieWriter: Check disk space in output directory#114858
Open
boozee wants to merge 1 commit intogodotengine:masterfrom
Open
MovieWriter: Check disk space in output directory#114858boozee wants to merge 1 commit intogodotengine:masterfrom
boozee wants to merge 1 commit intogodotengine:masterfrom
Conversation
393b959 to
36df7ef
Compare
36df7ef to
204036b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #113391
Summary
MovieWriter now opens the output directory directly when checking free space, so the warning reflects the target filesystem instead of the current working directory.
In the attached screen it can be seen that while
CWRis set toV, which has less than 6GB available, no warning is output as the movie is written toCwith over 1TB available.Why the previous code didn’t work
The old code created a
DirAccessinstance and then called the staticDirAccess::open()(viadir->open(path)), which returns a new object but doesn’t modify the existing one. As a result,get_space_left()still ran on the default current directory.