~thopiekar/arm-mali/libvdpau-sunxi

« back to all changes in this revision

Viewing changes to presentation_queue.c

  • Committer: Andreas Baierl
  • Date: 2016-02-24 18:03:56 UTC
  • Revision ID: git-v1:974735847aa640af2ef8f97dfce9504fd0c81ebc
Add CPU fallback for G2D

This adds a CPU fallback for G2D using pixman (www.pixman.org)
for 2D filling and blitting actions in case of missing
G2D mixer processor on devices != A10/A20.
The software fallback is one of the requirements for OSD support
on Allwinner devices other than A10/A20.

Note: Pixman expects pixel data as premultiplied alpha values, so
you have to ensure, that your application uses the correct values.

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
        qt->disp = sunxi_disp_open(dev->osd_enabled);
59
59
 
60
60
        if (!qt->disp)
 
61
        {
 
62
                dev->osd_enabled = 0;
61
63
                qt->disp = sunxi_disp2_open(dev->osd_enabled);
 
64
        }
62
65
 
63
66
        if (!qt->disp)
 
67
        {
 
68
                dev->osd_enabled = 0;
64
69
                qt->disp = sunxi_disp1_5_open(dev->osd_enabled);
 
70
        }
65
71
 
66
72
        if (!qt->disp)
67
73
                return VDP_STATUS_ERROR;