[Ffmpeg-cvslog] r7461 - trunk/libavutil/aes.c
michael
subversion
Sun Jan 14 10:14:05 CET 2007
Author: michael
Date: Sun Jan 14 10:14:05 2007
New Revision: 7461
Modified:
trunk/libavutil/aes.c
Log:
simplify sbox init
Modified: trunk/libavutil/aes.c
==============================================================================
--- trunk/libavutil/aes.c (original)
+++ trunk/libavutil/aes.c Sun Jan 14 10:14:05 2007
@@ -123,9 +123,8 @@
log8[0]= 255;
for(i=0; i<256; i++){
j= i ? alog8[255-log8[i]] : 0;
- j ^= (j<<1) ^ (j<<2) ^ (j<<3) ^ (j<<4)
- ^(j>>7) ^ (j>>6) ^ (j>>5) ^ (j>>4) ^ 99;
- j&=255;
+ j ^= (j<<1) ^ (j<<2) ^ (j<<3) ^ (j<<4);
+ j = (j ^ (j>>8) ^ 99) & 255;
inv_sbox[j]= i;
sbox [i]= j;
// av_log(NULL, AV_LOG_ERROR, "%d, ", log8[i]);
More information about the ffmpeg-cvslog
mailing list