summaryrefslogtreecommitdiff
path: root/exynos/exynos_fimg2d.c
AgeCommit message (Collapse)Author
2015-03-10exynos: fimg2d: whitespace fix in g2d_flushTobias Jakobi
Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-10exynos: fimg2d: introduce G2D_OP_INTERPOLATETobias Jakobi
This sets up the blending equation in the following way: out = src * src_alpha + dst * (1 - src_alpha) Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
2015-03-10exynos: fimg2d: remove TRUE/FALSE from headerTobias Jakobi
The fimg2d header was defining TRUE and FALSE, but actually these defines are just used once. Remove them, since they don't make the code better readable/understandable. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-03-10exynos: introduce g2d_add_base_addr helper functionTobias Jakobi
In almost all functions the base address register is written, so it makes sense to have a helper function for this. v3: Wrap line as pointed out by Emil Velikov <emil.l.velikov@gmail.com>. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
2015-03-10tests/exynos: fix typos and change wordingTobias Jakobi
No functional changes. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
2015-03-10exynos: replace G2D_DOUBLE_TO_FIXED macro with functionTobias Jakobi
This also avoids the floating point conversion steps and just uses pure integer arithmetic. Since the G2D hardware scaling approach is a bit unintuitive, document it in the function as well. v2: Explicitly mention the normalization constant. v3: Use common commenting style as pointed out by Emil Velikov <emil.l.velikov@gmail.com>. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
2014-08-14exynos: Use symbol visibility.Maarten Lankhorst
No changes to exported symbols. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
2014-06-20exynos: fix scaling factor computation in g2d_copy_with_scaleTobias Jakobi
When division of source and destination width yields the scaling factor for the x-coordinate, then it should be source/destination _height_ for y. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2014-06-20exynos: fix coordinate computation in g2d_copyTobias Jakobi
The right-bottom register isn't set correctly. Looks like a copy-and-paste error. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2014-05-12exynos_fimg2d: fix cast from pointer to integer of different sizeDaniel Kurtz
Fixes two gcc [-Wpointer-to-int-cast] warnings. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Inki Dae <inki.dae@samsung.com>
2013-03-08libdrm/exynos: add test application for 2d gpu.Inki Dae
This patch adds library and test application for g2d gpu(fimg2d). The fimg2d hardware is a 2D graphics accelerator(G2D) that supports Bit Block Transfer(BitBLT). The library includes the following primitive drawing operations: .solid fill - This operation fills the given buffer with the given color data. .copy - This operation copies contents in source buffer to destination buffer. .copy_with_scale - This operation copies contents in source buffer to destination buffer scaling up or down properly. .blend - This operation blends contents in source buffer with the ones in destination buffer. And the above operations uses gem handle or user space address allocated by malloc() as source or destination buffer. And the test application includes just simple primitive drawing tests with the above library. And the guide to test is as the following, "#exynos_fimg2d_test -s connector_id@crtc_id:mode" With this above simple command, four primitive drawing operations would be called step by step and also rendered on the output device to the given connector and crtc id. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Rob Clark <robdclark@gmail.com>