O'Reilly logo

OpenCL in Action: How to Accelerate Graphics and Computation by Matthew Scarpino

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. Image processing

 

This chapter covers
  • Understanding the data types used in OpenCL image processing
  • Invoking functions that read, write, and access image data
  • Interpolating between pixel colors using samplers

 

Memory objects package data sent between a host and a device, and as discussed in chapter 3, they come in two types: buffer objects and image objects. Buffer objects transfer general-purpose data, and so far, all of the example code in this book has relied exclusively on buffer objects.

Now we’re going to switch gears and focus on image objects. In theory, you could store an image’s data in a buffer object and access its pixels as regular buffer data. But there are four important reasons to use image objects instead: ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required