00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00027 #include <iostream>
00028 #include "ShOperation.hpp"
00029
00030 namespace SH {
00031
00035 const ShOperationInfo opInfo[] = {
00036 {"ASN", 1, ShOperationInfo::LINEAR, false},
00037
00038 {"NEG", 1, ShOperationInfo::LINEAR, false},
00039 {"ADD", 2, ShOperationInfo::LINEAR, true},
00040 {"MUL", 2, ShOperationInfo::LINEAR, true},
00041 {"DIV", 2, ShOperationInfo::LINEAR, false},
00042
00043 {"SLT", 2, ShOperationInfo::LINEAR, false},
00044 {"SLE", 2, ShOperationInfo::LINEAR, false},
00045 {"SGT", 2, ShOperationInfo::LINEAR, false},
00046 {"SGE", 2, ShOperationInfo::LINEAR, false},
00047 {"SEQ", 2, ShOperationInfo::LINEAR, false},
00048 {"SNE", 2, ShOperationInfo::LINEAR, false},
00049
00050 {"ABS", 1, ShOperationInfo::LINEAR, false},
00051 {"ACOS", 1, ShOperationInfo::LINEAR, false},
00052 {"ASIN", 1, ShOperationInfo::LINEAR, false},
00053 {"ATAN", 1, ShOperationInfo::LINEAR, false},
00054 {"ATAN2", 2, ShOperationInfo::LINEAR, false},
00055
00056 {"CBRT", 1, ShOperationInfo::LINEAR, false},
00057 {"CEIL", 1, ShOperationInfo::LINEAR, false},
00058 {"COS", 1, ShOperationInfo::LINEAR, false},
00059 {"CMUL", 1, ShOperationInfo::ALL, false},
00060 {"CSUM", 1, ShOperationInfo::ALL, false},
00061 {"DOT", 2, ShOperationInfo::ALL, true},
00062 {"DX", 1, ShOperationInfo::EXTERNAL, false},
00063 {"DY", 1, ShOperationInfo::EXTERNAL, false},
00064
00065 {"EXP", 1, ShOperationInfo::LINEAR, false},
00066 {"EXP2", 1, ShOperationInfo::LINEAR, false},
00067 {"EXP10", 1, ShOperationInfo::LINEAR, false},
00068 {"FLR", 1, ShOperationInfo::LINEAR, false},
00069 {"FRAC", 1, ShOperationInfo::LINEAR, false},
00070
00071 {"LOG", 1, ShOperationInfo::LINEAR, false},
00072 {"LOG2", 1, ShOperationInfo::LINEAR, false},
00073 {"LOG10", 1, ShOperationInfo::LINEAR, false},
00074 {"LRP", 3, ShOperationInfo::LINEAR, false},
00075
00076 {"MAD", 3, ShOperationInfo::LINEAR, false},
00077 {"MAX", 2, ShOperationInfo::LINEAR, false},
00078 {"MIN", 2, ShOperationInfo::LINEAR, true},
00079 {"MOD", 2, ShOperationInfo::LINEAR, true},
00080
00081 {"POW", 2, ShOperationInfo::LINEAR, false},
00082 {"RCP", 1, ShOperationInfo::LINEAR, false},
00083 {"RND", 1, ShOperationInfo::LINEAR, false},
00084 {"RSQ", 1, ShOperationInfo::LINEAR, false},
00085
00086 {"SIN", 1, ShOperationInfo::LINEAR, false},
00087 {"SGN", 1, ShOperationInfo::LINEAR, false},
00088 {"SQRT", 1, ShOperationInfo::LINEAR, false},
00089 {"TAN", 1, ShOperationInfo::LINEAR, false},
00090
00091 {"NORM", 1, ShOperationInfo::ALL, false},
00092 {"XPD", 2, ShOperationInfo::ALL, false},
00093
00094 {"TEX", 2, ShOperationInfo::EXTERNAL, false},
00095 {"TEXI", 2, ShOperationInfo::EXTERNAL, false},
00096 {"TEXD", 3, ShOperationInfo::EXTERNAL, false},
00097
00098 {"COND", 3, ShOperationInfo::LINEAR, false},
00099
00100 {"KIL", 1, ShOperationInfo::IGNORE, false},
00101
00102 {"OPTBRA", 1, ShOperationInfo::IGNORE, false},
00103
00104 {"FETCH", 1, ShOperationInfo::EXTERNAL, false},
00105 {"LOOKUP", 2, ShOperationInfo::EXTERNAL, false},
00106
00107 {"PAL", 2, ShOperationInfo::EXTERNAL, false},
00108
00109 {"LO", 1, ShOperationInfo::LINEAR, false},
00110 {"HI", 1, ShOperationInfo::LINEAR, false},
00111 {"SETLO", 1, ShOperationInfo::LINEAR, false},
00112 {"SETHI", 1, ShOperationInfo::LINEAR, false},
00113
00114 {0, 0, ShOperationInfo::IGNORE, false}
00115 };
00116
00117
00118 }
00119