Hi Mike,
Apologies for the slow response to your question. We've talked about removing this copying feature within the TSC actually. The threshold for when files are copied or not is rather arbitrary. I believe that the original intention of adding this feature was not platform-related and was simply to avoid the issues associated with attempting to load buffers from a file that has since been changed.
Your hack sounds reasonable to me. Most of OpenVDB has been developed with Linux as it's primary platform, so it wouldn't surprise me if there are platform-specific issues related to this functionality on Windows that could be improved.
To be more specific about what we'd like to change - we've talked about removing the fine-grained ability to lazily load each leaf buffer. My understanding is that this would mean (1) loading just the header, (2) loading the header and the topology, (3) loading the header, topology and value buffers. For instance, for (2) this would mean memory-mapping the value buffers that could be loaded on-demand in a single operation rather than as needed by each leaf node. To accelerate this, we would then load this data in the background in small chunks into a temporary buffer and thrown away so that it would be then cached by the filesystem. This is the essence of the idea, but we haven't gone into detail or assessed whether this is a workable solution for different platforms yet.
Regarding the use of std::filesystem, we will be releasing OpenVDB 8.0 sometime in the next few months which will adhere to the VFX Reference Platform that allows us to use C++17. Although we still need to be compatible with C++14 for the next couple of years, for a fairly self-contained feature like this, I wouldn't have a problem with us starting to develop an improved version that used C++17 gated by a define if you'd be interested in contributing to something like this. There is still of course the challenge of working with memory mapping in a platform-agnostic way in C++, but ideally we'd also like to remove the boost::iostreams dependency.
Cheers,
Dan