Connecting RGB888 format camera device to TX2

Hello all,

I am trying to input RGB888 image data from Camera device to TX2, but it does not work. I referred several forum topics, and I understood as follows.

· JETSON’s V4L2 does not support RGB888 format, so mapping to AR24 (BGRA) is recommended.
< -fpga-on-jetson-tx2-evaluation-board/>
I tried to create Image file corresponding to input RGB888, but pixel format was converted to AR24 automatically at V4L2. And, acquisition of RGB888 data failed.

· On the other hand, NVCSI supports RGB888, but not supports AR24 (TRM; Input Data Format 27.10.1).
TX2 does not start up by using Image file corresponding to AR24. Is this because NVCSI is not support AR24?

It looks there is no way to connect a device that outputs RGB888 to TX2.
If there is a way, I would like to know it.

Thank you.

hello sumisumisumi,

we don’t support RGB888 by default,
please refer to /kernel_src/kernel/kernel-4.4/include/uapi/linux/videodev2.h
you might have a try to configure it as below.

#define V4L2_PIX_FMT_RGB24   v4l2_fourcc('R', 'G', 'B', '3') /* 24  RGB-8-8-8     */

you should also extend the supported pixel formats as below.

static int extract_pixel_format(const char *pixel_t, u32 *format)


static const struct camera_common_colorfmt camera_common_color_fmts[] = {

Hello, JerryChang

Thank you for quick response.
However, I already tried pixel formats extension code as follows.

static int extract_pixel_format(const char *pixel_t, u32 *format)

else if (strncmp(pixel_t, "rgb", size) == 0)
        *format = V4L2_PIX_FMT_RGB24

static const struct camera_common_colorfmt camera_common_color_fmts =


However, V4L2 automatically converts it to AR24.
Also, I tried accessing data as AR24. But I could not acquire any data.
Does it need more additional process?

When I tried the same thing in UYVY format, it worked without problems.

hello sumisumisumi,

could you please share details logs about the failure.
also, may I know how did you consider that V4L2 automatically converts it to AR24.


We were able to get an rgb888 sensor working on Tx2 and Xavier. Other than adding code similar to what has been mentioned in this thread already I don’t think we needed to anything special to get the camera to work.

We used this basic pipeline for verification:

gst-launch-1.0 v4l2src ! videoconvert ! ximagesink


I tried executing the following command, but it was not working.

gst-launch-1.0 v4l2src ! videoconvert ! ximagesink

message is as follows.

Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

Processing stops here.
gst-launch-1.0 icon appears, but the picture is not displayed.
When I close icon, error message appears as shown below.

ERROR: from element /GstPipeline:pipeline0/GstXImageSink:ximagesink0: Output window was closed
Additional debug info:
ximagesink.c(700): gst_x_image_sink_handle_xevents (): /GstPieline:pipeline0/GstXImageSink:ximagesink0
Execution ended after .......
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ..

Also, if I use the following command, the Pixel Format becomes ‘AR24’ even though it is set as RGB888.

v4l2-ctl --list-formats

Output is

     index       : 0
     Type        : Video Capture
     Pixel Format: 'AR24'
     Name        : 32-bit BGRA 8-8-8-8

Is it okay to ignore this?

Thank you

How to make this RGB888 instead of ‘AR24’ ? Could you do it?

hello hburaksaruhan,

let’s tracking at Topic 1051967 since you initial another discussion thread for this, thanks