150

GitHub - retroplasma/earth-reverse-engineering: WIP

 5 years ago
source link: https://github.com/retroplasma/earth-reverse-engineering
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

README.md

example

Earth to OBJ file downloader

npm install
node index.js [octant] [max_level]

# example.jpg
node index.js 20527061605273514 20

find octant

Notes

"https://kh.google.com/rt/?/?"
 - ?: planet
       - "earth"
       - "mars"
       - ...
 - ?: resource
       - "PlanetoidMetadata"
       - "BulkMetadata/pb=!1m2!1s❶!2u❷"
          - ❶: octant path
          - ❷: epoch
       - "NodeData/pb=!1m2!1s❸!2u❹!2e❺(!3u❻)!4b0"
          - ❸: octant path
          - ❹: epoch
          - ❺: texture format
          - ❻: imagery epoch (sometimes)

General info:
 - Everything is stored in an octree.

Roles of resources:
 - PlanetoidMetadata points to first BulkMetaData.
 - BulkMetaData points to other BulkMetaData and to NodeData.
 - NodeData contains actual meshes and textures.

Versioning:
 - BulkMetaData and NodeData are versioned using epoch numbers.
 - PlanetoidMetadata provides epoch of first BulkMetaData.
 - BulkMetaData provides epochs of underlying resources.
 - Current version of a resource can be determined recursively.
 
NodeData:
 - Vertex Buffer:
    - 8 bytes per point: X,Y,Z,W,U,U,V,V
    - XYZ: position, W: octant mask, UV: texture coordinates
 - Texture:
    - Format 1: JPEG
    - Format 6: S3 DXT1 RGB

Related ideas: Racing game , Minimal client. WebGL + CORS should work (test).


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK