Re: R300 with xorg-x11-6.8.0

2004-11-10 Thread Nicolai Haehnle
On Wednesday 10 November 2004 08:10, eGore wrote:
> Hi list,
> 
> I ran into some trouble getting DRI running with r300 (I have no idea if
> it is already supported or not), but it didn't work. I looked at xorg's
> logfile and found out that DRI was disabled and I also found out that
> this is caused by radeon_accelfuncs.c. So I "wrote" the attached patch
> to get around that. DRI does still not work, but at least my xorg log
> tells me it does :-)
> 
> !! WARNING !!
> I have no idea what I'm doing, so this might be completely wrong :-)
> !! WARNING !!

You're confusing things. On the one hand, there's general support for DRI 
(and support for client side 3D acceleration), and on the other hand 
there's hardware acceleration for the Render extension. The two things are 
only loosely connected.
The R300 efforts are directed towards creating client side 3D acceleration 
(Render acceleration is a very specialised and limited subset of what the 
3D driver does), so your patch is both unnecessary and wrong, because both 
the R100 and the R200 Render acceleration paths cannot possibly work on an 
R300.

Client side 3D acceleration "works" without Render acceleration, where 
"works" means that Clear() operations are accelerated, and I have some code 
for hardware rasterization of untextured primitives which always locks up 
and which I haven't found the time to fix yet.

cu,
Nicolai

> PS: The webpage of r300 is missing a tutorial ;)
> PPS: Patch has been applied for a already patched file, I guess, so line
> numbers might be completely wrong.
> PPPS: I used xorg-x11-6.8.1 from gentoo Linux (xorg-x11-6.8.0-r1 to be
> exact)
> S: I'm having a Radon 9700 Pro from ELSA.
> 
> That's it for now, regards,
>   Christoph Brill aka egore


pgpsG36UP5Lfs.pgp
Description: PGP signature


R300 with xorg-x11-6.8.0

2004-11-09 Thread eGore
Hi list,

I ran into some trouble getting DRI running with r300 (I have no idea if
it is already supported or not), but it didn't work. I looked at xorg's
logfile and found out that DRI was disabled and I also found out that
this is caused by radeon_accelfuncs.c. So I "wrote" the attached patch
to get around that. DRI does still not work, but at least my xorg log
tells me it does :-)

!! WARNING !!
I have no idea what I'm doing, so this might be completely wrong :-)
!! WARNING !!

PS: The webpage of r300 is missing a tutorial ;)
PPS: Patch has been applied for a already patched file, I guess, so line
numbers might be completely wrong.
PPPS: I used xorg-x11-6.8.1 from gentoo Linux (xorg-x11-6.8.0-r1 to be
exact)
S: I'm having a Radon 9700 Pro from ELSA.

That's it for now, regards,
  Christoph Brill aka egore
--- radeon_accelfuncs.c.orig	2004-11-09 21:41:48.377249288 +0100
+++ radeon_accelfuncs.c	2004-11-09 21:43:18.461554392 +0100
@@ -1406,13 +1406,14 @@
 	a->CPUToScreenTextureFormats = RADEONTextureFormats;
 	a->CPUToScreenTextureDstFormats = RADEONDstFormats;
 
-	if (IS_R300_VARIANT) {
+	/*if (IS_R300_VARIANT) {
 	xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Render acceleration "
 		   "unsupported on Radeon 9500/9700 and newer.\n");
-	} else if ((info->ChipFamily == CHIP_FAMILY_RV250) || 
+	} else*/ if ((info->ChipFamily == CHIP_FAMILY_RV250) || 
 		   (info->ChipFamily == CHIP_FAMILY_RV280) || 
 		   (info->ChipFamily == CHIP_FAMILY_RS300) || 
-		   (info->ChipFamily == CHIP_FAMILY_R200)) {
+		   (info->ChipFamily == CHIP_FAMILY_R200) ||
+		   (info->ChipFamily == CHIP_FAMILY_R300)) {
 	a->SetupForCPUToScreenAlphaTexture2 =
 		FUNC_NAME(R200SetupForCPUToScreenAlphaTexture);
 	a->SubsequentCPUToScreenAlphaTexture =