JUCE  v5.1.1-3-g1a0b28c73
JUCE API
RenderingHelpers::GradientPixelIterators::Linear Class Reference

Iterates the colour of pixels in a linear gradient. More...

#include <juce_RenderingHelpers.h>

Collaboration diagram for RenderingHelpers::GradientPixelIterators::Linear:

Public Member Functions

 Linear (const ColourGradient &gradient, const AffineTransform &transform, const PixelARGB *const colours, const int numColours)
 
PixelARGB getPixel (const int x) const noexcept
 
forcedinline void setY (const int y) noexcept
 

Private Types

enum  { numScaleBits = 12 }
 

Private Attributes

double grad
 
bool horizontal
 
PixelARGB linePix
 
const PixelARGB *const lookupTable
 
const int numEntries
 
int scale
 
int start
 
bool vertical
 
double yTerm
 

Detailed Description

Iterates the colour of pixels in a linear gradient.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
numScaleBits 

Constructor & Destructor Documentation

◆ Linear()

RenderingHelpers::GradientPixelIterators::Linear::Linear ( const ColourGradient gradient,
const AffineTransform transform,
const PixelARGB *const  colours,
const int  numColours 
)
inline

Member Function Documentation

◆ getPixel()

PixelARGB RenderingHelpers::GradientPixelIterators::Linear::getPixel ( const int  x) const
inlinenoexcept

References jlimit(), and scale.

◆ setY()

forcedinline void RenderingHelpers::GradientPixelIterators::Linear::setY ( const int  y)
inlinenoexcept

References jlimit(), juce::roundToInt(), and scale.

Member Data Documentation

◆ grad

double RenderingHelpers::GradientPixelIterators::Linear::grad
private

◆ horizontal

bool RenderingHelpers::GradientPixelIterators::Linear::horizontal
private

◆ linePix

PixelARGB RenderingHelpers::GradientPixelIterators::Linear::linePix
private

◆ lookupTable

const PixelARGB* const RenderingHelpers::GradientPixelIterators::Linear::lookupTable
private

◆ numEntries

const int RenderingHelpers::GradientPixelIterators::Linear::numEntries
private

◆ scale

int RenderingHelpers::GradientPixelIterators::Linear::scale
private

◆ start

int RenderingHelpers::GradientPixelIterators::Linear::start
private

◆ vertical

bool RenderingHelpers::GradientPixelIterators::Linear::vertical
private

◆ yTerm

double RenderingHelpers::GradientPixelIterators::Linear::yTerm
private

The documentation for this class was generated from the following file: