Prusa Slicer 2.6.0
Loading...
Searching...
No Matches
agg::pixfmt_srgb24_gamma< Gamma > Class Template Reference

#include <src/agg/agg_pixfmt_rgb.h>

+ Inheritance diagram for agg::pixfmt_srgb24_gamma< Gamma >:
+ Collaboration diagram for agg::pixfmt_srgb24_gamma< Gamma >:

Public Types

enum  
 
typedef pixfmt_rgb_tag pixfmt_category
 
typedef rendering_buffer rbuf_type
 
typedef blender_rgb_gamma< srgba8, order_rgb, Gamma > blender_type
 
typedef rbuf_type::row_data row_data
 
typedef blender_type::color_type color_type
 
typedef blender_type::order_type order_type
 
typedef color_type::value_type value_type
 
typedef color_type::calc_type calc_type
 

Public Member Functions

 pixfmt_srgb24_gamma (rendering_buffer &rb, const Gamma &g)
 
void attach (rbuf_type &rb)
 
bool attach (PixFmt &pixf, int x1, int y1, int x2, int y2)
 
blender_rgb_gamma< srgba8, order_rgb, Gamma > & blender ()
 
AGG_INLINE unsigned width () const
 
AGG_INLINE unsigned height () const
 
AGG_INLINE int stride () const
 
AGG_INLINE int8urow_ptr (int y)
 
AGG_INLINE const int8urow_ptr (int y) const
 
AGG_INLINE row_data row (int y) const
 
AGG_INLINE int8upix_ptr (int x, int y)
 
AGG_INLINE const int8upix_ptr (int x, int y) const
 
AGG_INLINE pixel_type * pix_value_ptr (int x, int y, unsigned len)
 
AGG_INLINE const pixel_type * pix_value_ptr (int x, int y) const
 
AGG_INLINE color_type pixel (int x, int y) const
 
AGG_INLINE void copy_pixel (int x, int y, const color_type &c)
 
AGG_INLINE void blend_pixel (int x, int y, const color_type &c, int8u cover)
 
AGG_INLINE void copy_hline (int x, int y, unsigned len, const color_type &c)
 
AGG_INLINE void copy_vline (int x, int y, unsigned len, const color_type &c)
 
void blend_hline (int x, int y, unsigned len, const color_type &c, int8u cover)
 
void blend_vline (int x, int y, unsigned len, const color_type &c, int8u cover)
 
void blend_solid_hspan (int x, int y, unsigned len, const color_type &c, const int8u *covers)
 
void blend_solid_vspan (int x, int y, unsigned len, const color_type &c, const int8u *covers)
 
void copy_color_hspan (int x, int y, unsigned len, const color_type *colors)
 
void copy_color_vspan (int x, int y, unsigned len, const color_type *colors)
 
void blend_color_hspan (int x, int y, unsigned len, const color_type *colors, const int8u *covers, int8u cover)
 
void blend_color_vspan (int x, int y, unsigned len, const color_type *colors, const int8u *covers, int8u cover)
 
void for_each_pixel (Function f)
 
void apply_gamma_dir (const GammaLut &g)
 
void apply_gamma_inv (const GammaLut &g)
 
void copy_from (const RenBuf2 &from, int xdst, int ydst, int xsrc, int ysrc, unsigned len)
 
void blend_from (const SrcPixelFormatRenderer &from, int xdst, int ydst, int xsrc, int ysrc, unsigned len, int8u cover)
 
void blend_from_color (const SrcPixelFormatRenderer &from, const color_type &color, int xdst, int ydst, int xsrc, int ysrc, unsigned len, int8u cover)
 
void blend_from_lut (const SrcPixelFormatRenderer &from, const color_type *color_lut, int xdst, int ydst, int xsrc, int ysrc, unsigned len, int8u cover)
 

Static Public Member Functions

static AGG_INLINE pixel_type * pix_value_ptr (void *p)
 
static AGG_INLINE const pixel_type * pix_value_ptr (const void *p)
 
static AGG_INLINE void write_plain_color (void *p, color_type c)
 
static AGG_INLINE color_type read_plain_color (const void *p)
 
static AGG_INLINE void make_pix (int8u *p, const color_type &c)
 

Private Member Functions

