From: Denys Dmytriyenko <denis@denix.org>
To: "Franklin S. Cooper Jr" <fcooper@ti.com>
Cc: meta-arago@arago-project.org
Subject: Re: [PATCH 1/6] qt4-embedded-gles: Add support for new version of the Graphics SDK
Date: Fri, 22 Nov 2013 10:02:36 -0500 [thread overview]
Message-ID: <20131122150236.GF32354@denix.org> (raw)
In-Reply-To: <1385135121-14345-1-git-send-email-fcooper@ti.com>
I believe I already had this set?
On Fri, Nov 22, 2013 at 09:45:16AM -0600, Franklin S. Cooper Jr wrote:
> * Add support for the Graphics SDK version 5.00.00.01
> * For now only apply the patches to AM43x and AM335x since this alpha release of
> the Graphics SDK has only been sanity tested for these platforms.
> * The official release should support all the typical platforms and this patch
> can be applied for all devices.
>
> Signed-off-by: Franklin S. Cooper Jr <fcooper@ti.com>
> ---
> ...hanges-for-integrating-with-TI-graphics-S.patch | 719 ++++++++++++++++++++
> .../recipes-qt/qt4/qt4-embedded-gles_4.8.4.bb | 4 +-
> 2 files changed, 722 insertions(+), 1 deletions(-)
> create mode 100644 meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles/0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch
>
> diff --git a/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles/0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch b/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles/0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch
> new file mode 100644
> index 0000000..73ef094
> --- /dev/null
> +++ b/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles/0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch
> @@ -0,0 +1,719 @@
> +From c463092eb5465cf7a7f9f783425dd75ec48d5f89 Mon Sep 17 00:00:00 2001
> +From: Prathap Srinivas <msprathap@ti.com>
> +Date: Tue, 5 Nov 2013 07:52:34 -0600
> +Subject: [PATCH] Qt 4.x v2: Changes for integrating with TI graphics SDK release 04.10.00.01
> +
> +This patch adds the changes required for Qt 4.x to work with 04.10 TI gfx sdk.
> +04.10.00.01 TI gfx sdk is based on 1.10 Linux DDK from Imagination Technologies
> +wsegl.h, pvr2d.h has been updated with 1.10 DDK.
> +This patch includes the updated files and also makes the required changes.
> +The changes are in QWSWSEGL to interface with updated wsegl.h.
> +
> +Version 2:
> +Updated to apply cleanly
> +---
> + src/3rdparty/powervr/wsegl2/pvr2d.h | 190 +++++++++++++-------
> + src/3rdparty/powervr/wsegl2/wsegl.h | 172 ++++++++++++------
> + .../gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c | 28 +++-
> + 3 files changed, 269 insertions(+), 121 deletions(-)
> +
> +diff --git a/src/3rdparty/powervr/wsegl2/pvr2d.h b/src/3rdparty/powervr/wsegl2/pvr2d.h
> +index 0f44833..d7e8123 100644
> +--- a/src/3rdparty/powervr/wsegl2/pvr2d.h
> ++++ b/src/3rdparty/powervr/wsegl2/pvr2d.h
> +@@ -1,39 +1,47 @@
> +-/**********************************************************************
> +-*
> +-* Copyright(c) Imagination Technologies Ltd.
> +-*
> +-* The contents of this file are subject to the MIT license as set out below.
> +-*
> +-* Permission is hereby granted, free of charge, to any person obtaining a copy
> +-* of this software and associated documentation files (the "Software"),
> +-* to deal in the Software without restriction, including without limitation
> +-* the rights to use, copy, modify, merge, publish, distribute, sublicense,
> +-* and/or sell copies of the Software, and to permit persons to whom the
> +-* Software is furnished to do so, subject to the following conditions:
> +-*
> +-* The above copyright notice and this permission notice shall be included
> +-* in all copies or substantial portions of the Software.
> +-*
> +-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
> +-* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
> +-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
> +-* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
> +-* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT
> +-* OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
> +-* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
> +-*
> +-* This License is also included in this distribution in the file called
> +-* "COPYING".
> +-*
> +-******************************************************************************/
> +-
> +-
> ++/*************************************************************************/ /*!
> ++@Copyright Copyright (c) Imagination Technologies Ltd. All Rights Reserved
> ++@License Dual MIT/GPLv2
> ++
> ++The contents of this file are subject to the MIT license as set out below.
> ++
> ++Permission is hereby granted, free of charge, to any person obtaining a copy
> ++of this software and associated documentation files (the "Software"), to deal
> ++in the Software without restriction, including without limitation the rights
> ++to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
> ++copies of the Software, and to permit persons to whom the Software is
> ++furnished to do so, subject to the following conditions:
> ++
> ++The above copyright notice and this permission notice shall be included in
> ++all copies or substantial portions of the Software.
> ++
> ++Alternatively, the contents of this file may be used under the terms of
> ++the GNU General Public License Version 2 ("GPL") in which case the provisions
> ++of GPL are applicable instead of those above.
> ++
> ++If you wish to allow use of your version of this file only under the terms of
> ++GPL, and not to allow others to use your version of this file under the terms
> ++of the MIT license, indicate your decision by deleting the provisions above
> ++and replace them with the notice and other provisions required by GPL as set
> ++out in the file called "GPL-COPYING" included in this distribution. If you do
> ++not delete the provisions above, a recipient may use your version of this file
> ++under the terms of either the MIT license or GPL.
> ++
> ++This License is also included in this distribution in the file called
> ++"MIT-COPYING".
> ++
> ++EXCEPT AS OTHERWISE STATED IN A NEGOTIATED AGREEMENT: (A) THE SOFTWARE IS
> ++PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
> ++BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
> ++PURPOSE AND NONINFRINGEMENT; AND (B) IN NO EVENT SHALL THE AUTHORS OR
> ++COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
> ++IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
> ++CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
> ++
> ++*/ /**************************************************************************/
> +
> + /******************************************************************************
> + Modifications :-
> + $Log: pvr2d.h $
> +-
> +- --- Revision Logs Removed ---
> + ******************************************************************************/
> +
> + #ifndef _PVR2D_H_
> +@@ -54,7 +62,7 @@ extern "C" {
> +
> + /* PVR2D header revision */
> + #define PVR2D_REV_MAJOR 3
> +-#define PVR2D_REV_MINOR 5
> ++#define PVR2D_REV_MINOR 6
> +
> + /* Basic types */
> + typedef enum
> +@@ -67,13 +75,20 @@ typedef void* PVR2D_HANDLE;
> +
> + typedef char PVR2D_CHAR, *PVR2D_PCHAR;
> + typedef unsigned char PVR2D_UCHAR, *PVR2D_PUCHAR;
> ++
> + typedef int PVR2D_INT, *PVR2D_PINT;
> + typedef unsigned int PVR2D_UINT, *PVR2D_PUINT;
> ++
> ++typedef unsigned short PVR2D_UINT16, *PVR2D_PUINT16;
> ++typedef signed short PVR2D_INT16, *PVR2D_PINT16;
> ++
> + typedef long PVR2D_LONG, *PVR2D_PLONG;
> + typedef unsigned long PVR2D_ULONG, *PVR2D_PULONG;
> +
> + typedef void PVR2D_VOID, *PVR2D_PVOID;
> +
> ++/* services/stream ID */
> ++typedef unsigned int PVR2D_SID;
> +
> + /* error codes */
> + typedef enum
> +@@ -99,7 +114,7 @@ typedef unsigned long PVR2DFORMAT;
> + #define PVR2D_1BPP 0x00UL // 1bpp mask surface or palletized 1 bit source with 2x32 bit CLUT
> + #define PVR2D_RGB565 0x01UL // Common rgb 565 format
> + #define PVR2D_ARGB4444 0x02UL // Common argb 4444 format
> +-#define PVR2D_RGB888 0x03UL // Common rgb 888 format (not supported)
> ++#define PVR2D_RGB888 0x03UL // Common rgb 888 format
> + #define PVR2D_ARGB8888 0x04UL // Common argb 8888 format
> + #define PVR2D_ARGB1555 0x05UL // Common argb 1555 format
> + #define PVR2D_ALPHA8 0x06UL // Alpha-only 8 bit per pixel (used with a constant fill colour)
> +@@ -114,16 +129,18 @@ typedef unsigned long PVR2DFORMAT;
> + #define PVR2D_YUV422_UYVY 0x14UL // YUV 422 low-high byte order UY0VY1
> + #define PVR2D_YUV422_YVYU 0x15UL // YUV 422 low-high byte order Y0VY1U
> + #define PVR2D_YUV422_VYUY 0x16UL // YUV 422 low-high byte order VY0UY1
> +-#define PVR2D_YUV420_2PLANE 0x17UL // YUV420 2 Plane
> +-#define PVR2D_YUV420_3PLANE 0x18UL // YUV420 3 Plane
> +-#define PVR2D_2101010ARGB 0x19UL // 32 bit 2 10 10 10
> +-#define PVR2D_888RSGSBS 0x1AUL
> ++#define PVR2D_YUV420_2PLANE 0x17UL // YUV420 2 Plane with UV interleaved in plane 2
> ++#define PVR2D_YVU420_3PLANE 0x18UL // YVU420 3 Plane
> ++#define PVR2D_YUV420_3PLANE 0x21UL // YUV420 3 Plane
> ++#define PVR2D_2101010ARGB 0x19UL // 32 bit 2 10 10 10
> ++#define PVR2D_888RSGSBS 0x1AUL // 3 channel signed 8 bit
> + #define PVR2D_16BPP_RAW 0x1BUL // 16 bit raw (no format conversion)
> + #define PVR2D_32BPP_RAW 0x1CUL // 32 bit raw
> + #define PVR2D_64BPP_RAW 0x1DUL // 64 bit raw
> + #define PVR2D_128BPP_RAW 0x1EUL // 128 bit raw
> +-
> +-#define PVR2D_NO_OF_FORMATS 0x1FUL
> ++#define PVR2D_AYUV8888 0x1FUL
> ++#define PVR2D_F16 0x20UL
> ++#define PVR2D_NO_OF_FORMATS 0x22UL
> +
> + /* Format modifier bit field (DstFormat and SrcFormat bits 16..23) */
> + #define PVR2D_FORMAT_MASK 0x0000FFFFUL // PVR2D Format bits
> +@@ -141,7 +158,8 @@ typedef unsigned long PVR2DFORMAT;
> + This flag requests a surface pdump, to capture the pixel state after host writes.
> + Not needed if the surface state has resulted from previous SGX 2D/3D core writes.
> + */
> +-#define PVR2D_SURFACE_PDUMP 0x00100000UL // calls PVRSRVPDumpMem to capture the surface (pdump builds only)
> ++#define PVR2D_SURFACE_PDUMP 0x00100000UL // calls PVRSRVPDumpMem to capture the surface (pdump builds only)
> ++#define PVR2D_BLTRECT_PDUMP 0x00200000UL // calls PVRSRVPDumpMem to capture the blt rectangle (pdump builds only)
> +
> + /*
> + Low level 3D format extension - for blts via the 3D core only.
> +@@ -155,8 +173,7 @@ typedef unsigned long PVR2DFORMAT;
> + typedef enum
> + {
> + PVR2D_WRAPFLAG_NONCONTIGUOUS = 0,
> +- PVR2D_WRAPFLAG_CONTIGUOUS = 1,
> +-
> ++ PVR2D_WRAPFLAG_CONTIGUOUS = 1
> + }PVR2DWRAPFLAGS;
> +
> + #define PVR2D_CONTEXT_FLAGS_PRIORITY_MASK 0x00000003
> +@@ -171,7 +188,7 @@ typedef enum
> + PVR2D_BLIT_DISABLE_ALL = 0x00000000, /* disable all additional controls */
> + PVR2D_BLIT_CK_ENABLE = 0x00000001, /* enable colour key */
> + PVR2D_BLIT_GLOBAL_ALPHA_ENABLE = 0x00000002, /* enable standard global alpha */
> +- PVR2D_BLIT_PERPIXEL_ALPHABLEND_ENABLE = 0x00000004, /* enable per-pixel alpha bleding */
> ++ PVR2D_BLIT_PERPIXEL_ALPHABLEND_ENABLE = 0x00000004, /* enable per-pixel alpha blending */
> + PVR2D_BLIT_PAT_SURFACE_ENABLE = 0x00000008, /* enable pattern surf (disable fill) */
> + PVR2D_BLIT_FULLY_SPECIFIED_ALPHA_ENABLE = 0x00000010, /* enable fully specified alpha */
> + PVR2D_BLIT_ROT_90 = 0x00000020, /* apply 90 degree rotation to the blt */
> +@@ -186,11 +203,12 @@ typedef enum
> + PVR2D_BLIT_COLKEY_MASKED = 0x00004000, /* Mask enabled for colour key */
> + PVR2D_BLIT_COLKEY_OP_PASS = 0x00008000, /* Colour key op = pass */
> + PVR2D_BLIT_COLKEY_OP_REJECT = 0x00010000, /* Colour key op = reject */
> ++ PVR2D_BLIT_ROP4 = 0x00020000, /* rop4 pattern support */
> + PVR2D_BLIT_PATH_2DCORE = 0x00100000, /* Blt via dedicated 2D Core or PTLA */
> + PVR2D_BLIT_PATH_3DCORE = 0x00200000, /* Blt via 3D Core */
> + PVR2D_BLIT_PATH_SWBLT = 0x00400000, /* Blt via host software */
> + PVR2D_BLIT_NO_SRC_SYNC_INFO = 0x00800000, /* Dont send a source sync info*/
> +- PVR2D_BLIT_ISSUE_STATUS_UPDATES = 0x01000000, /* Issue status updates */
> ++ PVR2D_BLIT_ISSUE_STATUS_UPDATES = 0x01000000, /* Issue SyncInfo status updates */
> +
> + } PVR2DBLITFLAGS;
> +
> +@@ -288,6 +306,17 @@ typedef struct _PVR2MISCDISPLAYINFO
> +
> + }PVR2DMISCDISPLAYINFO;
> +
> ++typedef struct
> ++{
> ++ PVR2DMEMINFO *pSurfMemInfo; /* surface memory */
> ++ PVR2D_ULONG SurfOffset; /* byte offset from start of allocation to destination surface pixel 0,0 */
> ++ PVR2D_LONG Stride; /* signed stride */
> ++ PVR2DFORMAT Format; /* format */
> ++ PVR2D_ULONG SurfWidth; /* surface width in pixels */
> ++ PVR2D_ULONG SurfHeight; /* surface height in pixels */
> ++
> ++} PVR2D_SURFACE, *PPVR2D_SURFACE;
> ++
> +
> + typedef struct _PVR2DBLTINFO
> + {
> +@@ -326,34 +355,28 @@ typedef struct _PVR2DBLTINFO
> + PVR2D_LONG MaskX, MaskY; /* mask rect top left (mask size = blt size) */
> + PVR2D_ULONG MaskSurfWidth; /* size of mask surface in pixels */
> + PVR2D_ULONG MaskSurfHeight; /* size of mask surface in pixels */
> +-
> ++
> + PPVR2D_ALPHABLT pAlpha; /* fully specified alpha blend (2DCore only) */
> +-
> ++
> + PVR2D_ULONG uSrcChromaPlane1; /* mem offset from start of source alloc to chroma plane 1 */
> + PVR2D_ULONG uSrcChromaPlane2; /* mem offset from start of source alloc to chroma plane 2 */
> + PVR2D_ULONG uDstChromaPlane1; /* mem offset from start of dest alloc to chroma plane 1 */
> + PVR2D_ULONG uDstChromaPlane2; /* mem offset from start of dest alloc to chroma plane 2 */
> +-
> ++
> + PVR2D_ULONG ColourKeyMask; /* 32 bit colour key mask, only valid when PVR2D_BLIT_COLKEY_MASKED is set */
> +
> ++ PPVR2D_SURFACE pPat; /* full rop4 support for patterns if PVR2D_BLIT_ROP4 set (2D Core hardware only) */
> ++ PVR2D_LONG PatX, PatY; /* pattern start offset if PVR2D_BLIT_ROP4 set (2D Core hardware only) */
> ++
> + }PVR2DBLTINFO, *PPVR2DBLTINFO;
> +
> ++
> + typedef struct _PVR2DRECT
> + {
> + PVR2D_LONG left, top;
> + PVR2D_LONG right, bottom;
> +-} PVR2DRECT;
> ++} PVR2DRECT, *PPVR2DRECT;
> +
> +-typedef struct
> +-{
> +- PVR2DMEMINFO *pSurfMemInfo; /* surface memory */
> +- PVR2D_ULONG SurfOffset; /* byte offset from start of allocation to destination surface pixel 0,0 */
> +- PVR2D_LONG Stride; /* signed stride */
> +- PVR2DFORMAT Format; /* format */
> +- PVR2D_ULONG SurfWidth; /* surface width in pixels */
> +- PVR2D_ULONG SurfHeight; /* surface height in pixels */
> +-
> +-} PVR2D_SURFACE, *PPVR2D_SURFACE;
> +
> + typedef struct
> + {
> +@@ -479,8 +502,8 @@ typedef void* PVR2DFLIPCHAINHANDLE;
> +
> + #define PVR2D_CREATE_FLIPCHAIN_SHARED (1UL << 0)
> + #define PVR2D_CREATE_FLIPCHAIN_QUERY (1UL << 1)
> +-#define PVR2D_CREATE_FLIPCHAIN_OEMOVERLAY (1UL << 2)
> +-#define PVR2D_CREATE_FLIPCHAIN_AS_BLITCHAIN (1UL << 3)
> ++#define PVR2D_CREATE_FLIPCHAIN_OEMOVERLAY (1UL << 2)
> ++#define PVR2D_CREATE_FLIPCHAIN_AS_BLITCHAIN (1UL << 3)
> +
> + /* Colour-key colour must be translated into argb8888 format */
> + #define CKEY_8888(P) (P)
> +@@ -498,7 +521,8 @@ typedef void* PVR2DFLIPCHAINHANDLE;
> + #define CFILL_565(P) (((P&0xF800UL)<<8) | ((P&0x7E0UL)<<5) | ((P&0x1FUL)<<3))
> +
> + /* PVR2DCreateDeviceContext flags */
> +-#define PVR2D_XSERVER_PROC 0x00000001UL /*!< Set for the Xserver connection */
> ++#define PVR2D_XSERVER_PROC 0x00000001UL /* Set for the Xserver connection */
> ++#define PVR2D_FLAGS_PDUMP_ACTIVE 0x00000002UL /* Set when pdumping from multiple processes */
> +
> + /* PVR2DMemAlloc flags */
> + #define PVR2D_MEM_UNCACHED 0x00000000UL /* Default */
> +@@ -508,7 +532,7 @@ typedef void* PVR2DFLIPCHAINHANDLE;
> + /* Functions that the library exports */
> +
> + PVR2D_IMPORT
> +-int PVR2DEnumerateDevices(PVR2DDEVICEINFO *pDevInfo);
> ++PVR2D_INT PVR2DEnumerateDevices(PVR2DDEVICEINFO *pDevInfo);
> +
> + PVR2D_IMPORT
> + PVR2DERROR PVR2DCreateDeviceContext(PVR2D_ULONG ulDevID,
> +@@ -633,7 +657,7 @@ PVR2DERROR PVR2DSetPresentFlipProperties(PVR2DCONTEXTHANDLE hContext,
> + PVR2D_ULONG ulPropertyMask,
> + PVR2D_LONG lDstXPos,
> + PVR2D_LONG lDstYPos,
> +- PVR2D_ULONG ulNumClipRects,
> ++ PVR2D_ULONG ulNumClipRects,
> + PVR2DRECT *pClipRects,
> + PVR2D_ULONG ulSwapInterval);
> +
> +@@ -658,6 +682,44 @@ PVR2DERROR PVR2DBlt3D (const PVR2DCONTEXTHANDLE hContext, const PPVR2D_3DBLT pBl
> + PVR2D_IMPORT
> + PVR2DERROR PVR2DBlt3DExt (const PVR2DCONTEXTHANDLE hContext, const PPVR2D_3DBLT_EXT pBlt3D);
> +
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DModifyPendingOps(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2D_HANDLE *phSyncModObj,
> ++ PVR2DMEMINFO *psMemInfo,
> ++ PVR2D_BOOL bIsWriteOp,
> ++ PVR2D_ULONG *pulReadOpsPending,
> ++ PVR2D_ULONG *pulWriteOpsPending);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DModifyCompleteOps(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2D_HANDLE hSyncModObj);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DFlushToSyncModObj(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2D_HANDLE hSyncModObj,
> ++ PVR2D_BOOL bWait);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DTakeSyncToken(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2DMEMINFO *psMemInfo,
> ++ PVR2D_HANDLE *phSyncToken,
> ++ PVR2D_ULONG *pulReadOpsPending,
> ++ PVR2D_ULONG *pulWriteOpsPending);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DReleaseSyncToken(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2D_HANDLE hSyncToken);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DFlushToSyncToken(const PVR2DCONTEXTHANDLE hContext,
> ++ PVR2DMEMINFO *psMemInfo,
> ++ PVR2D_HANDLE hSyncToken,
> ++ PVR2D_BOOL bWait);
> ++
> ++PVR2D_IMPORT
> ++PVR2DERROR PVR2DWaitForNextHardwareEvent(const PVR2DCONTEXTHANDLE hContext);
> ++
> + #ifdef __cplusplus
> + }
> + #endif
> +diff --git a/src/3rdparty/powervr/wsegl2/wsegl.h b/src/3rdparty/powervr/wsegl2/wsegl.h
> +index a2c3ffc..480179b 100644
> +--- a/src/3rdparty/powervr/wsegl2/wsegl.h
> ++++ b/src/3rdparty/powervr/wsegl2/wsegl.h
> +@@ -1,34 +1,43 @@
> +-/**********************************************************************
> +-*
> +-* Copyright(c) Imagination Technologies Ltd.
> +-*
> +-* The contents of this file are subject to the MIT license as set out below.
> +-*
> +-* Permission is hereby granted, free of charge, to any person obtaining a copy
> +-* of this software and associated documentation files (the "Software"),
> +-* to deal in the Software without restriction, including without limitation
> +-* the rights to use, copy, modify, merge, publish, distribute, sublicense,
> +-* and/or sell copies of the Software, and to permit persons to whom the
> +-* Software is furnished to do so, subject to the following conditions:
> +-*
> +-* The above copyright notice and this permission notice shall be included
> +-* in all copies or substantial portions of the Software.
> +-*
> +-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
> +-* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
> +-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
> +-* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
> +-* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT
> +-* OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
> +-* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
> +-*
> +-* This License is also included in this distribution in the file called
> +-* "COPYING".
> +-*
> +-******************************************************************************/
> +-
> +-
> +-
> ++/*************************************************************************/ /*!
> ++@Copyright Copyright (c) Imagination Technologies Ltd. All Rights Reserved
> ++@License Dual MIT/GPLv2
> ++
> ++The contents of this file are subject to the MIT license as set out below.
> ++
> ++Permission is hereby granted, free of charge, to any person obtaining a copy
> ++of this software and associated documentation files (the "Software"), to deal
> ++in the Software without restriction, including without limitation the rights
> ++to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
> ++copies of the Software, and to permit persons to whom the Software is
> ++furnished to do so, subject to the following conditions:
> ++
> ++The above copyright notice and this permission notice shall be included in
> ++all copies or substantial portions of the Software.
> ++
> ++Alternatively, the contents of this file may be used under the terms of
> ++the GNU General Public License Version 2 ("GPL") in which case the provisions
> ++of GPL are applicable instead of those above.
> ++
> ++If you wish to allow use of your version of this file only under the terms of
> ++GPL, and not to allow others to use your version of this file under the terms
> ++of the MIT license, indicate your decision by deleting the provisions above
> ++and replace them with the notice and other provisions required by GPL as set
> ++out in the file called "GPL-COPYING" included in this distribution. If you do
> ++not delete the provisions above, a recipient may use your version of this file
> ++under the terms of either the MIT license or GPL.
> ++
> ++This License is also included in this distribution in the file called
> ++"MIT-COPYING".
> ++
> ++EXCEPT AS OTHERWISE STATED IN A NEGOTIATED AGREEMENT: (A) THE SOFTWARE IS
> ++PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
> ++BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
> ++PURPOSE AND NONINFRINGEMENT; AND (B) IN NO EVENT SHALL THE AUTHORS OR
> ++COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
> ++IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
> ++CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
> ++
> ++*/ /**************************************************************************/
> + #if !defined(__WSEGL_H__)
> + #define __WSEGL_H__
> +
> +@@ -51,7 +60,7 @@ extern "C" {
> + // WSEGL API Version Number
> + */
> +
> +-#define WSEGL_VERSION 2
> ++#define WSEGL_VERSION 4
> + #define WSEGL_DEFAULT_DISPLAY 0
> + #define WSEGL_DEFAULT_NATIVE_ENGINE 0
> +
> +@@ -78,6 +87,11 @@ typedef enum WSEGLCapsType_TAG
> + WSEGL_CAP_WINDOWS_USE_HW_SYNC = 3, /* System default value = 0 (FALSE) */
> + WSEGL_CAP_PIXMAPS_USE_HW_SYNC = 4, /* System default value = 0 (FALSE) */
> +
> ++ /* When this capability is set, the EGL lock is not taken around calls
> ++ to WSEGL functions. The WSEGL module is responsible for performing
> ++ its own locking in this case. */
> ++ WSEGL_CAP_UNLOCKED = 5, /* System default value = 0 */
> ++
> + } WSEGLCapsType;
> +
> + /*
> +@@ -97,6 +111,19 @@ typedef struct WSEGLCaps_TAG
> + #define WSEGL_DRAWABLE_WINDOW 0x1
> + #define WSEGL_DRAWABLE_PIXMAP 0x2
> +
> ++/*
> ++// YUV format flags and sync
> ++*/
> ++#define WSEGL_FLAGS_YUV_CONFORMANT_RANGE (0 << 0)
> ++#define WSEGL_FLAGS_YUV_FULL_RANGE (1 << 0)
> ++#define WSEGL_FLAGS_YUV_BT601 (0 << 1)
> ++#define WSEGL_FLAGS_YUV_BT709 (1 << 1)
> ++#define WSEGL_FLAGS_EGLIMAGE_COMPOSITION_SYNC (1 << 2)
> ++
> ++/*
> ++// Maximum number of optional PowerVR Services 4 SYNCINFO objects
> ++*/
> ++#define WSEGL_MAX_SRC_SYNCS 32
> +
> + /*
> + // Pixel format of display/drawable
> +@@ -110,6 +137,16 @@ typedef enum WSEGLPixelFormat_TAG
> + WSEGL_PIXELFORMAT_ARGB1555 = 3,
> + WSEGL_PIXELFORMAT_ABGR8888 = 4,
> + WSEGL_PIXELFORMAT_XBGR8888 = 5,
> ++ WSEGL_PIXELFORMAT_NV12 = 6,
> ++ WSEGL_PIXELFORMAT_YUYV = 7,
> ++ WSEGL_PIXELFORMAT_YV12 = 8,
> ++ WSEGL_PIXELFORMAT_XRGB8888 = 9,
> ++ WSEGL_PIXELFORMAT_UYVY = 10,
> ++ WSEGL_PIXELFORMAT_NV12_4KALIGN = 11,
> ++ WSEGL_PIXELFORMAT_NV21_4KALIGN = 12,
> ++ WSEGL_PIXELFORMAT_R8 = 13,
> ++ WSEGL_PIXELFORMAT_R8G8 = 14,
> ++ WSEGL_PIXELFORMAT_NV21 = 15,
> +
> + /* These are compatibility names only; new WSEGL
> + * modules should not use them.
> +@@ -138,31 +175,33 @@ typedef struct WSEGLConfig_TAG
> + {
> + /*
> + // Type of drawables this configuration applies to -
> +- // OR'd values of drawable types.
> ++ // OR'd values of drawable types.
> + */
> +- unsigned long ui32DrawableType;
> ++ unsigned long ui32DrawableType;
> +
> + /* Pixel format */
> +- WSEGLPixelFormat ePixelFormat;
> ++ WSEGLPixelFormat ePixelFormat;
> +
> + /* Native Renderable - set to WSEGL_TRUE if native renderable */
> +- unsigned long ulNativeRenderable;
> ++ unsigned long ulNativeRenderable;
> +
> + /* FrameBuffer Level Parameter */
> +- unsigned long ulFrameBufferLevel;
> ++ unsigned long ulFrameBufferLevel;
> +
> + /* Native Visual ID */
> +- unsigned long ulNativeVisualID;
> ++ unsigned long ulNativeVisualID;
> +
> + /* Native Visual */
> +- void *hNativeVisual;
> ++ unsigned long ulNativeVisualType;
> +
> + /* Transparent Type */
> +- WSEGLTransparentType eTransparentType;
> ++ WSEGLTransparentType eTransparentType;
> +
> + /* Transparent Color - only used if transparent type is COLOR_KEY */
> +- unsigned long ulTransparentColor; /* packed as 0x00RRGGBB */
> ++ unsigned long ulTransparentColor; /* packed as 0x00RRGGBB */
> +
> ++ /* Framebuffer Target - set to WSEGL_TRUE if config compatible with framebuffer */
> ++ unsigned long ulFramebufferTarget;
> +
> + } WSEGLConfig;
> +
> +@@ -180,13 +219,14 @@ typedef enum WSEGLError_TAG
> + WSEGL_BAD_DRAWABLE = 6,
> + WSEGL_BAD_MATCH = 7,
> + WSEGL_OUT_OF_MEMORY = 8,
> ++ WSEGL_RETRY = 9,
> +
> + /* These are compatibility names only; new WSEGL
> + * modules should not use them.
> + */
> + WSEGL_BAD_CONFIG = WSEGL_BAD_MATCH,
> +
> +-} WSEGLError;
> ++} WSEGLError;
> +
> + /*
> + // Drawable orientation (in degrees anti-clockwise)
> +@@ -198,7 +238,7 @@ typedef enum WSEGLRotationAngle_TAG
> + WSEGL_ROTATE_180 = 2,
> + WSEGL_ROTATE_270 = 3
> +
> +-} WSEGLRotationAngle;
> ++} WSEGLRotationAngle;
> +
> + /*
> + // Drawable information required by OpenGL-ES driver
> +@@ -206,26 +246,46 @@ typedef enum WSEGLRotationAngle_TAG
> + typedef struct WSEGLDrawableParams_TAG
> + {
> + /* Width in pixels of the drawable */
> +- unsigned long ui32Width;
> ++ unsigned long ui32Width;
> +
> + /* Height in pixels of the drawable */
> +- unsigned long ui32Height;
> ++ unsigned long ui32Height;
> +
> + /* Stride in pixels of the drawable */
> +- unsigned long ui32Stride;
> ++ unsigned long ui32Stride;
> +
> + /* Pixel format of the drawable */
> +- WSEGLPixelFormat ePixelFormat;
> ++ WSEGLPixelFormat ePixelFormat;
> +
> + /* User space cpu virtual address of the drawable */
> +- void *pvLinearAddress;
> ++ void *pvLinearAddress;
> +
> + /* HW address of the drawable */
> +- unsigned long ui32HWAddress;
> ++ unsigned long ui32HWAddress;
> ++
> ++ /* Override display's HW_SYNC mode */
> ++ unsigned long bWaitForRender;
> +
> +- /* Private data for the drawable */
> +- void *hPrivateData;
> ++ /* Flags */
> ++ unsigned long ulFlags;
> +
> ++ /* Rotation angle of drawable (presently source only) */
> ++ WSEGLRotationAngle eRotationAngle;
> ++
> ++ /*
> ++ // Optional PowerVR Services 4 MEMINFO pointer. This may be used for
> ++ // internal (implicit) synchronization purposes, and by PDUMP. It should
> ++ // refer to the same object as the other fields in this structure.
> ++ */
> ++ void *hMemInfo;
> ++
> ++ /*
> ++ // Optional PowerVR Services 4 SYNCINFO pointers to sent down as source
> ++ // surface (texture) dependencies of a render. If these are provided
> ++ // when not applicable, they will be ignored. If a sync is not needed,
> ++ // it should be passed as NULL.
> ++ */
> ++ void *ahSyncInfo[WSEGL_MAX_SRC_SYNCS];
> +
> + } WSEGLDrawableParams;
> +
> +@@ -262,12 +322,18 @@ typedef struct WSEGL_FunctionTable_TAG
> +
> + WSEGLError (*pfnWSEGL_CopyFromPBuffer)(void *, unsigned long, unsigned long, unsigned long, WSEGLPixelFormat, NativePixmapType);
> +
> +- WSEGLError (*pfnWSEGL_GetDrawableParameters)(WSEGLDrawableHandle, WSEGLDrawableParams *, WSEGLDrawableParams *);
> ++ WSEGLError (*pfnWSEGL_GetDrawableParameters)(WSEGLDrawableHandle, WSEGLDrawableParams *, WSEGLDrawableParams *, unsigned long);
> +
> + WSEGLError (*pfnWSEGL_ConnectDrawable)(WSEGLDrawableHandle);
> +
> + WSEGLError (*pfnWSEGL_DisconnectDrawable)(WSEGLDrawableHandle);
> +
> ++ WSEGLError (*pfnWSEGL_FlagStartFrame)(void);
> ++
> ++
> ++#if defined (__QNXNTO__)
> ++ WSEGLError (*pfnWSEGL_WaitForDrawableRenderBuffer)(WSEGLDrawableHandle);
> ++#endif
> +
> + } WSEGL_FunctionTable;
> +
> +@@ -276,7 +342,7 @@ WSEGL_IMPORT const WSEGL_FunctionTable *WSEGL_GetFunctionTablePointer(void);
> +
> + #ifdef __cplusplus
> + }
> +-#endif
> ++#endif
> +
> + #endif /* __WSEGL_H__ */
> +
> +diff --git a/src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c b/src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c
> +index d42e59f..24e5b0d 100644
> +--- a/src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c
> ++++ b/src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c
> +@@ -336,12 +336,17 @@ static WSEGLError wseglCopyFromPBuffer
> + /* Return the parameters of a drawable that are needed by the EGL layer */
> + static WSEGLError wseglGetDrawableParameters
> + (WSEGLDrawableHandle _drawable, WSEGLDrawableParams *sourceParams,
> +- WSEGLDrawableParams *renderParams)
> ++ WSEGLDrawableParams *renderParams,unsigned long ulPlaneOffset)
> + {
> + PvrQwsDrawable *drawable = (PvrQwsDrawable *)_drawable;
> + PVR2DMEMINFO *source, *render;
> + WSEGLPixelFormat pixelFormat;
> +
> ++ WSEGL_UNREFERENCED_PARAMETER(ulPlaneOffset);
> ++
> ++ memset(renderParams, 0, sizeof(*renderParams));
> ++ memset(sourceParams, 0, sizeof(*sourceParams));
> ++
> + if (!pvrQwsGetBuffers(drawable, &source, &render))
> + return WSEGL_BAD_DRAWABLE;
> +
> +@@ -366,7 +371,7 @@ static WSEGLError wseglGetDrawableParameters
> + sourceParams->ePixelFormat = pixelFormat;
> + sourceParams->pvLinearAddress = source->pBase;
> + sourceParams->ui32HWAddress = source->ui32DevAddr;
> +- sourceParams->hPrivateData = source->hPrivateData;
> ++ sourceParams->hMemInfo = source->hPrivateData;
> +
> + renderParams->ui32Width = drawable->rect.width;
> + renderParams->ui32Height = drawable->rect.height;
> +@@ -374,7 +379,7 @@ static WSEGLError wseglGetDrawableParameters
> + renderParams->ePixelFormat = pixelFormat;
> + renderParams->pvLinearAddress = render->pBase;
> + renderParams->ui32HWAddress = render->ui32DevAddr;
> +- renderParams->hPrivateData = render->hPrivateData;
> ++ renderParams->hMemInfo = render->hPrivateData;
> +
> + return WSEGL_SUCCESS;
> + }
> +@@ -393,6 +398,20 @@ static WSEGLError wseglDisconnectDrawable(WSEGLDrawableHandle hDrawable)
> + return WSEGL_SUCCESS;
> + }
> +
> ++/***********************************************************************************
> ++ Function Name : WSEGL_FlagStartFrame
> ++ Inputs : hDrawable
> ++ Outputs : None
> ++ Returns : Error code
> ++ Description : Indicates that there have been rendering commands submitted
> ++ by a client driver
> ++************************************************************************************/
> ++static WSEGLError wseglFlagStartFrame(void)
> ++{
> ++ return WSEGL_SUCCESS;
> ++}
> ++
> ++
> + static WSEGL_FunctionTable const wseglFunctions = {
> + WSEGL_VERSION,
> + wseglIsDisplayValid,
> +@@ -408,7 +427,8 @@ static WSEGL_FunctionTable const wseglFunctions = {
> + wseglCopyFromPBuffer,
> + wseglGetDrawableParameters,
> + wseglConnectDrawable,
> +- wseglDisconnectDrawable
> ++ wseglDisconnectDrawable,
> ++ wseglFlagStartFrame,
> + };
> +
> + /* Return the table of WSEGL functions to the EGL implementation */
> +--
> +1.7.0.4
> +
> diff --git a/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles_4.8.4.bb b/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles_4.8.4.bb
> index fa2d31c..460de67 100644
> --- a/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles_4.8.4.bb
> +++ b/meta-arago-extras/recipes-qt/qt4/qt4-embedded-gles_4.8.4.bb
> @@ -1,7 +1,7 @@
> require ${COREBASE}/meta/recipes-qt/qt4/qt4-${PV}.inc
> require ${COREBASE}/meta/recipes-qt/qt4/qt4-embedded.inc
>
> -PR = "${INC_PR}.2"
> +PR = "${INC_PR}.3"
>
> FILESEXTRAPATHS_append := "${THISDIR}/${PN}:${COREBASE}/meta/recipes-qt/qt4/qt4-${PV}:${COREBASE}/meta/recipes-qt/qt4/files:"
>
> @@ -12,6 +12,8 @@ SRC_URI += " \
> file://002_pvrqwswsegl.c.patch \
> file://cursor-hack.diff \
> "
> +SRC_URI_append_ti33x = " file://0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch"
> +SRC_URI_append_ti43x = " file://0001-Qt-4.x-v2-Changes-for-integrating-with-TI-graphics-S.patch"
>
> QT_CONFIG_FLAGS_append_armv6 = " -no-neon "
>
> --
> 1.7.0.4
>
> _______________________________________________
> meta-arago mailing list
> meta-arago@arago-project.org
> http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago
>
next prev parent reply other threads:[~2013-11-22 15:03 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-22 15:45 [PATCH 1/6] qt4-embedded-gles: Add support for new version of the Graphics SDK Franklin S. Cooper Jr
2013-11-22 15:02 ` Denys Dmytriyenko [this message]
2013-11-22 15:13 ` Cooper Jr., Franklin
2013-11-22 18:51 ` Denys Dmytriyenko
2013-11-22 19:00 ` Cooper Jr., Franklin
2013-11-22 15:45 ` [PATCH 2/6] arago-prefs.inc Use version 05.00.00.01 of the Graphics SDK for am335 and am43x Franklin S. Cooper Jr
2013-11-22 15:45 ` [PATCH 3/6] branding-core: Dont remove SGX from MACHINE_FEATURES Franklin S. Cooper Jr
2013-11-22 15:45 ` [PATCH 4/6] Revert "packagegroup-arago-tisdk-amsdk.bb, mount-sdcard: Remove mount-sdcard" Franklin S. Cooper Jr
2013-11-22 15:45 ` [PATCH 5/6] mount-sdcard: Update to use new udev entry Franklin S. Cooper Jr
2013-11-22 20:00 ` Tom Rini
2013-11-22 22:27 ` Cooper Jr., Franklin
2013-11-23 2:15 ` Tom Rini
2013-12-02 21:31 ` Denys Dmytriyenko
2013-12-02 23:23 ` Cooper Jr., Franklin
2013-12-03 0:20 ` Tom Rini
2013-12-03 1:20 ` Cooper Jr., Franklin
2013-12-03 12:43 ` Tom Rini
2013-11-22 15:45 ` [PATCH 6/6] packagegroup-arago-tisdk-amsdk-sdk-host: Don't bother packaging blank uEnv.txt Franklin S. Cooper Jr
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131122150236.GF32354@denix.org \
--to=denis@denix.org \
--cc=fcooper@ti.com \
--cc=meta-arago@arago-project.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.