Commit Graph

11347 Commits

Author SHA1 Message Date
Kristian Høgsberg 594006d8b2 Remove now unused getProcAddress from DRIinterfaceMethods. 2007-10-11 11:25:37 -04:00
Kristian Høgsberg f968f67e62 Add a DRI_ReadDrawable marker extension to signal read drawable capability. 2007-10-11 11:22:55 -04:00
Kristian Høgsberg 106a6f29bb Move media stream counter entry points to new extension. 2007-10-11 11:21:29 -04:00
Kristian Høgsberg a7a0a2beb5 Move GLX_MESA_swap_frame_usage DRI entry points to the new mechanism. 2007-10-11 11:11:12 -04:00
Kristian Høgsberg 78a6aa57a0 Move GLX_MESA_allocate_memory related functions to new extension mechanism. 2007-10-11 11:09:57 -04:00
Kristian Høgsberg efaf90b03e Move swap_interval to new extension mechanism. 2007-10-10 19:14:10 -04:00
Kristian Høgsberg ac3e838fa7 Move the copySubBuffer extension over to the new mechanism. 2007-10-10 18:57:57 -04:00
Kristian Høgsberg f616a263a2 Implement new screen extension API.
This new API lets the loader examine DRI level extensions provided by the
driver in a forward compatible manner.

Much of the churn in the DRI interface is adding support for new
extensions or removing old, unused extensions.  This new extension
mechanism lets the loader query the extensions provided by the driver
and implement the extensions it knows about.  Deprecating extensions
is done by not exporting that extension in the list, which doesn't
require keeping old function pointers around to preserve ABI.
2007-10-10 18:47:22 -04:00
Kristian Høgsberg 295dc2d225 Stop passing in unused fbconfigs to createNewScreen. 2007-10-10 18:46:51 -04:00
Kristian Høgsberg 64106d0d9a Pull createNewScreen entry point into dri_util.c.
This pulls the top level createNewScreen entry point out of the drivers
and rewrites __driUtilCreateNewScreen in dri_util.c to be the new entry point.

The change moves more logic into the common/ layer and changes the
createNewScreen entry point to only be defined in one place.
2007-10-10 18:36:14 -04:00
Kristian Høgsberg efd03a278a Replace open-coded major, minor, and patch version fields with __DRIversionRec. 2007-10-10 18:20:08 -04:00
Kristian Høgsberg 5987a03f99 Convert all DRI entrypoints to take pointers to __DRI* types.
The entrypoints take a mix of __DRIscreen * and void * (screen private)
arguments (similarly for contexts and drawables).  This patch does away
with passing the private void pointer and always only passes the fully
typed __DRIscreen pointer and always as the first argument.

This makes the interface more consistent and increases type safety, and
catches a bug where we would pass a screen private to DRIdrawable::getSBC.
2007-10-10 18:00:18 -04:00
Kristian Høgsberg aac367f48a Remove screenConfigs from __DRIscreen.
The screenConfigs field of __DRIscreen points back to the containing
__GLXscreenConfigs struct.  This is a serious abstraction violation; it
assumes that the loader is libGL and that there *is* a __GLXscreenConfigs
type in the loader.

Using the containerOf macro, we can get from the __DRIscreen pointer to
the containing __GLXscreenConfigs struct, at a place in the stack
where the above is a valid assumption.  Besides, the __DRI* structs shouldn't
hold state other than the private pointer.
2007-10-10 18:00:13 -04:00
Kristian Høgsberg fa72013ada Drop mostly unused __DRIid typedef. 2007-10-10 17:09:48 -04:00
Kristian Høgsberg 9590ba97ad Avoid deadlock in GarbageCollectDRIDrawables.
__glXinitialize() can't be called with the GLX lock held.  Just
pass in the __GLXscreenConfigs pointer so we don't have to look it
up in __GLXdisplayPrivate.
2007-10-10 17:09:36 -04:00
Kristian Høgsberg 8ed5c7ca05 Drop createContext and destroyContext from DRIinterfaceMethods.
As for createDrawable and destroyDrawable, these functions immediately
upon entry to driCreateNewContext and immediately before exit from
driDestroyContext.  Instead of passing function pointers back and forth
just obtain the drm_context_t prior to calling DRIscreen::createNewContext
and pass it as a parameter.

This change also lets us keep the DRI context XID in the libGL loader only.
2007-10-10 17:09:16 -04:00
Kristian Høgsberg 4ff95e78e1 Drop createDrawable and destroyDrawable fron DRIinterfaceMethods.
All the DRI driver did was call the createDrawable callback immediately
upon entry to DRIscreen::createNewDrawable to get the drm_drawable_t.
We can just call that before calling into the DRI driver and pass the
returned drm_drawable_t as an argument to the DRI entry point.

Likewise for destroyDrawable.

Also, DRIdrawablePrivate::draw isn't used anywhere, and since the
driver no longer needs the XID of the drawable we can now drop that.
2007-10-10 17:07:26 -04:00
Kristian Høgsberg b068af2f3b Key drm_i915_flip_t typedef off of the ioctl #define instead. 2007-10-10 17:07:01 -04:00
Kristian Høgsberg aceccda56b Drop __DRInativeDisplay and pass in __DRIscreen pointers instead.
Many DRI entry points took a __DRInativeDisplay pointer and a screen
index as arguments.  The only use for the native display pointer was to
pass it back to the loader when looking up the __DRIscreen for the given
screen index.

Instead, let's just pass in the __DRIscreen pointer directly, which
let's drop the __DRInativeDisplay type and the getScreen function.

