Skip to content

(feat SensorModelling) add pixel_order field #698

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions osi_sensorview.proto
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,10 @@ message CameraSensorView

// Raw image data.
//
// The raw image data in the memory layout and order specified by the
// camera sensor input configuration.
// The raw image data in the memory layout specified by the camera
// sensor input configuration. The pixel order is specified in
// CameraSensorViewConfiguration.pixel_order with the
// default value PIXEL_ORDER_DEFAULT (i.e. left-to-right, top-to-bottom).
//
optional bytes image_data = 2;
}
Expand Down
47 changes: 47 additions & 0 deletions osi_sensorviewconfiguration.proto
Original file line number Diff line number Diff line change
Expand Up @@ -729,6 +729,53 @@ message CameraSensorViewConfiguration
//
repeated WavelengthData wavelength_data = 11;

// Indicates if and how the the pixel data is ordered
//
// The default value (PIXEL_ORDER_DEFAULT) indicates standard image
// pixel order (left-to-right, top-to-bottom). The other values can
// be used to indicate/request mirroring (right to left or bottom to top).
//
// \note For rotations of the pixel data, use the camera coordinate system.
//
optional PixelOrder pixel_order = 12;

// Pixel layout
//
// Pixel layout documents the order of pixels in the \c image_data
// in CameraSensorView.
//
// \note this enum does not contain an entry to do mirroring upside down
// and left-to-right at the same time, because this is equivalent to a
// 180-degree rotation, which should be indicated in the sensor coordinate
// system.
//
enum PixelOrder
{
// Pixel data is not mirrored (Default).
// Pixels are ordered left-to-right, top-to-bottom.
//
PIXEL_ORDER_DEFAULT = 0;

// Known pixel order that is not supported by OSI.
// Consider proposing an additional format if using
// \c #PIXEL_ORDER_OTHER.
//
PIXEL_ORDER_OTHER = 1;

// Pixels are ordered right-to-left, top-to-bottom.
// Pixel data is mirrored along the vertical axis.
// The image is mirrored left-to-right.
//
PIXEL_ORDER_RIGHT_LEFT_TOP_BOTTOM = 2;

// Pixels are ordered left-to-right, bottom-to-top.
// Pixel data is mirrored along the horizontal axis.
// The image is mirrored top-to-bottom.
//
PIXEL_ORDER_LEFT_RIGHT_BOTTOM_TOP = 3;
}


// Channel format.
//
enum ChannelFormat
Expand Down