AGG_INLINE void blend_pix (pixel_type *p, value_type r, value_type g, value_type b, value_type a, unsigned cover)
 
AGG_INLINE void blend_pix (pixel_type *p, value_type r, value_type g, value_type b, value_type a)
 
AGG_INLINE void blend_pix (pixel_type *p, const color_type &c, unsigned cover)
 
AGG_INLINE void blend_pix (pixel_type *p, const color_type &c)
 
AGG_INLINE void copy_or_blend_pix (pixel_type *p, const color_type &c, unsigned cover)
 
AGG_INLINE void copy_or_blend_pix (pixel_type *p, const color_type &c)
 

Private Attributes

rbuf_typem_rbuf
 
blender_rgb_gamma< srgba8, order_rgb, Gamma > m_blender
 

Detailed Description

template<class Gamma>
class agg::pixfmt_srgb24_gamma< Gamma >

Member Typedef Documentation

◆ blender_type

typedef blender_rgb_gamma< srgba8, order_rgb, Gamma > agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blender_type
inherited

◆ calc_type

◆ color_type

◆ order_type

◆ pixfmt_category

typedef pixfmt_rgb_tag agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pixfmt_category
inherited

◆ rbuf_type

typedef rendering_buffer agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::rbuf_type
inherited

◆ row_data

◆ value_type

Member Enumeration Documentation

◆ anonymous enum

Constructor & Destructor Documentation

◆ pixfmt_srgb24_gamma()

template<class Gamma >
agg::pixfmt_srgb24_gamma< Gamma >::pixfmt_srgb24_gamma ( rendering_buffer rb,
const Gamma &  g 
)
inline
937 :
938 pixfmt_alpha_blend_rgb<blender_rgb_gamma<srgba8, order_rgb, Gamma>, rendering_buffer, 3>(rb)
939 {
940 this->blender().gamma(g);
941 }
void gamma(const gamma_type &g)
Definition agg_pixfmt_rgb.h:154
blender_rgb_gamma< srgba8, order_rgb, Gamma > & blender()
Definition agg_pixfmt_rgb.h:337
row_accessor< int8u > rendering_buffer
Definition agg_rendering_buffer.h:294

References agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma >, rendering_buffer, 3 >::blender(), and agg::blender_rgb_gamma< ColorT, Order, Gamma >::gamma().

+ Here is the call graph for this function:

Member Function Documentation

◆ apply_gamma_dir()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::apply_gamma_dir ( const GammaLut &  g)
inlineinherited
694 {
695 for_each_pixel(apply_gamma_dir_rgb<color_type, order_type, GammaLut>(g));
696 }

◆ apply_gamma_inv()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::apply_gamma_inv ( const GammaLut &  g)
inlineinherited
700 {
701 for_each_pixel(apply_gamma_inv_rgb<color_type, order_type, GammaLut>(g));
702 }

◆ attach() [1/2]

bool agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::attach ( PixFmt &  pixf,
int  x1,
int  y1,
int  x2,
int  y2 
)
inlineinherited
322 {
323 rect_i r(x1, y1, x2, y2);
324 if (r.clip(rect_i(0, 0, pixf.width()-1, pixf.height()-1)))
325 {
326 int stride = pixf.stride();
327 m_rbuf->attach(pixf.pix_ptr(r.x1, stride < 0 ? r.y2 : r.y1),
328 (r.x2 - r.x1) + 1,
329 (r.y2 - r.y1) + 1,
330 stride);
331 return true;
332 }
333 return false;
334 }
void attach(T *buf, unsigned width, unsigned height, int stride)
Definition agg_rendering_buffer.h:57
rect_base< int > rect_i
Definition agg_basics.h:363

◆ attach() [2/2]

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::attach ( rbuf_type rb)
inlineinherited
317{ m_rbuf = &rb; }

