PointCloud2 lib for non ROS environments
Project description
PointCloud2
PointCloud2 lib for non ROS environment.
Usage
>>> import numpy as np
>>> from pointcloud2 import create_cloud, read_points, PointField
>>> fields = [
... PointField('x', 0, PointField.FLOAT32, 1),
... PointField('y', 4, PointField.FLOAT32, 1),
... PointField('z', 8, PointField.FLOAT32, 1),
... PointField('rgb', 12, PointField.UINT32, 1),
... ]
>>> points = np.array([
... [1, 0, 0, 255],
... [0, 1, 0, 255],
... [0, 0, 1, 255],
... ], dtype=np.float32)
>>> cloud = create_cloud(header=None, fields=fields, points=points)
>>> cloud.height, cloud.width, cloud.point_step, cloud.row_step, len(cloud.data)
(1, 3, 16, 48, 48)
>>> read_points(cloud)
array([(1., 0., 0., 255), (0., 1., 0., 255), (0., 0., 1., 255)],
dtype=[('x', '<f4'), ('y', '<f4'), ('z', '<f4'), ('rgb', '<u4')])
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pointcloud2-0.3.0.tar.gz
(6.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pointcloud2-0.3.0.tar.gz.
File metadata
- Download URL: pointcloud2-0.3.0.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2c625d2d5b8509241770d589d53dbfef00444be452c1fa557a10060b6ed330bf
|
|
| MD5 |
5b58e45f3ce34d6341f211d4c9ddbd4e
|
|
| BLAKE2b-256 |
1df9183b111eac5189eb04234b9808b5ae97ce294814d1549c61a5160e73919a
|
File details
Details for the file pointcloud2-0.3.0-py3-none-any.whl.
File metadata
- Download URL: pointcloud2-0.3.0-py3-none-any.whl
- Upload date:
- Size: 7.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0eb8c70d3a062176c3897cdae9f9312b31ad87aac0bc232a933208514cd553a9
|
|
| MD5 |
6010b941c94a0429af6b81ead555eaeb
|
|
| BLAKE2b-256 |
69b211480bd1980651805756445101346ae1dc933ce95645bdf917ea8993281f
|