Andreas Stenglein wrote:
Am 2003.06.10 12:12:56 +0200 schrieb(en) Keith Whitwell:

Keith Whitwell wrote:

Andreas Stenglein wrote:

@keithw: here is another version.

yuvrect.c seems to work
texrect.c still doesnt work

any hints?



OK, the final piece of the puzzle fell into place. Without the radeon docs you might hav had trouble find this -- basically, the radeon still expects texture rectangle texcoords to be in 0..1 range, rather than 0..width,0..height like the r200.


I haven't got the code running for this yet, but modifying the app to supply the texcoords the hardware expects gives a good image.

Keith

yes, its unbelievable... it works with texcoords 0...1 ;)

1) Do you have an idea how to make it work with the right texcoords?

I was thinking that this would be a fairly easy option:


a) Disable TCL for all rectangular texture operations
b) Insert a new stage to the swtcl pipeline, based on Mesa/src/tnl/t_vb_texmat.c, to perform a 1/w, 1/h scale to all texrect coordinates.


I can send you some unfinished code for this, if you want.

2) Since the default bordermode GL_REPEAT doesnt work/isnt allowed
with npot textures, should there something be done about that?

Probably...


3) in radeon_ioctl.c, function radeonEmitVbufPrim()
the first cmd is cleared before filled with the cmd_type:
   cmd[0].i = 0;
   cmd[0].header.cmd_type = RADEON_CMD_PACKET3_CLIP;
  ....
should this be done in radeonEmitBlit() also or
is that not necessary?

Quite possibly it should.



4) I missed a line in radeon_context.c: driCalculateMaxTextureLevels( rmesa->texture_heaps, rmesa->nr_heaps, & ctx->Const, 4, 11, /* max 2D texture size is 2048x2048 */ 0, /* 3D textures unsupported. */ 0, /* cube textures unsupported. */ ===> 11, /* max texture rectangle size is 2048x2048 */ 12, GL_FALSE );


Looks good, too.


Keith




------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The best thread debugger on the planet. Designed with thread debugging features you've never dreamed of, try TotalView 6 free at www.etnus.com. _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to