[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] wind_xget()



Hello,

 Good, I just checked in the changes, WF_FIRSTAREAXYWH should not be
implemented in XaAES.

Gemlib is updated too... as well as my little test proggy
http://arnaud.bercegeay.free.fr/gemlib/tstxget2.tgz

The missing piece is a way to detect the availability of this function. I propose appl_getinfo(AES_WINDOW(=11)). bit 9-15 of out1 seems to be unused
at the moment, so bit 9 may be used to indicate that WF_FIRSTAREAXYWH is
implemented.

 Okie, sounds find by me. Should we do so?




About identification of AES, if i sum-up, we have:

#define APGI_VERSION 96
appl_getinfo(APGI_VERSION, &min_version, &maj_version, &arch, &status)

and for APGI_AESINFO (value = 0x5800 ???), we can think of an alternate
version of appl_getinfo()... something like:

Yes, value of APGI_AESINFO should be agreed on.. suggestions?


appl_getinfo_str( short mode, char *str1, char *str2, char *str3, char
*str4);
which set
aes_addrin[0] = str1;
aes_addrin[1] = str2;
aes_addrin[2] = str3;
aes_addrin[3] = str4;
and aes_control[2]=1 (intead of 5) to tell that nothing is expected in
intout[1..4].

 Ok, as a way to detect which aes we can use intout[1/2] to contain a 4-
letter ID, like 'MyAES' or 'XaAES' in addition to the above definition.

'MyAES' : 5 letters
'XaAES' : 5 letters too ;)

that don't fit in a long (32 bits) integer.

If we need an AES_ID, we could add this to appl_getinfo_str():

char aes_name[64], aes_version[64], aes_id[8];
appl_getinfo_str( APGI_VERSION, aes_name, aes_version, aes_id, NULL);

BTW, i'm not sure we need to detect if the AES running is xaaes or myaes. If the application want to use a modern feature, then the application just have to check if the feature is available by calling the corresponding appl_getinfo() mode.

the name of the AES is only usefull if the application want to display it... and for that purpose a simple string is the best choice.

So the AES shall check the number of entries for addrin and intout in
aes_control[] to check which appl_getinfo is called. We even can go
further and use the same mode (APGI_VERSION) for both:

short min_version, maj_version, arch, status;
char aes_name[64], aes_version[64];

appl_getinfo(APGI_VERSION, &min_version, &maj_version, &arch, &status)
appl_getinfo_str( APGI_VERSION, aes_name, aes_version, NULL, NULL);

 Yes, that sounds excellent to me :-)


where
aes_name will be filled in with "OurAES"
aes_version will be filled in with "1.02b (25 dec 2004)"

opinions ?

 I like it. With the addition of AES ID (which is a fixed-lenght AES ID)
in intout[1/2] for
appl_getinfo(APGI_VERSION, aes_name, aes_version, NULL, NULL);
I really like this idea :)

What about aes_id (length fixed to 8 chars) in the 4th parameter of appl_getinfo_str() ?

best regards,
Arnaud.