◆ blend_color_hspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_color_hspan ( int  x,
int  y,
unsigned  len,
const color_type colors,
const int8u covers,
int8u  cover 
)
inlineinherited
601 {
602 pixel_type* p = pix_value_ptr(x, y, len);
603
604 if (covers)
605 {
606 do
607 {
608 copy_or_blend_pix(p, *colors++, *covers++);
609 p = p->next();
610 }
611 while (--len);
612 }
613 else
614 {
615 if (cover == cover_mask)
616 {
617 do
618 {
619 copy_or_blend_pix(p, *colors++);
620 p = p->next();
621 }
622 while (--len);
623 }
624 else
625 {
626 do
627 {
628 copy_or_blend_pix(p, *colors++, cover);
629 p = p->next();
630 }
631 while (--len);
632 }
633 }
634 }
AGG_INLINE void copy_or_blend_pix(pixel_type *p, const color_type &c, unsigned cover)
Definition agg_pixfmt_rgb.h:281
AGG_INLINE pixel_type * pix_value_ptr(int x, int y, unsigned len)
Definition agg_pixfmt_rgb.h:361

◆ blend_color_vspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_color_vspan ( int  x,
int  y,
unsigned  len,
const color_type colors,
const int8u covers,
int8u  cover 
)
inlineinherited
642 {
643 if (covers)
644 {
645 do
646 {
647 copy_or_blend_pix(pix_value_ptr(x, y++, 1), *colors++, *covers++);
648 }
649 while (--len);
650 }
651 else
652 {
653 if (cover == cover_mask)
654 {
655 do
656 {
657 copy_or_blend_pix(pix_value_ptr(x, y++, 1), *colors++);
658 }
659 while (--len);
660 }
661 else
662 {
663 do
664 {
665 copy_or_blend_pix(pix_value_ptr(x, y++, 1), *colors++, cover);
666 }
667 while (--len);
668 }
669 }
670 }

◆ blend_from()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_from ( const SrcPixelFormatRenderer &  from,
int  xdst,
int  ydst,
int  xsrc,
int  ysrc,
unsigned  len,
int8u  cover 
)
inlineinherited
727 {
728 typedef typename SrcPixelFormatRenderer::pixel_type src_pixel_type;
729 typedef typename SrcPixelFormatRenderer::order_type src_order;
730
731 if (const src_pixel_type* psrc = from.pix_value_ptr(xsrc, ysrc))
732 {
733 pixel_type* pdst = pix_value_ptr(xdst, ydst, len);
734
735 if (cover == cover_mask)
736 {
737 do
738 {
739 value_type alpha = psrc->c[src_order::A];
740 if (alpha <= color_type::empty_value())
741 {
742 if (alpha >= color_type::full_value())
743 {
744 pdst->c[order_type::R] = psrc->c[src_order::R];
745 pdst->c[order_type::G] = psrc->c[src_order::G];
746 pdst->c[order_type::B] = psrc->c[src_order::B];
747 }
748 else
749 {
750 blend_pix(pdst,
751 psrc->c[src_order::R],
752 psrc->c[src_order::G],
753 psrc->c[src_order::B],
754 alpha);
755 }
756 }
757 psrc = psrc->next();
758 pdst = pdst->next();
759 }
760 while(--len);
761 }
762 else
763 {
764 do
765 {
766 copy_or_blend_pix(pdst, psrc->get(), cover);
767 psrc = psrc->next();
768 pdst = pdst->next();
769 }
770 while (--len);
771 }
772 }
773 }
AGG_INLINE void blend_pix(pixel_type *p, value_type r, value_type g, value_type b, value_type a, unsigned cover)
Definition agg_pixfmt_rgb.h:254

◆ blend_from_color()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_from_color ( const SrcPixelFormatRenderer &  from,
const color_type color,
int  xdst,
int  ydst,
int  xsrc,
int  ysrc,
unsigned  len,
int8u  cover 
)
inlineinherited
784 {
785 typedef typename SrcPixelFormatRenderer::pixel_type src_pixel_type;
786 typedef typename SrcPixelFormatRenderer::color_type src_color_type;
787
788 if (const src_pixel_type* psrc = from.pix_value_ptr(xsrc, ysrc))
789 {
790 pixel_type* pdst = pix_value_ptr(xdst, ydst, len);
791
792 do
793 {
794 copy_or_blend_pix(pdst, color, src_color_type::scale_cover(cover, psrc->c[0]));
795 psrc = psrc->next();
796 pdst = pdst->next();
797 }
798 while (--len);
799 }
800 }

