Code Monkey home page Code Monkey logo

rgb-d-scan-with-arkit's Introduction

RGB-D Scan with ARKit

For every saveSpan frames, save

  • RGB
  • Depth map
  • Confidence map
  • Camera intrinsic
  • View matrix

The saved data can be used to generate a point cloud of the scene for a variety of applications and researches in computer vision and robotics.

How to Use

Just open the app and tap the screen to start scanning.

From the tab bar, you can choose what to show on the screen among

  • Camera Image (RGB)
  • Depth Map
  • Confidence Map

When the Show Point Cloud button is on, the app shows the point cloud of the scnene instead of Camera Image.

Camera Image Depth Map Confidence Map Point Cloud

How to Save Point Cloud

After scanning, tap the Save button on the bottom left of the app to save the point cloud as a .ply file.

The point cloud is generated by projecting the pixels of the current frame onto the 3D space using the depth map, camera intrinsic and view matrix.

Structure of the Saved Data

The saved data is stored under the Documents directory of the ScanRGB app. The directory structure is as follows:

.
├── 1/
│   ├── Confidence/
│   │   ├── confidence_0.jpg
│   │   ├── confidence_1.jpg
│   │   └── ...
│   ├── Frame/
│   │   ├── frame_0.json
│   │   ├── frame_1.json
│   │   └── ...
│   └── RGB/
│       ├── rgb_0.jpg
│       ├── rgb_1.jpg
│       └── ...
└── 2/
    ├── Confidence/
    ├── Frame/
    └── RGB/

frame_n.json contains the following information for the n-th frame:

{
    "depth_map": {
        "width": "width of the depth map",
        "height": "height of the depth map",
        "values": [
            "depth map values flattened into a 1D array"
        ]
    },
    "intrinsic": [
        "3 x 3 camera intrinsic matrix"
    ],
    "view_matrix": [
        "4 x 4 view matrix"
    ],
    "frame_number": "frame number"
}

Known Issues

  • The number of saved frames shown on the top left of the app is not accurate. Sometimes it shows a larger number than the actual number of saved frames.

rgb-d-scan-with-arkit's People

Contributors

tomoya-matsubara avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.