osgEarth 2.1.1
Static Public Member Functions

agg::span_bgra32 Struct Reference

#include <AGG.h>

List of all members.

Static Public Member Functions

static void render (unsigned char *ptr, int x, unsigned count, const unsigned char *covers, const rgba8 &c)
static void hline (unsigned char *ptr, int x, unsigned count, const rgba8 &c)
static rgba8 get (unsigned char *ptr, int x)

Detailed Description

Definition at line 1164 of file AGG.h.


Member Function Documentation

static rgba8 agg::span_bgra32::get ( unsigned char *  ptr,
int  x 
) [inline, static]

Definition at line 1200 of file AGG.h.

        {
            unsigned char* p = ptr + (x << 2);
            rgba8 c;
            c.b = *p++; 
            c.g = *p++; 
            c.r = *p++;
            c.a = *p;
            return c;
        }
static void agg::span_bgra32::hline ( unsigned char *  ptr,
int  x,
unsigned  count,
const rgba8 c 
) [inline, static]

Definition at line 1190 of file AGG.h.

        {
            unsigned char* p = ptr + (x << 2);
            do { *p++ = c.b; *p++ = c.g; *p++ = c.r; *p++ = c.a; } while(--count);
        }
static void agg::span_bgra32::render ( unsigned char *  ptr,
int  x,
unsigned  count,
const unsigned char *  covers,
const rgba8 c 
) [inline, static]

Definition at line 1167 of file AGG.h.

        {
            unsigned char* p = ptr + (x << 2);
            do
            {
                int alpha = (*covers++) * c.a;
                int b = p[0];
                int g = p[1];
                int r = p[2];
                int a = p[3];
                *p++ = (((c.b - b) * alpha) + (b << 16)) >> 16;
                *p++ = (((c.g - g) * alpha) + (g << 16)) >> 16;
                *p++ = (((c.r - r) * alpha) + (r << 16)) >> 16;
                *p++ = (((c.a - a) * alpha) + (a << 16)) >> 16;
            }
            while(--count);
        }

The documentation for this struct was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines