[wined3d] drawprint tidyup initilization of strided data.

Dimi Paun dimi at lattica.com
Fri Jul 22 12:38:15 CDT 2005


From: "Oliver Stieber" <oliver_stieber at yahoo.co.uk>
> Well, when the #if 0's are removed the whole lot should fit on a screen so
you can see the macro
> and it's usage quite clearly and it no longer looks like magic.

No, the _usage_ will always look like magic. It will magically use and
modify
var from the local context. No other C construct does that.

This is (one of) the problem with macros. It's best if their usage is not
very different then a regular C construct. Principle of least surprise and
all that.

> > Also, accessing the magic strided, data, element, stride
> > directly is very weird, and problematic. The casual user
> > wouldn't know what hit him :)
>
> It's less problematic since if forces the code into a strict layout, why
have extra paramiters
> when there going to be identical? Every opportunity for a typo is an
opportunity for a bug, less
> code less bugs, especially when it's being changed by the 'casual user'

Because it makes is clear what is going on there.

-- 
Dimi Paun <dimi at lattica.com>
Lattica, Inc.




More information about the wine-devel mailing list