Clever Geek Handbook
πŸ“œ ⬆️ ⬇️

PLY

PLY is a geometry description file format, also known as Polygon File Format and Stanford Triangle Format . It was designed primarily for storing three-dimensional data from 3D scanners. The format supports a relatively simple description of an object as a list of flat polygons. PLY can store many properties of an object, including: color and transparency, surface normals, texture coordinates, etc. The format allows you to have various properties of the front and back faces of the polygon. There are 2 versions of the PLY format: ASCII and as a binary file .

Polygon file format
Expansion. ply
MIME typetext / plain
SignaturePLY
DeveloperGreg Turk , Stanford University
Published1994 [1]
Format type3D model format

Content

Format Description

Files are arranged in the form of a header, in which the elements of the mesh and their types are determined, and the list of the elements following them. Elements are usually vertices and faces, but other entities, such as edges or triangle strips, may be included.

The header for both ASCII and binary is ASCII text. Only the numerical data following the heading differs between versions. The heading always starts with a line containing the word

  ply

that identifies the PLY file format. The second line displays which version of the PLY format is used:

  format ascii 1.0
 format binary_little_endian 1.0
 format binary_big_endian 1.0

At the moment, 1.0 is the only used version of the format.

Comments can be placed in the header using the word comment at the beginning of the line. The entire line after this word will be ignored during import:

  comment This is a comment!

The element keyword introduces a description of which particular data item is stored in the file, as well as the number of these items. The example below describes that the file contains 12 vertices, each of which is represented as three floating-point numbers:

  element vertex 12
 property float x
 property float y
 property float z

Lines beginning with the word property indicate the type of vertex information. There are 2 types of options, depending on the source of the ply file. The type can be one of char uchar short ushort int uint float double or one of int8 uint8 int16 uint16 int32 uint32 float32 float64 . The faces of an object can be described as follows:

  element face 10
 property list uchar int vertex_indices

The word list shows that the data is presented as a list of values, the first of which is the number of elements in the list (represented by the type 'uchar' in this case), and each occurrence of the list is of the type 'int'. For the usual 'property list ...' polygon representation, the first number for this element is the number of polygon vertices, and the remaining numbers are the indices in the previous vertex list.

At the end of the header is a line indicating its end:

  end_header

ASCII or binary format

In the ASCII version of the format, each vertex and face is described by a single string of numbers separated by spaces. In the binary version of the format, the data is packed next to each other in the byte order set in the workpiece and the type specified in 'property'.

History

The PLY format was developed in the mid-90s by Greg Turk English. and other Stanford graphics lab employees led by Marc Levoy. Its design was inspired by the Wavefront .obj format, but the Obj format is not extensible by arbitrary properties and data groups, for which the keywords 'property' and 'element' were introduced, generalizing the notation of vertices, faces, associated data, etc.

Notes

  1. ↑ Greg Turk. The PLY Polygon File Format (unopened) (link not available) . Archived December 4, 2016.

Links

  • PLY - Polygon File Format
  • Some tools for working with PLY files (C source code)
  • rply - ANSI C library for reading and writing PLY files (MIT license)
  • libply - C ++ library for reading and writing PLY files (GNU license)
  • Another C ++ library for reading and writing PLY files (GPL 3.0 license)
  • Repository of 3D models in PLY format
Source - https://ru.wikipedia.org/w/index.php?title=PLY&oldid=92662683


More articles:

  • Sidaris Andy
  • Infinite H
  • The Conquest of Siberia by Ermak Timofeevich
  • Gareev, Stanislav Uralovich
  • Roketnitsa (commune, Yaroslavl County)
  • Senyava (Commune)
  • Chernyshkov (station)
  • 17th Pacific Fleet Operational Squadron
  • Tryncha (Commune)
  • Iraq Men's Basketball Team

All articles

Clever Geek | 2019