◆ blend_from_lut()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_from_lut ( const SrcPixelFormatRenderer &  from,
const color_type color_lut,
int  xdst,
int  ydst,
int  xsrc,
int  ysrc,
unsigned  len,
int8u  cover 
)
inlineinherited
812 {
813 typedef typename SrcPixelFormatRenderer::pixel_type src_pixel_type;
814
815 if (const src_pixel_type* psrc = from.pix_value_ptr(xsrc, ysrc))
816 {
817 pixel_type* pdst = pix_value_ptr(xdst, ydst, len);
818
819 if (cover == cover_mask)
820 {
821 do
822 {
823 const color_type& color = color_lut[psrc->c[0]];
824 blend_pix(pdst, color);
825 psrc = psrc->next();
826 pdst = pdst->next();
827 }
828 while(--len);
829 }
830 else
831 {
832 do
833 {
834 copy_or_blend_pix(pdst, color_lut[psrc->c[0]], cover);
835 psrc = psrc->next();
836 pdst = pdst->next();
837 }
838 while(--len);
839 }
840 }
841 }

◆ blend_hline()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_hline ( int  x,
int  y,
unsigned  len,
const color_type c,
int8u  cover 
)
inlineinherited
459 {
460 if (!c.is_transparent())
461 {
462 pixel_type* p = pix_value_ptr(x, y, len);
463
464 if (c.is_opaque() && cover == cover_mask)
465 {
466 do
467 {
468 p->set(c);
469 p = p->next();
470 }
471 while (--len);
472 }
473 else
474 {
475 do
476 {
477 blend_pix(p, c, cover);
478 p = p->next();
479 }
480 while (--len);
481 }
482 }
483 }

◆ blend_pix() [1/4]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_pix ( pixel_type *  p,
const color_type c 
)
inlineprivateinherited
276 {
277 m_blender.blend_pix(p->c, c.r, c.g, c.b, c.a);
278 }
AGG_INLINE void blend_pix(value_type *p, value_type cr, value_type cg, value_type cb, value_type alpha, cover_type cover)
Definition agg_pixfmt_rgb.h:157
blender_rgb_gamma< srgba8, order_rgb, Gamma > m_blender
Definition agg_pixfmt_rgb.h:845

◆ blend_pix() [2/4]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_pix ( pixel_type *  p,
const color_type c,
unsigned  cover 
)
inlineprivateinherited
270 {
271 m_blender.blend_pix(p->c, c.r, c.g, c.b, c.a, cover);
272 }

◆ blend_pix() [3/4]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_pix ( pixel_type *  p,
value_type  r,
value_type  g,
value_type  b,
value_type  a 
)
inlineprivateinherited
264 {
265 m_blender.blend_pix(p->c, r, g, b, a);
266 }

◆ blend_pix() [4/4]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_pix ( pixel_type *  p,
value_type  r,
value_type  g,
value_type  b,
value_type  a,
unsigned  cover 
)
inlineprivateinherited
257 {
258 m_blender.blend_pix(p->c, r, g, b, a, cover);
259 }

◆ blend_pixel()

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_pixel ( int  x,
int  y,
const color_type c,
int8u  cover 
)
inlineinherited
423 {
424 copy_or_blend_pix(pix_value_ptr(x, y, 1), c, cover);
425 }

◆ blend_solid_hspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_solid_hspan ( int  x,
int  y,
unsigned  len,
const color_type c,
const int8u covers 
)
inlineinherited
518 {
519 if (!c.is_transparent())
520 {
521 pixel_type* p = pix_value_ptr(x, y, len);
522
523 do
524 {
525 if (c.is_opaque() && *covers == cover_mask)
526 {
527 p->set(c);
528 }
529 else
530 {
531 blend_pix(p, c, *covers);
532 }
533 p = p->next();
534 ++covers;
535 }
536 while (--len);
537 }
538 }

◆ blend_solid_vspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_solid_vspan ( int  x,
int  y,
unsigned  len,
const color_type c,
const int8u covers 
)
inlineinherited
546 {
547 if (!c.is_transparent())
548 {
549 do
550 {
551 pixel_type* p = pix_value_ptr(x, y++, 1);
552
553 if (c.is_opaque() && *covers == cover_mask)
554 {
555 p->set(c);
556 }
557 else
558 {
559 blend_pix(p, c, *covers);
560 }
561 ++covers;
562 }
563 while (--len);
564 }
565 }