The assumption is now that the loader will be able to retrieve context
from the __DRIscreen pointer when necessary.
2007-10-10 15:32:15 -04:00
Kristian Høgsberg b42152061c Add macros to generate CreateNewScreen entrypoint. 2007-10-05 00:12:30 -04:00
Kristian Høgsberg 4a22ae8d44 Remove XIDs from DRI interface (see #5714). 2007-10-05 00:09:32 -04:00
Kristian Høgsberg 4ceefccbfa Pull in the drm hash. 2007-10-05 00:09:23 -04:00
Eric Anholt 77e0523fb7 [965] Replace various alignment code with a shared ALIGN() macro.
In the process, fix some alignment issues:
- Scratch space allocation was aligned into units of 1KB, while the allocation
  wanted units of bytes, so we never allocated enough space for scratch.
- GRF register count was programmed as ALIGN(val - 1, 16) / 16 instead of
  ALIGN(val, 16) / 16 - 1, which overcounted for val != 16n+1.
2007-10-04 12:28:49 -07:00
Eric Anholt 0fc9efd8f0 Replace bmBufferOffset usage in batchbuffer setup with OUT_RELOC.
This is in preparation for 965 TTM.
2007-10-04 12:28:49 -07:00
Eric Anholt 6bac9478c3 Replace duplicated intel_reg.h with a shared header. 2007-10-04 12:28:49 -07:00
Eric Anholt 1f7378ee46 Replace some structure-based batch preparation with plain OUT_BATCH.
OUT_BATCH is far more amenable to the upcoming relocations being done for TTM
support.
2007-10-04 12:28:48 -07:00
Eric Anholt ffa94e5b1e FreeBSD: more /usr/X11R6->/usr/local 2007-10-04 12:28:48 -07:00
Maarten Maathuis 10cc229dc2 nouveau: Replace removed device classes with their proper labels. 2007-10-04 19:08:37 +02:00
Roland Scheidegger db0f050582 minor fog calc cleanup 2007-10-03 22:20:44 +02:00
Michel Dänzer 58cdd1dc52 i915: Only align texture pitch to 64 bytes when textures can be render targets. 2007-10-03 11:25:59 +02:00
Michel Dänzer 1bc84102ad i915: Work around texture pitch related performance drops on i915 at least. 2007-10-03 11:06:48 +02:00
Brian de1d725f44 updated glext.h license info (Khronos), plus other clean-ups 2007-10-01 17:57:25 -06:00
Brian f8ee72d98f fix VBO-split infinite loop (bug 12164) 2007-09-29 12:01:34 -06:00
Chris Rankin 4f96000e29 r200: Implement SetTexOffset hook.
Implementation guidance by Michel Dänzer, final testing by Timo Aaltonen.
2007-09-29 18:14:06 +02:00
Dan Nicholson 2a3e33865d add support for LDFLAGS env var 2007-09-28 18:42:21 -06:00
Brian e776e7a95a update the DRM/DRI instructions 2007-09-28 18:39:41 -06:00
Brian 6775c1e8cc Remove test for EXT_blend_logic_op in glGetString when determining GL version.
EXT_blend_logic_op is slightly different from GL 1.1's RGBA logicop mode
and does not have to be supported.  Per conversation with Roland.
2007-09-28 16:06:43 -06:00
Jesse Barnes d99f6c4a2a Go back to using old drm_i915_flip_t field name
This field shouldn't have been renamed in the first place.  Go back to using
the old name so that the tree is backward and forward compatible again.
2007-09-28 10:11:52 -07:00
Eric Anholt 35331a511f [965] Add batchbuffer dumping under INTEL_DEBUG=bat, like 915. 2007-09-27 15:11:47 -07:00
Eric Anholt b2c8b1385a FreeBSD: Chase /usr/X11R6 death (replaced by everything in one prefix). 2007-09-27 15:11:45 -07:00
Eric Anholt e886ae4c58 Revert "WIP 965 conversion to dri_bufmgr."
This reverts commit b2f1aa2389.

Somehow I ended up with my branch's save-this-while-I-work-on-master commit
actually on master.
2007-09-27 15:11:39 -07:00
Eric Anholt b2f1aa2389 WIP 965 conversion to dri_bufmgr. 2007-09-27 11:15:51 -07:00
Eric Anholt 38c30a8184 [965] Remove AUB file support.
This code existed to dump logs of hardware access to be replayed in simulation.
Since we have real hardware now, it's not really needed.
2007-09-27 10:16:08 -07:00
Brian f2d9a07efe for Miniglx, use git sources 2007-09-27 10:39:01 -06:00
Brian ed6d5ff6f8 Restore old _TriangleCaps code to fix Blender problem (bug 12164) 2007-09-27 10:39:01 -06:00
Brian 4f9d29cd4e tweak point rast to fix conform failure 2007-09-27 10:39:01 -06:00
Xiang, Haihao 3ee6a77e97 i965: handle all unfilled mode in clip stage. fix bug #12453 2007-09-27 16:14:57 +08:00
Xiang, Haihao 6254be9b71 mesa: make sure the gotten value isn't greater than the
max depth buffer value on 64bit system. fix bug #12095
2007-09-27 15:52:01 +08:00
Zou Nan hai aa88d11e7d fix ppracer and bzflag issue with clip optimization 2007-09-27 13:49:35 +08:00
Dave Airlie 67f6449743 i915/i965 merge serer directories along lines for radeon/r200 2007-09-27 11:15:42 +10:00