pcl icon indicating copy to clipboard operation
pcl copied to clipboard

Document the RGBA structure

Open rurban opened this issue 1 year ago • 4 comments

rurban avatar Sep 09 '24 13:09 rurban

Shouldn't it be RGBA all places, since the alpha part is always present? I couldn't find a RGB only struct at least?

larshg avatar Sep 10 '24 16:09 larshg

Shouldn't it be RGBA all places, since the alpha part is always present? I couldn't find a RGB only struct at least?

No they are separate, even if they share the same uint32_t storage. pcl::PointXYZRGB != pcl::PointXYZRGBA

rurban avatar Sep 12 '24 08:09 rurban

Ahh, but there is only a single pcl::RGB struct - which expose the A channel with default 255 value. There are no pcl::RGBA struct.

But indeed there is PointXYZRGB and PointXYZRGBA. And what I can see PointXYZRGB only has constructors that accept XYZ and RGB - ie. hides the alpha channel.

I don't see the necessary of having PointXYZRGB, since it still has the same size as PointXYZRGBA - but I don't see us removing it now anyways...? And pcl::RGB should be pcl::RGBA, since it does contain both the space and expose the alpha channel.

I would vote that the documentation explains this for the pcl::RGB struct though?

What do you think @mvieth ?

larshg avatar Sep 19 '24 17:09 larshg

Ahh, but there is only a single pcl::RGB struct - which expose the A channel with default 255 value. There are no pcl::RGBA struct.

But indeed there is PointXYZRGB and PointXYZRGBA. And what I can see PointXYZRGB only has constructors that accept XYZ and RGB - ie. hides the alpha channel.

I don't see the necessary of having PointXYZRGB, since it still has the same size as PointXYZRGBA - but I don't see us removing it now anyways...? And pcl::RGB should be pcl::RGBA, since it does contain both the space and expose the alpha channel.

I would vote that the documentation explains this for the pcl::RGB struct though?

What do you think @mvieth ?

Agreed -- removing or renaming point types is not possible any more, but the documentation should say that the alpha value can be stored.

mvieth avatar Sep 26 '24 12:09 mvieth