◆ blend_vline()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blend_vline ( int  x,
int  y,
unsigned  len,
const color_type c,
int8u  cover 
)
inlineinherited
491 {
492 if (!c.is_transparent())
493 {
494 if (c.is_opaque() && cover == cover_mask)
495 {
496 do
497 {
498 pix_value_ptr(x, y++, 1)->set(c);
499 }
500 while (--len);
501 }
502 else
503 {
504 do
505 {
506 blend_pix(pix_value_ptr(x, y++, 1), c, cover);
507 }
508 while (--len);
509 }
510 }
511 }

◆ blender()

blender_rgb_gamma< srgba8, order_rgb, Gamma > & agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::blender ( )
inlineinherited
337{ return m_blender; }

◆ copy_color_hspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_color_hspan ( int  x,
int  y,
unsigned  len,
const color_type colors 
)
inlineinherited
571 {
572 pixel_type* p = pix_value_ptr(x, y, len);
573
574 do
575 {
576 p->set(*colors++);
577 p = p->next();
578 }
579 while (--len);
580 }

◆ copy_color_vspan()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_color_vspan ( int  x,
int  y,
unsigned  len,
const color_type colors 
)
inlineinherited
587 {
588 do
589 {
590 pix_value_ptr(x, y++, 1)->set(*colors++);
591 }
592 while (--len);
593 }

◆ copy_from()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_from ( const RenBuf2 &  from,
int  xdst,
int  ydst,
int  xsrc,
int  ysrc,
unsigned  len 
)
inlineinherited
710 {
711 if (const int8u* p = from.row_ptr(ysrc))
712 {
713 memmove(m_rbuf->row_ptr(xdst, ydst, len) + xdst * pix_width,
714 p + xsrc * pix_width,
715 len * pix_width);
716 }
717 }
AGG_INLINE T * row_ptr(int, int y, unsigned)
Definition agg_rendering_buffer.h:81

◆ copy_hline()

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_hline ( int  x,
int  y,
unsigned  len,
const color_type c 
)
inlineinherited
431 {
432 pixel_type* p = pix_value_ptr(x, y, len);
433 do
434 {
435 p->set(c);
436 p = p->next();
437 }
438 while(--len);
439 }

◆ copy_or_blend_pix() [1/2]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_or_blend_pix ( pixel_type *  p,
const color_type c 
)
inlineprivateinherited
298 {
299 if (!c.is_transparent())
300 {
301 if (c.is_opaque())
302 {
303 p->set(c);
304 }
305 else
306 {
307 blend_pix(p, c);
308 }
309 }
310 }

◆ copy_or_blend_pix() [2/2]

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_or_blend_pix ( pixel_type *  p,
const color_type c,
unsigned  cover 
)
inlineprivateinherited
282 {
283 if (!c.is_transparent())
284 {
285 if (c.is_opaque() && cover == cover_mask)
286 {
287 p->set(c);
288 }
289 else
290 {
291 blend_pix(p, c, cover);
292 }
293 }
294 }

◆ copy_pixel()

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_pixel ( int  x,
int  y,
const color_type c 
)
inlineinherited
417 {
418 pix_value_ptr(x, y, 1)->set(c);
419 }

◆ copy_vline()

AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::copy_vline ( int  x,
int  y,
unsigned  len,
const color_type c 
)
inlineinherited
446 {
447 do
448 {
449 pix_value_ptr(x, y++, 1)->set(c);
450 }
451 while (--len);
452 }

◆ for_each_pixel()

void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::for_each_pixel ( Function  f)
inlineinherited
674 {
675 for (unsigned y = 0; y < height(); ++y)
676 {
677 row_data r = m_rbuf->row(y);
678 if (r.ptr)
679 {
680 unsigned len = r.x2 - r.x1 + 1;
681 pixel_type* p = pix_value_ptr(r.x1, y, len);
682 do
683 {
684 f(p->c);
685 p = p->next();
686 }
687 while (--len);
688 }
689 }
690 }
AGG_INLINE row_data row(int y) const
Definition agg_rendering_buffer.h:87
const Scalar & y
Definition MathFunctions.h:552
int x2
Definition agg_basics.h:544

◆ height()

