Odom: support features-only frames (#1767)

* Odom: support features-only frames

* odom: fixed input keypoint scaling when Odom/Decimation is used

* fixing octave scaling when decimating image in Memory

* Gating negative octave scaling on decimation

* backward compatibility with octave issue

* narrowing the change, cleanup comments

* fixing corrupted file copy on windows
This commit is contained in:
matlabbe
2026-09-19 23:48:45 -07:00
committed by GitHub
parent 1fe713cc1f
commit 9ed83a71db
9 changed files with 234 additions and 10 deletions
+4 -2
View File
@@ -96,8 +96,10 @@ std::string UFile::getExtension(const std::string &filePath)
void UFile::copy(const std::string & from, const std::string & to)
{
std::ifstream src(from.c_str());
std::ofstream dst(to.c_str());
// Binary, or Windows translates line endings and stops at the first 0x1A, which
// silently truncates or corrupts anything that is not text -- a database, an image.
std::ifstream src(from.c_str(), std::ios::binary);
std::ofstream dst(to.c_str(), std::ios::binary);
dst << src.rdbuf();
}