summaryrefslogtreecommitdiffstats
path: root/src/gallium/include/pipe/p_screen.h
Commit message (Collapse)AuthorAgeFilesLines
* gallium/util: add u_transfer_helperRob Clark2017-12-151-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | Add a new helper that drivers can use to emulate various things that need special handling in particular in transfer_map: 1) z32_s8x24.. gl/gallium treats this as a single buffer with depth and stencil interleaved but hardware frequently treats this as separate z32 and s8 buffers. Special pack/unpack handling is needed in transfer_map/unmap to pack/unpack the exposed buffer 2) fake RGTC.. GPUs designed with GLES in mind, but which can other- wise do GL3, if native RGTC is not supported it can be emulated by converting to uncompressed internally, but needs pack/unpack in transfer_map/unmap 3) MSAA resolves in the transfer_map() case v2: add MSAA resolve based on Eric's "gallium: Add helpers for MSAA resolves in pipe_transfer_map()/unmap()." patch; avoid wrapping pipe_resource, to make it possible for drivers to use both this and threaded_context. Signed-off-by: Rob Clark <[email protected]>
* gallium: add pipe_screen::check_resource_capabilityMarek Olšák2017-10-121-0/+17
| | | | | | | | | This is optional (and no CAP). Implemented by radeonsi, ddebug, rbug, trace. Reviewed-by: Daniel Stone <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium: introduce device/driver UUID queriesAndres Rodriguez2017-08-061-0/+13
| | | | | | | | | | v2: remove unnecessary returns v3 (Timothy Arceri): updated trace v4 (Timothy Arceri): actually dump the params in trace Signed-off-by: Andres Rodriguez <[email protected]> Reviewed-by: Marek Olšák <[email protected]> (v2) Reviewed-by: Samuel Pitoiset <[email protected]>
* gallium: introduce memory objectDave Airlie2017-08-061-0/+36
| | | | | | | | | | v2: fix comment regarding fd ownership, define pipe_memory_object v3: remove stray return v4 (Timothy Arceri): update trace v5 (Timothy Arceri): actually dump the params in trace Reviewed-by: Marek Olšák <[email protected]> (v3) Reviewed-by: Samuel Pitoiset <[email protected]>
* gallium: get rid of pipe_screen_config::flagsNicolai Hähnle2017-08-041-1/+0
| | | | | | | | | | | They were set only by the DRI state tracker, which is problematic when radeonsi is used with different state trackers in the same process. Also, we don't need them anymore. Tested-by: Dieter Nützel <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: add driconf options to pipe_screen_configNicolai Hähnle2017-08-021-0/+2
| | | | Reviewed-by: Marek Olšák <[email protected]>
* gallium: add pipe_screen_config to screen_create functionsNicolai Hähnle2017-08-021-0/+8
| | | | | | | This allows a more generic mechanism for passing user configurations into drivers by accessing the dri options directly. Reviewed-by: Marek Olšák <[email protected]>
* gallium: introduce format modifier queryingVarad Gautam2017-06-091-0/+14
| | | | | | | | | | | | | | | | | format modifiers tokens are driver specific, and hence, need to come in from the driver. this allows drivers to be queried for supported format modifiers for EGL_EXT_image_dma_buf_import_modifiers. v2: rebase to master. v3: drivers must return false on query failure. v4: use pscreen->is_format_supported instead of adding a separate format query handle, remove PIPE_CAP_QUERY_DMABUF_ATTRIBS. (Lucas Stach) v5: add external_only parameter. Signed-off-by: Varad Gautam <[email protected]> Cc: Lucas Stach <[email protected]> Reviewed-by: Lucas Stach <[email protected]>
* st/dri: implement createImageWithModifiers in DRIimageVarad Gautam2017-06-091-0/+15
| | | | | | | | | | | | | | | adds a pscreen->resource_create_with_modifiers() to create textures with modifier. v2: - stylefixes (Emil Velikov) - don't return selected modifier from resource_create_with_modifiers. we can use the winsys_handle to get this. Signed-off-by: Varad Gautam <[email protected]> Reviewed-by: Lucas Stach <[email protected]> (v1) Cc: Lucas Stach <[email protected]> Reviewed-by: Lucas Stach <[email protected]>
* gallium: s/unsigned/enum pipe_shader_type/ for get_compiler_options()Brian Paul2017-03-081-1/+1
| | | | Reviewed-by: Edward O'Callaghan <[email protected]>
* gallium: s/unsigned/enum pipe_shader_type/ for pipe_screen::get_shader_param()Brian Paul2017-03-081-1/+2
| | | | Reviewed-by: Edward O'Callaghan <[email protected]>
* gallium: add get_disk_shader_cache() callbackTimothy Arceri2017-02-231-0/+9
| | | | | | | V2: Provide more detail in callback description and add description to screen.rst Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium: add pipe_screen::resource_changedPhilipp Zabel2017-01-201-0/+8
| | | | | | | | | | Add a hook to tell drivers that an imported resource may have changed and they need to update their internal derived resources. Signed-off-by: Philipp Zabel <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Lucas Stach <[email protected]>
* gallium: support for native fence fd'sRob Clark2016-12-011-0/+10
| | | | | | | This enables gallium support for EGL_ANDROID_native_fence_sync, for drivers which support PIPE_CAP_NATIVE_FENCE_FD. Signed-off-by: Rob Clark <[email protected]>
* gallium: add a pipe_context parameter to resource_get_handleMarek Olšák2016-08-251-0/+7
| | | | | | | | radeonsi needs to do some operations (DCC decompression) for OpenGL-OpenCL interop and this is the only way to make it coherent with the current context. It can optionally be set to NULL. Reviewed-by: Brian Paul <[email protected]>
* gallium: add a pipe_context parameter to fence_finishMarek Olšák2016-08-101-3/+12
| | | | | | | | required by glClientWaitSync (GL 4.5 Core spec) that can optionally flush the context Reviewed-by: Rob Clark <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium: add NIR as a possible IRRob Clark2016-05-111-0/+9
| | | | | | Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: distinguish between shader IR in get_compute_paramBas Nieuwenhuizen2016-04-021-5/+8
| | | | | | | | | | | | | For radeonsi, native and TGSI use different compilers and this results in different limits for different IR's. The set we strictly need for radeonsi is only the MAX_BLOCK_SIZE and MAX_THREADS_PER_BLOCK params, but I added a few others as shader related that seemed like they would also typically depend on the compiler. Signed-off-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* gallium: add external usage flags to resource_from(get)_handle (v2)Marek Olšák2016-03-091-2/+8
| | | | | | | | | This will allow drivers to make better decisions about texture sharing for DRI2, DRI3, Wayland, and OpenCL. v2: add read/write flags, take advantage of __DRI_IMAGE_USE_BACKBUFFER Reviewed-by: Axel Davy <[email protected]>
* gallium: add interface for querying memory usage and sizes (v2)Marek Olšák2016-02-051-0/+6
| | | | | | | | | | If you're worried about the duplication of some CAPs, we can remove them later. v2: add fields for memory eviction stats Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* gallium/swrast: fix front buffer blitting. (v2)Dave Airlie2015-10-311-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So I've known this was broken before, cogl has a workaround for it from what I know, but with the gallium based swrast drivers BlitFramebuffer from back to front or vice-versa was pretty broken. The legacy swrast driver tracks when a front buffer is used and does the get/put images when it is mapped/unmapped, so this patch attempts to add the same functionality to the gallium drivers. It creates a new context interface to denote when a front buffer is being created, and passes a private pointer to it, this pointer is then used to decide on map/unmap if the contents should be updated from the real frontbuffer using get/put image. This is primarily to make gtk's gl code work, the only thing I've tested so far is the glarea test from https://github.com/ebassi/glarea-example.git v2: bump extension version, check extension version before calling get image. (Ian) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91930 Cc: <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* gallium/docs: clairify dmabuf fd ownershipRob Clark2015-09-091-0/+8
| | | | | | | Since debugging issues w/ fd's close()d at the wrong time can be quite fun, this should probably be made more explicit in the docs. Signed-off-by: Rob Clark <[email protected]>
* gallium: add flags parameter to pipe_screen::context_createMarek Olšák2015-08-261-2/+9
| | | | | | | | This allows creating compute-only and debug contexts. Reviewed-by: Brian Paul <[email protected]> Acked-by: Christian König <[email protected]> Acked-by: Alex Deucher <[email protected]>
* gallium: remove redundant pipe_context::fence_signalledMarek Olšák2015-07-051-6/+0
| | | | | | fence_finish(timeout=0) does the same thing Reviewed-by: Brian Paul <[email protected]>
* gallium: add pipe_screen::get_driver_query_group_infoSamuel Pitoiset2015-05-061-0/+11
| | | | | | | | | | | | | | Driver queries are organized as a single hierarchy where queries are categorized into groups. Each group has a list of queries and a maximum number of queries that can be sampled. The list of available groups can be obtained using pipe_screen::get_driver_query_group_info. This will be used by GL_AMD_performance monitor. v2: add group type (CPU/GPU) Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Martin Peres <[email protected]>
* gallium: introduce get_device_vendor() entrypoint for pipesGiuseppe Bilotta2015-03-231-0/+8
| | | | | | | | | This will be needed by Clover to return the correct information to CL_DEVICE_VENDOR info queries. Signed-off-by: Giuseppe Bilotta <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* gallium: remove trailing whitespace in p_screen.hGiuseppe Bilotta2015-03-231-1/+1
| | | | | | Signed-off-by: Giuseppe Bilotta <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* gallium: add interface and state tracker support for GL_AMD_pinned_memoryMarek Olšák2015-02-171-0/+8
| | | | | | v2: add alignment restrictions to docs, fix indentation in headers Reviewed-by: Christian König <[email protected]>
* s/Tungsten Graphics/VMware/José Fonseca2014-01-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/[email protected]/[email protected]/ s/[email protected]/[email protected]/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\[email protected]/[email protected]/g s/keithw\[email protected]/[email protected]/g s/[email protected]/[email protected]/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/[email protected]/[email protected]/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <[email protected]>
* swrast* (gallium, classic): add MESA_copy_sub_buffer support (v3)Dave Airlie2013-12-131-3/+4
| | | | | | | | | | | | | | | | | | | | | | | This patches add MESA_copy_sub_buffer support to the dri sw loader and then to gallium state tracker, llvmpipe, softpipe and other bits. It reuses the dri1 driver extension interface, and it updates the swrast loader interface for a new putimage which can take a stride. I've tested this with gnome-shell with a cogl hacked to reenable sub copies for llvmpipe and the one piglit test. I could probably split this patch up as well. v2: pass a pipe_box, to reduce the entrypoints, as per Jose's review, add to p_screen doc comments. v3: finish off winsys interfaces, add swrast classic support as well. Reviewed-by: Jose Fonseca <[email protected]> Signed-off-by: Dave Airlie <[email protected]> swrast: add support for copy_sub_buffer
* vl: add entrypoint to is_video_format_supportedChristian König2013-08-191-1/+2
| | | | Signed-off-by: Christian König <[email protected]>
* vl: add entrypoint to get_video_paramChristian König2013-08-191-0/+1
| | | | Signed-off-by: Christian König <[email protected]>
* gallium: add interface for driver queries like performance counters, etc.Marek Olšák2013-03-261-0/+11
| | | | | | | The pipe query interface is reused. The list of available queries can be obtained using pipe_screen::get_driver_query_info. Reviewed-by: Brian Paul <[email protected]>
* gallium: mention PIPE_TIMEOUT_INFINITE in the fence_finish() commentBrian Paul2012-09-201-1/+1
|
* gallium: add new pipe_screen::can_create_resource() functionBrian Paul2012-09-171-0/+8
| | | | | | | | | | Used to implement proxy textures. If a gallium driver doesn't implement this function we'll just continue to use the core Mesa fallback code. Without this hook we really have no good way to implement OpenGL proxy textures with gallium drivers. Reviewed-by: Jose Fonseca <[email protected]>
* gallium: add QUERY_TIMESTAMP cap and get_timestamp screen functionMarek Olšák2012-07-101-0/+7
|
* gallium: minor whitespace, comment changesBrian Paul2012-06-271-3/+1
|
* gallium: remove user_buffer_create from the interfaceMarek Olšák2012-05-121-26/+0
| | | | Nothing uses it now.
* gallium: Basic compute interface.Francisco Jerez2012-05-111-0/+12
| | | | | | | | | | Define an interface that exposes the minimal functionality required to implement some of the popular compute APIs. This commit adds entry points to set the grid layout and other state required to keep track of the usual address spaces employed in compute APIs, to bind a compute program, and execute it on the device. Reviewed-by: Marek Olšák <[email protected]>
* gallium: remove unused winsys pointers in pipe_screen and pipe_contextMarek Olšák2012-02-211-3/+0
| | | | A winsys is already a private object of a driver.
* gallium: separate out floating-point CAPs into its own enumMarek Olšák2011-11-221-1/+1
| | | | | | | | | | | | | | | The motivation behind this is to add some self-documentation in the code about how each CAP can be used. The idea is: - enum pipe_cap is only valid in get_param - enum pipe_capf is only valid in get_paramf Which CAPs are floating-point have been determined based on how everybody except svga implemented the functions. svga have been modified to match all the other drivers. Besides that, the floating-point CAPs are now prefixed with PIPE_CAPF_.
* gallium: put video-related enums in separate headerBrian Paul2011-07-141-0/+1
| | | | | | | | | | | The forward references to video enum types in p_context.h causes a massive number of compiler warnings (ISO C forbids forward references to ‘enum’ types). By putting the new video enums in a separate header that can be included by p_context.h and p_screen.h we can avoid this. Acked-by Christian König <[email protected]>
* [g3dvl] revert some unintended white space changesChristian König2011-07-111-9/+12
|
* [g3dvl] and finally remove pipe_video_contextChristian König2011-07-081-3/+0
|
* [g3dvl] remove the unused priv member from pipe_video_contextChristian König2011-07-081-2/+1
|
* [g3dvl] make pipe_context mandatory for creation pipe_video_contextChristian König2011-07-081-1/+3
|
* [g3dvl] rename is_format_supported to is_video_format_supported and move it ↵Christian König2011-07-081-0/+8
| | | | into screen object
* [g3dvl] rename get_param to get_video_param and move into screen objectChristian König2011-07-071-0/+6
|
* [g3dvl] and finally split the decoder part out of the contextChristian König2011-04-061-11/+7
| | | | This should give a good basis to implement vdpau ontop of it.
* Merge remote branch 'origin/master' into pipe-videoChristian König2011-03-191-13/+7
|\ | | | | | | | | | | Conflicts: src/gallium/drivers/r600/r600_asm.c src/gallium/tests/unit/SConscript