AGG_INLINE unsigned agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::height ( ) const
inlineinherited
341{ return m_rbuf->height(); }
AGG_INLINE unsigned height() const
Definition agg_rendering_buffer.h:73

◆ make_pix()

static AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::make_pix ( int8u p,
const color_type c 
)
inlinestaticinherited
401 {
402 ((pixel_type*)p)->set(c);
403 }

◆ pix_ptr() [1/2]

AGG_INLINE int8u * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_ptr ( int  x,
int  y 
)
inlineinherited
351 {
352 return m_rbuf->row_ptr(y) + sizeof(value_type) * (x * pix_step + pix_offset);
353 }

◆ pix_ptr() [2/2]

AGG_INLINE const int8u * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_ptr ( int  x,
int  y 
) const
inlineinherited
356 {
357 return m_rbuf->row_ptr(y) + sizeof(value_type) * (x * pix_step + pix_offset);
358 }

◆ pix_value_ptr() [1/4]

static AGG_INLINE const pixel_type * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_value_ptr ( const void p)
inlinestaticinherited
381 {
382 return (const pixel_type*)((const value_type*)p + pix_offset);
383 }

◆ pix_value_ptr() [2/4]

AGG_INLINE const pixel_type * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_value_ptr ( int  x,
int  y 
) const
inlineinherited
368 {
369 int8u* p = m_rbuf->row_ptr(y);
370 return p ? (pixel_type*)(p + sizeof(value_type) * (x * pix_step + pix_offset)) : 0;
371 }
AGG_INT8U int8u
Definition agg_basics.h:120
TCoord< P > x(const P &p)
Definition geometry_traits.hpp:297

◆ pix_value_ptr() [3/4]

AGG_INLINE pixel_type * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_value_ptr ( int  x,
int  y,
unsigned  len 
)
inlineinherited
362 {
363 return (pixel_type*)(m_rbuf->row_ptr(x, y, len) + sizeof(value_type) * (x * pix_step + pix_offset));
364 }

◆ pix_value_ptr() [4/4]

static AGG_INLINE pixel_type * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pix_value_ptr ( void p)
inlinestaticinherited
375 {
376 return (pixel_type*)((value_type*)p + pix_offset);
377 }

◆ pixel()

AGG_INLINE color_type agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::pixel ( int  x,
int  y 
) const
inlineinherited
407 {
408 if (const pixel_type* p = pix_value_ptr(x, y))
409 {
410 return p->get();
411 }
412 return color_type::no_color();
413 }

◆ read_plain_color()

static AGG_INLINE color_type agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::read_plain_color ( const void p)
inlinestaticinherited
395 {
396 return pix_value_ptr(p)->get();
397 }

◆ row()

AGG_INLINE row_data agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::row ( int  y) const
inlineinherited
347{ return m_rbuf->row(y); }

◆ row_ptr() [1/2]

AGG_INLINE int8u * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::row_ptr ( int  y)
inlineinherited
345{ return m_rbuf->row_ptr(y); }

◆ row_ptr() [2/2]

AGG_INLINE const int8u * agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::row_ptr ( int  y) const
inlineinherited
346{ return m_rbuf->row_ptr(y); }

◆ stride()

AGG_INLINE int agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::stride ( ) const
inlineinherited
342{ return m_rbuf->stride(); }
AGG_INLINE int stride() const
Definition agg_rendering_buffer.h:74

◆ width()

AGG_INLINE unsigned agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::width ( ) const
inlineinherited
340{ return m_rbuf->width(); }
AGG_INLINE unsigned width() const
Definition agg_rendering_buffer.h:72

◆ write_plain_color()

static AGG_INLINE void agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::write_plain_color ( void p,
color_type  c 
)
inlinestaticinherited
387 {
388 // RGB formats are implicitly premultiplied.
389 c.premultiply();
390 pix_value_ptr(p)->set(c);
391 }

Member Data Documentation

◆ m_blender

blender_rgb_gamma< srgba8, order_rgb, Gamma > agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::m_blender
privateinherited

◆ m_rbuf

rbuf_type* agg::pixfmt_alpha_blend_rgb< blender_rgb_gamma< srgba8, order_rgb, Gamma > , rendering_buffer , Step, 0 >::m_rbuf
privateinherited

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