MCPcopy Create free account
hub / github.com/colmap/colmap / UpdateImage

Method UpdateImage

src/colmap/scene/database_sqlite.cc:1470–1489  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1468 }
1469
1470 void UpdateImage(const Image& image) override {
1471 if (image.HasFrameId()) {
1472 const Frame frame = ReadFrame(image.FrameId());
1473 THROW_CHECK(frame.HasDataId(image.DataId()));
1474 }
1475
1476 Sqlite3StmtContext context(sql_stmt_update_image_);
1477
1478 SQLITE3_CALL(sqlite3_bind_text(sql_stmt_update_image_,
1479 1,
1480 image.Name().c_str(),
1481 static_cast<int>(image.Name().size()),
1482 SQLITE_STATIC));
1483 SQLITE3_CALL(
1484 sqlite3_bind_int64(sql_stmt_update_image_, 2, image.CameraId()));
1485 SQLITE3_CALL(
1486 sqlite3_bind_int64(sql_stmt_update_image_, 3, image.ImageId()));
1487
1488 SQLITE3_CALL(sqlite3_step(sql_stmt_update_image_));
1489 }
1490
1491 void UpdatePosePrior(const PosePrior& pose_prior) override {
1492 Sqlite3StmtContext context(sql_stmt_update_pose_prior_);

Callers 3

TEST_PFunction · 0.45
SynthesizeDatasetFunction · 0.45
CreateTestDataFunction · 0.45

Calls 7

HasFrameIdMethod · 0.80
HasDataIdMethod · 0.80
DataIdMethod · 0.80
sizeMethod · 0.80
CameraIdMethod · 0.80
ImageIdMethod · 0.80
FrameIdMethod · 0.45

Tested by 2

TEST_PFunction · 0.36
CreateTestDataFunction · 0.36