diff options
Diffstat (limited to 'src/emu')
-rw-r--r-- | src/emu/cheat.c | 54 | ||||
-rw-r--r-- | src/emu/cheat.h | 40 | ||||
-rw-r--r-- | src/emu/cpu/dsp56k/inst.h | 8 | ||||
-rw-r--r-- | src/emu/debug/debugcpu.c | 2 | ||||
-rw-r--r-- | src/emu/debug/debugcpu.h | 2 | ||||
-rw-r--r-- | src/emu/debug/debugvw.c | 2 | ||||
-rw-r--r-- | src/emu/debug/express.c | 80 | ||||
-rw-r--r-- | src/emu/debug/express.h | 38 | ||||
-rw-r--r-- | src/emu/render.h | 2 | ||||
-rw-r--r-- | src/emu/rendfont.c | 34 | ||||
-rw-r--r-- | src/emu/rendfont.h | 4 | ||||
-rw-r--r-- | src/emu/sound/asc.c | 36 | ||||
-rw-r--r-- | src/emu/sound/disc_dev.c | 2 | ||||
-rw-r--r-- | src/emu/sound/disc_mth.c | 698 |
14 files changed, 501 insertions, 501 deletions
diff --git a/src/emu/cheat.c b/src/emu/cheat.c index 2ba822089c7..d83d81d076b 100644 --- a/src/emu/cheat.c +++ b/src/emu/cheat.c @@ -173,7 +173,7 @@ cheat_parameter::cheat_parameter(cheat_manager &manager, symbol_table &symbols, m_minval = number_and_format(xml_get_attribute_int(¶mnode, "min", 0), xml_get_attribute_int_format(¶mnode, "min")); m_maxval = number_and_format(xml_get_attribute_int(¶mnode, "max", 0), xml_get_attribute_int_format(¶mnode, "max")); m_stepval = number_and_format(xml_get_attribute_int(¶mnode, "step", 1), xml_get_attribute_int_format(¶mnode, "step")); - + // iterate over items for (xml_data_node *itemnode = xml_get_sibling(paramnode.child, "item"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "item")) { @@ -184,11 +184,11 @@ cheat_parameter::cheat_parameter(cheat_manager &manager, symbol_table &symbols, // check for non-existant value if (xml_get_attribute(itemnode, "value") == NULL) throw emu_fatalerror("%s.xml(%d): item is value\n", filename, itemnode->line); - + // extract the parameters UINT64 value = xml_get_attribute_int(itemnode, "value", 0); int format = xml_get_attribute_int_format(itemnode, "value"); - + // allocate and append a new item item &curitem = m_itemlist.append(*auto_alloc(&manager.machine(), item(itemnode->value, value, format))); @@ -210,7 +210,7 @@ const char *cheat_parameter::text() // are we a value cheat? if (!has_itemlist()) m_curtext.format("%d (0x%X)", UINT32(m_value), UINT32(m_value)); - + // if not, we're an item cheat else { @@ -280,7 +280,7 @@ bool cheat_parameter::set_minimum_state() bool cheat_parameter::set_prev_state() { UINT64 origvalue = m_value; - + // are we a value cheat? if (!has_itemlist()) { @@ -289,7 +289,7 @@ bool cheat_parameter::set_prev_state() else m_value -= m_stepval; } - + // if not, we're an item cheat else { @@ -300,7 +300,7 @@ bool cheat_parameter::set_prev_state() if (previtem != NULL) m_value = previtem->value(); } - + return (m_value != origvalue); } @@ -312,7 +312,7 @@ bool cheat_parameter::set_prev_state() bool cheat_parameter::set_next_state() { UINT64 origvalue = m_value; - + // are we a value cheat? if (!has_itemlist()) { @@ -321,7 +321,7 @@ bool cheat_parameter::set_next_state() else m_value += m_stepval; } - + // if not, we're an item cheat else { @@ -332,7 +332,7 @@ bool cheat_parameter::set_next_state() if (curitem != NULL && curitem->next() != NULL) m_value = curitem->next()->value(); } - + return (m_value != origvalue); } @@ -477,7 +477,7 @@ cheat_script::script_entry::script_entry(cheat_manager &manager, symbol_table &s for (xml_data_node *argnode = xml_get_sibling(entrynode.child, "argument"); argnode != NULL; argnode = xml_get_sibling(argnode->next, "argument")) { output_argument &curarg = m_arglist.append(*auto_alloc(&manager.machine(), output_argument(manager, symbols, filename, *argnode))); - + // verify we didn't overrun the argument count totalargs += curarg.count(); if (totalargs > MAX_ARGUMENTS) @@ -887,7 +887,7 @@ bool cheat_entry::activate() //------------------------------------------------- -// select_default_state - select the default +// select_default_state - select the default // state for a cheat, or activate a oneshot cheat //------------------------------------------------- @@ -908,7 +908,7 @@ bool cheat_entry::select_default_state() //------------------------------------------------- -// select_previous_state - select the previous +// select_previous_state - select the previous // state for a cheat //------------------------------------------------- @@ -947,7 +947,7 @@ bool cheat_entry::select_previous_state() //------------------------------------------------- -// select_next_state - select the next state for +// select_next_state - select the next state for // a cheat //------------------------------------------------- @@ -972,11 +972,11 @@ bool cheat_entry::select_next_state() changed = set_state(SCRIPT_STATE_RUN); m_parameter->set_minimum_state(); } - + // otherwise, switch to the next state else changed = m_parameter->set_next_state(); - + // if we changed, signal a state change if (changed && !is_oneshot_parameter()) execute_change_script(); @@ -986,7 +986,7 @@ bool cheat_entry::select_next_state() //------------------------------------------------- -// menu_text - return the text needed to display +// menu_text - return the text needed to display // this cheat in a menu item //------------------------------------------------- @@ -1118,7 +1118,7 @@ cheat_manager::cheat_manager(running_machine &machine) //------------------------------------------------- -// set_enable - globally enable or disable the +// set_enable - globally enable or disable the // cheat engine //------------------------------------------------- @@ -1165,7 +1165,7 @@ void cheat_manager::reload() // free everything m_cheatlist.reset(); - + // reset state m_framecount = 0; m_numlines = 0; @@ -1213,7 +1213,7 @@ bool cheat_manager::save_all(const char *filename) // if that failed, return nothing if (filerr != FILERR_NONE) return false; - + // wrap the rest of catch errors try { @@ -1231,7 +1231,7 @@ bool cheat_manager::save_all(const char *filename) mame_fclose(cheatfile); return true; } - + // catch errors and cleanup catch (emu_fatalerror &err) { @@ -1244,7 +1244,7 @@ bool cheat_manager::save_all(const char *filename) //------------------------------------------------- -// render_text - called by the UI system to +// render_text - called by the UI system to // render text //------------------------------------------------- @@ -1265,7 +1265,7 @@ void cheat_manager::render_text(render_container &container) //------------------------------------------------- // get_output_astring - return a reference to -// the given row's string, and set the +// the given row's string, and set the // justification //------------------------------------------------- @@ -1277,10 +1277,10 @@ astring &cheat_manager::get_output_astring(int row, int justify) // remember the last request m_lastline = row; - + // invert if negative row = (row < 0) ? m_numlines + row : row - 1; - + // clamp within range row = MAX(row, 0); row = MIN(row, m_numlines - 1); @@ -1398,7 +1398,7 @@ void cheat_manager::frame_update() //------------------------------------------------- -// load_cheats - load a cheat file into memory +// load_cheats - load a cheat file into memory // and create the cheat entry list //------------------------------------------------- @@ -1467,7 +1467,7 @@ void cheat_manager::load_cheats(const char *filename) filerr = mame_fclose_and_open_next(&cheatfile, fname, OPEN_FLAG_READ); } } - + // handle errors cleanly catch (emu_fatalerror &err) { diff --git a/src/emu/cheat.h b/src/emu/cheat.h index bca1832dc6d..84bab06ed92 100644 --- a/src/emu/cheat.h +++ b/src/emu/cheat.h @@ -83,7 +83,7 @@ public: // pass-through to look like a regular number operator UINT64 &() { return m_value; } operator const UINT64 &() const { return m_value; } - + // format the number according to its format const char *format(astring &string) const; @@ -116,13 +116,13 @@ public: // actions void save(mame_file &cheatfile) const; - + private: // a single item in a parameter item list class item { friend class simple_list<item>; - + public: // construction/destruction item(const char *text, UINT64 value, int valformat) @@ -130,11 +130,11 @@ private: m_text(text), m_value(value, valformat) { } - // getters + // getters item *next() const { return m_next; } const number_and_format &value() const { return m_value; } const char *text() const { return m_text; } - + private: // internal state item * m_next; // next item in list @@ -148,7 +148,7 @@ private: number_and_format m_stepval; // step value UINT64 m_value; // live value of the parameter astring m_curtext; // holding for a value string - simple_list<item> m_itemlist; // list of items + simple_list<item> m_itemlist; // list of items }; @@ -204,11 +204,11 @@ private: // actions void save(mame_file &cheatfile) const; - + private: // internal state output_argument * m_next; // link to next argument - parsed_expression m_expression; // expression for argument + parsed_expression m_expression; // expression for argument UINT64 m_count; // number of repetitions }; @@ -217,8 +217,8 @@ private: // internal state script_entry * m_next; // link to next entry - parsed_expression m_condition; // condition under which this is executed - parsed_expression m_expression; // expression to execute + parsed_expression m_condition; // condition under which this is executed + parsed_expression m_expression; // expression to execute astring m_format; // string format to print simple_list<output_argument> m_arglist; // list of arguments INT8 m_line; // which line to print on @@ -227,7 +227,7 @@ private: // constants static const int MAX_ARGUMENTS = 32; }; - + // internal state simple_list<script_entry> m_entrylist; // list of actions to perform script_state m_state; // which state this script is for @@ -240,12 +240,12 @@ private: class cheat_entry { friend class simple_list<cheat_entry>; - + public: // construction/destruction cheat_entry(cheat_manager &manager, symbol_table &globaltable, const char *filename, xml_data_node &cheatnode); ~cheat_entry(); - + // getters cheat_manager &manager() const { return m_manager; } cheat_entry *next() const { return m_next; } @@ -283,7 +283,7 @@ public: // UI helpers void menu_text(astring &description, astring &state, UINT32 &flags); - // per-frame update + // per-frame update void frame_update() { if (m_state == SCRIPT_STATE_RUN) execute_run_script(); } private: @@ -319,20 +319,20 @@ class cheat_manager public: // construction/destruction cheat_manager(running_machine &machine); - + // getters running_machine &machine() const { return m_machine; } bool enabled() const { return !m_disabled; } cheat_entry *first() const { return m_cheatlist.first(); } - + // setters void set_enable(bool enable = true); - + // actions void reload(); bool save_all(const char *filename); void render_text(render_container &container); - + // output helpers astring &get_output_astring(int row, int justify); @@ -346,7 +346,7 @@ private: static void frame_update_static(running_machine &machine); void frame_update(); void load_cheats(const char *filename); - + // internal state running_machine & m_machine; // reference to our machine simple_list<cheat_entry> m_cheatlist; // cheat list @@ -357,7 +357,7 @@ private: INT8 m_lastline; // last line used for output bool m_disabled; // true if the cheat engine is disabled symbol_table m_symtable; // global symbol table - + // constants static const int CHEAT_VERSION = 1; }; diff --git a/src/emu/cpu/dsp56k/inst.h b/src/emu/cpu/dsp56k/inst.h index 1142e0fa51c..011ba4887aa 100644 --- a/src/emu/cpu/dsp56k/inst.h +++ b/src/emu/cpu/dsp56k/inst.h @@ -925,7 +925,7 @@ public: bool decode(const UINT16 word0, const UINT16 word1) { /* Note: This is a JJJF limited in the docs, but other opcodes sneak - in before cmp, so the same decode function can be used. */ + in before cmp, so the same decode function can be used. */ decode_JJJF_table(BITSn(word0,0x07), BITSn(word0,0x08), m_source, m_destination); return true; @@ -950,7 +950,7 @@ public: bool decode(const UINT16 word0, const UINT16 word1) { /* Note: This is a JJJF limited in the docs, but other opcodes sneak - in before cmp, so the same decode function can be used. */ + in before cmp, so the same decode function can be used. */ decode_JJJF_table(BITSn(word0,0x07), BITSn(word0,0x08), m_source, m_destination); return true; @@ -2676,7 +2676,7 @@ public: bool decode(const UINT16 word0, const UINT16 word1) { /* There are inconsistencies with the S1 & S2 operand ordering in the docs, - but since it's a multiply it doesn't matter */ + but since it's a multiply it doesn't matter */ decode_QQQF_table(BITSn(word0,0x07), BITSn(word0,0x08), m_source, m_source2, m_destination); @@ -2772,7 +2772,7 @@ public: bool decode(const UINT16 word0, const UINT16 word1) { /* There are inconsistencies with the S1 & S2 operand ordering in the docs, - but since it's a multiply it doesn't matter */ + but since it's a multiply it doesn't matter */ decode_QQQF_table(BITSn(word0,0x07), BITSn(word0,0x08), m_source, m_source2, m_destination); diff --git a/src/emu/debug/debugcpu.c b/src/emu/debug/debugcpu.c index 61b06ae91b7..83cd78db618 100644 --- a/src/emu/debug/debugcpu.c +++ b/src/emu/debug/debugcpu.c @@ -154,7 +154,7 @@ void debug_cpu_init(running_machine *machine) /* create a global symbol table */ global->symtable = global_alloc(symbol_table(machine)); - + // configure our base memory accessors debug_cpu_configure_memory(*machine, *global->symtable); diff --git a/src/emu/debug/debugcpu.h b/src/emu/debug/debugcpu.h index b40e24eccef..0a8fd9c90c8 100644 --- a/src/emu/debug/debugcpu.h +++ b/src/emu/debug/debugcpu.h @@ -97,7 +97,7 @@ public: int m_index; // user reported index UINT8 m_enabled; // enabled? offs_t m_address; // execution address - parsed_expression m_condition; // condition + parsed_expression m_condition; // condition astring m_action; // action }; diff --git a/src/emu/debug/debugvw.c b/src/emu/debug/debugvw.c index 1166df72f1c..2454644c7ed 100644 --- a/src/emu/debug/debugvw.c +++ b/src/emu/debug/debugvw.c @@ -581,7 +581,7 @@ debug_view_expression::~debug_view_expression() void debug_view_expression::set_context(symbol_table *context) { - m_parsed.set_symbols((context != NULL) ? context : debug_cpu_get_global_symtable(&m_machine)); + m_parsed.set_symbols((context != NULL) ? context : debug_cpu_get_global_symtable(&m_machine)); m_dirty = true; } diff --git a/src/emu/debug/express.c b/src/emu/debug/express.c index 853f6adfa92..fa3cc71b366 100644 --- a/src/emu/debug/express.c +++ b/src/emu/debug/express.c @@ -1,7 +1,7 @@ /*************************************************************************** express.c - + Generic expressions engine. **************************************************************************** @@ -37,24 +37,24 @@ **************************************************************************** - Operator precedence - =================== - 0x0000 ( ) - 0x0001 ++ (postfix), -- (postfix) - 0x0002 ++ (prefix), -- (prefix), ~, !, - (unary), + (unary), b@, w@, d@, q@ - 0x0003 *, /, % - 0x0004 + - - 0x0005 << >> - 0x0006 < <= > >= - 0x0007 == != - 0x0008 & - 0x0009 ^ - 0x000a | - 0x000b && - 0x000c || - 0x000d = *= /= %= += -= <<= >>= &= |= ^= - 0x000e , - 0x000f func() + Operator precedence + =================== + 0x0000 ( ) + 0x0001 ++ (postfix), -- (postfix) + 0x0002 ++ (prefix), -- (prefix), ~, !, - (unary), + (unary), b@, w@, d@, q@ + 0x0003 *, /, % + 0x0004 + - + 0x0005 << >> + 0x0006 < <= > >= + 0x0007 == != + 0x0008 & + 0x0009 ^ + 0x000a | + 0x000b && + 0x000c || + 0x000d = *= /= %= += -= <<= >>= &= |= ^= + 0x000e , + 0x000f func() ***************************************************************************/ @@ -155,9 +155,9 @@ private: static UINT64 internal_getter(symbol_table &table, void *symref); static void internal_setter(symbol_table &table, void *symref, UINT64 value); - // internal state - symbol_table::getter_func m_getter; - symbol_table::setter_func m_setter; + // internal state + symbol_table::getter_func m_getter; + symbol_table::setter_func m_setter; UINT64 m_value; }; @@ -191,7 +191,7 @@ private: //************************************************************************** //------------------------------------------------- -// code_string - return a friendly string for a +// code_string - return a friendly string for a // given expression error //------------------------------------------------- @@ -321,7 +321,7 @@ void integer_symbol_entry::set_value(UINT64 newvalue) //------------------------------------------------- -// internal_getter - internal helper for +// internal_getter - internal helper for // returning the value of a variable //------------------------------------------------- @@ -425,7 +425,7 @@ symbol_table::symbol_table(void *globalref, symbol_table *parent) //------------------------------------------------- -// add - add a new UINT64 pointer symbol +// add - add a new UINT64 pointer symbol //------------------------------------------------- void symbol_table::configure_memory(void *param, valid_func valid, read_func read, write_func write) @@ -438,7 +438,7 @@ void symbol_table::configure_memory(void *param, valid_func valid, read_func rea //------------------------------------------------- -// add - add a new UINT64 pointer symbol +// add - add a new UINT64 pointer symbol //------------------------------------------------- void symbol_table::add(const char *name, read_write rw, UINT64 *ptr) @@ -449,7 +449,7 @@ void symbol_table::add(const char *name, read_write rw, UINT64 *ptr) //------------------------------------------------- -// add - add a new value symbol +// add - add a new value symbol //------------------------------------------------- void symbol_table::add(const char *name, UINT64 value) @@ -460,7 +460,7 @@ void symbol_table::add(const char *name, UINT64 value) //------------------------------------------------- -// add - add a new register symbol +// add - add a new register symbol //------------------------------------------------- void symbol_table::add(const char *name, void *ref, getter_func getter, setter_func setter) @@ -471,7 +471,7 @@ void symbol_table::add(const char *name, void *ref, getter_func getter, setter_f //------------------------------------------------- -// add - add a new function symbol +// add - add a new function symbol //------------------------------------------------- void symbol_table::add(const char *name, void *ref, int minparams, int maxparams, execute_func execute) @@ -500,7 +500,7 @@ symbol_entry *symbol_table::find_deep(const char *symbol) //------------------------------------------------- -// value - return the value of a symbol +// value - return the value of a symbol //------------------------------------------------- UINT64 symbol_table::value(const char *symbol) @@ -511,7 +511,7 @@ UINT64 symbol_table::value(const char *symbol) //------------------------------------------------- -// set_value - set the value of a symbol +// set_value - set the value of a symbol //------------------------------------------------- void symbol_table::set_value(const char *symbol, UINT64 value) @@ -593,7 +593,7 @@ parsed_expression::parsed_expression(symbol_table *symtable, const char *express // if we got an expression parse it if (expression != NULL) parse(expression); - + // if we get a result pointer, execute it if (result != NULL) *result = execute(); @@ -956,7 +956,7 @@ void parsed_expression::parse_symbol_or_number(parse_token &token, const char *& // if we have an 0x prefix, we must be a hex value if (buffer[0] == '0' && buffer[1] == 'x') return parse_number(token, &buffer[2], 16, expression_error::INVALID_NUMBER); - + // if we have a # prefix, we must be a decimal value if (buffer[0] == '#') return parse_number(token, &buffer[1], 10, expression_error::INVALID_NUMBER); @@ -964,7 +964,7 @@ void parsed_expression::parse_symbol_or_number(parse_token &token, const char *& // if we have a $ prefix, we are a hex value if (buffer[0] == '$') return parse_number(token, &buffer[1], 16, expression_error::INVALID_NUMBER); - + // check for a symbol match symbol_entry *symbol = m_symtable->find_deep(buffer); if (symbol != NULL) @@ -979,7 +979,7 @@ void parsed_expression::parse_symbol_or_number(parse_token &token, const char *& } return; } - + // attempt to parse as a number in the default base parse_number(token, buffer, DEFAULT_BASE, expression_error::UNKNOWN_SYMBOL); } @@ -1006,7 +1006,7 @@ void parsed_expression::parse_number(parse_token &token, const char *string, int int digit = ptr - numbers; if (digit >= base) break; - + // shift previous digits up and add in new digit value = (value * (UINT64)base) + digit; string++; @@ -1223,7 +1223,7 @@ void parsed_expression::normalize_operator(parse_token *prevtoken, parse_token & if (peek == NULL) break; - // if we hit an execute function operator, or else a left parenthesis that is + // if we hit an execute function operator, or else a left parenthesis that is // already tagged, then tag us as well if (peek->is_operator(TVL_EXECUTEFUNC) || (peek->is_operator(TVL_LPAREN) && peek->is_function_separator())) { @@ -1252,7 +1252,7 @@ void parsed_expression::infix_to_postfix() { // pre-determine our next token next = token->next(); - + // if the character is an operand, append it to the result string if (token->is_number() || token->is_symbol() || token->is_string()) m_tokenlist.append(*token); @@ -1686,7 +1686,7 @@ UINT64 parsed_expression::execute_tokens() //------------------------------------------------- parsed_expression::parse_token::parse_token(int offset) - : m_next(NULL), + : m_next(NULL), m_type(INVALID), m_offset(offset), m_value(0), @@ -1726,7 +1726,7 @@ inline void parsed_expression::parse_token::set_lval_value(symbol_table *table, // set the value of a symbol if (is_symbol()) m_symbol->set_value(value); - + // or set the value via the memory callbacks else if (is_memory() && table != NULL) table->set_memory_value(m_string, memory_space(), address(), 1 << memory_size(), value); diff --git a/src/emu/debug/express.h b/src/emu/debug/express.h index 8a5282ff855..26f267da282 100644 --- a/src/emu/debug/express.h +++ b/src/emu/debug/express.h @@ -114,7 +114,7 @@ public: // operators operator error_code() const { return m_code; } - + // getters error_code code() const { return m_code; } int offset() const { return m_offset; } @@ -134,7 +134,7 @@ class symbol_entry { friend class tagged_list<symbol_entry>; -protected: +protected: // symbol types enum symbol_type { @@ -150,10 +150,10 @@ public: // getters symbol_entry *next() const { return m_next; } const char *name() const { return m_name; } - + // type checking bool is_function() const { return (m_type == SMT_FUNCTION); } - + // symbol access virtual bool is_lval() const = 0; virtual UINT64 value() const = 0; @@ -179,7 +179,7 @@ public: // callback functions for getting/setting a symbol value typedef UINT64 (*getter_func)(symbol_table &table, void *symref); typedef void (*setter_func)(symbol_table &table, void *symref, UINT64 value); - + // callback functions for function execution typedef UINT64 (*execute_func)(symbol_table &table, void *symref, int numparams, const UINT64 *paramlist); @@ -196,15 +196,15 @@ public: // construction/destruction symbol_table(void *globalref, symbol_table *parent = NULL); - + // getters symbol_entry *first() const { return m_symlist.first(); } symbol_table *parent() const { return m_parent; } void *globalref() const { return m_globalref; } - + // setters void configure_memory(void *param, valid_func valid, read_func read, write_func write); - + // symbol access void add(const char *name, read_write rw, UINT64 *ptr = NULL); void add(const char *name, UINT64 constvalue); @@ -212,7 +212,7 @@ public: void add(const char *name, void *ref, int minparams, int maxparams, execute_func execute); symbol_entry *find(const char *name) { return m_symlist.find(name); } symbol_entry *find_deep(const char *name); - + // value getter/setter UINT64 value(const char *symbol); void set_value(const char *symbol, UINT64 value); @@ -253,7 +253,7 @@ public: const char *original_string() const { return m_original_string; } symbol_table *symbols() const { return m_symtable; } - // setters + // setters void set_symbols(symbol_table *symtable) { m_symtable = symtable; } // execution @@ -265,7 +265,7 @@ private: class parse_token { friend class simple_list<parse_token>; - + // operator flags enum { @@ -297,7 +297,7 @@ private: public: // construction/destruction parse_token(int offset = 0); - + // getters parse_token *next() const { return m_next; } int offset() const { return m_offset; } @@ -328,7 +328,7 @@ private: parse_token &configure_string(const char *string) { m_type = STRING; m_string = string; return *this; } parse_token &configure_memory(UINT32 address, parse_token &memoryat) { m_type = MEMORY; m_value = address; m_flags = memoryat.m_flags; m_string = memoryat.m_string; return *this; } parse_token &configure_symbol(symbol_entry &symbol) { m_type = SYMBOL; m_symbol = &symbol; return *this; } - parse_token &configure_operator(UINT8 optype, UINT8 precedence) + parse_token &configure_operator(UINT8 optype, UINT8 precedence) { m_type = OPERATOR; m_flags = ((optype << TIN_OPTYPE_SHIFT) & TIN_OPTYPE_MASK) | ((precedence << TIN_PRECEDENCE_SHIFT) & TIN_PRECEDENCE_MASK); return *this; } parse_token &set_function_separator() { assert(m_type == OPERATOR); m_flags |= TIN_FUNCTION_MASK; return *this; } @@ -336,7 +336,7 @@ private: parse_token &set_memory_space(expression_space space) { assert(m_type == OPERATOR || m_type == MEMORY); m_flags = (m_flags & ~TIN_MEMORY_SPACE_MASK) | ((space << TIN_MEMORY_SPACE_SHIFT) & TIN_MEMORY_SPACE_MASK); return *this; } parse_token &set_memory_size(int log2ofbits) { assert(m_type == OPERATOR || m_type == MEMORY); m_flags = (m_flags & ~TIN_MEMORY_SIZE_MASK) | ((log2ofbits << TIN_MEMORY_SIZE_SHIFT) & TIN_MEMORY_SIZE_MASK); return *this; } parse_token &set_memory_source(const char *string) { assert(m_type == OPERATOR || m_type == MEMORY); m_string = string; return *this; } - + // access UINT64 get_lval_value(symbol_table *symtable); void set_lval_value(symbol_table *symtable, UINT64 value); @@ -351,22 +351,22 @@ private: const char * m_string; // associated string symbol_entry * m_symbol; // symbol pointer }; - + // an expression_string holds an indexed string parsed from the expression class expression_string { friend class simple_list<expression_string>; - + public: // construction/destruction expression_string(const char *string, int length = 0) : m_next(NULL), m_string(string, (length == 0) ? strlen(string) : length) { } - + // operators operator const char *() { return m_string; } operator const char *() const { return m_string; } - + private: // internal state expression_string * m_next; // next string in list @@ -376,7 +376,7 @@ private: // internal helpers void copy(const parsed_expression &src); void print_tokens(FILE *out); - + // parsing helpers void parse_string_into_tokens(); void parse_symbol_or_number(parse_token &token, const char *&string); diff --git a/src/emu/render.h b/src/emu/render.h index a4d92250fa4..56d77928f48 100644 --- a/src/emu/render.h +++ b/src/emu/render.h @@ -741,7 +741,7 @@ public: // textures render_texture *texture_alloc(texture_scaler_func scaler = NULL, void *param = NULL); void texture_free(render_texture *texture); - + // fonts render_font *font_alloc(const char *filename = NULL); void font_free(render_font *font); diff --git a/src/emu/rendfont.c b/src/emu/rendfont.c index 80afe7ae091..6961a115120 100644 --- a/src/emu/rendfont.c +++ b/src/emu/rendfont.c @@ -79,7 +79,7 @@ inline const char *next_line(const char *ptr) inline render_font::glyph &render_font::get_char(unicode_char chnum) { static glyph dummy_glyph; - + // grab the table; if none, return the dummy character glyph *glyphtable = m_glyphs[chnum / 256]; if (glyphtable == NULL && m_format == FF_OSD) @@ -117,7 +117,7 @@ render_font::render_font(render_manager &manager, const char *filename) m_osdfont(NULL) { memset(m_glyphs, 0, sizeof(m_glyphs)); - + // if this is an OSD font, we're done if (filename != NULL) { @@ -129,7 +129,7 @@ render_font::render_font(render_manager &manager, const char *filename) return; } } - + // if the filename is 'default' default to 'ui.bdf' for backwards compatibility if (filename != NULL && mame_stricmp(filename, "default") == 0) filename = "ui.bdf"; @@ -173,7 +173,7 @@ render_font::~render_font() // free the raw data and the size itself auto_free(&m_manager.machine(), m_rawdata); - + // release the OSD font if (m_osdfont != NULL) m_manager.machine().osd().font_close(m_osdfont); @@ -181,7 +181,7 @@ render_font::~render_font() //------------------------------------------------- -// char_expand - expand the raw data for a +// char_expand - expand the raw data for a // character into a bitmap //------------------------------------------------- @@ -193,7 +193,7 @@ void render_font::char_expand(unicode_char chnum, glyph &gl) // we set bmwidth to -1 if we've previously queried and failed if (gl.bmwidth == -1) return; - + // attempt to get the font bitmap; if we fail, set bmwidth to -1 gl.bitmap = m_manager.machine().osd().font_get_bitmap(m_osdfont, chnum, gl.width, gl.xoffs, gl.yoffs); if (gl.bitmap == NULL) @@ -206,7 +206,7 @@ void render_font::char_expand(unicode_char chnum, glyph &gl) gl.bmwidth = gl.bitmap->width; gl.bmheight = gl.bitmap->height; } - + // other formats need to parse their data else { @@ -282,8 +282,8 @@ void render_font::char_expand(unicode_char chnum, glyph &gl) //------------------------------------------------- -// get_char_texture_and_bounds - return the -// texture for a character and compute the +// get_char_texture_and_bounds - return the +// texture for a character and compute the // bounds of the final bitmap //------------------------------------------------- @@ -351,7 +351,7 @@ void render_font::get_scaled_bitmap_and_bounds(bitmap_t &dest, float height, flo //------------------------------------------------- -// char_width - return the width of a character +// char_width - return the width of a character // at the given height //------------------------------------------------- @@ -362,7 +362,7 @@ float render_font::char_width(float height, float aspect, unicode_char ch) //------------------------------------------------- -// string_width - return the width of a string +// string_width - return the width of a string // at the given height //------------------------------------------------- @@ -379,7 +379,7 @@ float render_font::string_width(float height, float aspect, const char *string) //------------------------------------------------- -// utf8string_width - return the width of a +// utf8string_width - return the width of a // UTF8-encoded string at the given height //------------------------------------------------- @@ -406,9 +406,9 @@ float render_font::utf8string_width(float height, float aspect, const char *utf8 //------------------------------------------------- -// load_cached_bdf - attempt to load a cached -// version of the BDF font 'filename'; if that -// fails, fall back on the regular BDF loader +// load_cached_bdf - attempt to load a cached +// version of the BDF font 'filename'; if that +// fails, fall back on the regular BDF loader // and create a new cached version //------------------------------------------------- @@ -431,7 +431,7 @@ bool render_font::load_cached_bdf(const char *filename) mame_fclose(file); return false; } - + // has the chunk UINT32 hash = crc32(0, (const UINT8 *)data, bytes) ^ (UINT32)m_rawsize; @@ -456,7 +456,7 @@ bool render_font::load_cached_bdf(const char *filename) return true; } } - + // read in the rest of the font if (bytes < m_rawsize) { diff --git a/src/emu/rendfont.h b/src/emu/rendfont.h index 293ac3f4af2..ad930f63fb8 100644 --- a/src/emu/rendfont.h +++ b/src/emu/rendfont.h @@ -55,7 +55,7 @@ class render_font { friend class render_manager; friend resource_pool_object<render_font>::~resource_pool_object(); - + // construction/destruction render_font(render_manager &manager, const char *filename); virtual ~render_font(); @@ -63,7 +63,7 @@ class render_font public: // getters render_manager &manager() const { return m_manager; } - + // size queries INT32 pixel_height() const { return m_height; } float char_width(float height, float aspect, unicode_char ch); diff --git a/src/emu/sound/asc.c b/src/emu/sound/asc.c index 4038ba9a6a1..d591fca2548 100644 --- a/src/emu/sound/asc.c +++ b/src/emu/sound/asc.c @@ -4,7 +4,7 @@ Apple Sound Chip (ASC) 344S0063 Enhanced Apple Sound Chip (EASC) 343S1063 - + Emulation by R. Belmont Registers: @@ -212,7 +212,7 @@ void asc_device::stream_generate(stream_sample_t **inputs, stream_sample_t **out m_fifo_a_rdptr &= 0x3ff; m_fifo_cap_a--; } - + if (m_fifo_cap_b) { m_fifo_b_rdptr++; @@ -283,7 +283,7 @@ void asc_device::stream_generate(stream_sample_t **inputs, stream_sample_t **out INT8 smpl; mixL = mixR = 0; - + // update channel pointers for (ch = 0; ch < 4; ch++) { @@ -309,7 +309,7 @@ void asc_device::stream_generate(stream_sample_t **inputs, stream_sample_t **out break; } -// printf("rdA %04x rdB %04x wrA %04x wrB %04x (capA %04x B %04x)\n", m_fifo_a_rdptr, m_fifo_b_rdptr, m_fifo_a_wrptr, m_fifo_b_wrptr, m_fifo_cap_a, m_fifo_cap_b); +// printf("rdA %04x rdB %04x wrA %04x wrB %04x (capA %04x B %04x)\n", m_fifo_a_rdptr, m_fifo_b_rdptr, m_fifo_a_wrptr, m_fifo_b_wrptr, m_fifo_cap_a, m_fifo_cap_b); } //------------------------------------------------- @@ -320,7 +320,7 @@ READ8_MEMBER( asc_device::read ) { UINT8 rv; -// printf("ASC: read at %x\n", offset); +// printf("ASC: read at %x\n", offset); // not sure what actually happens when the CPU reads the FIFO... if (offset < 0x400) @@ -394,7 +394,7 @@ READ8_MEMBER( asc_device::read ) rv = m_regs[R_FIFOSTAT-0x800]; } -// printf("Read FIFO stat = %02x\n", rv); +// printf("Read FIFO stat = %02x\n", rv); // reading this register clears all bits m_regs[R_FIFOSTAT-0x800] = 0; @@ -454,7 +454,7 @@ READ8_MEMBER( asc_device::read ) WRITE8_MEMBER( asc_device::write ) { -// printf("ASC: write %02x to %x\n", data, offset); +// printf("ASC: write %02x to %x\n", data, offset); if (offset < 0x400) { @@ -488,7 +488,7 @@ WRITE8_MEMBER( asc_device::write ) } m_fifo_b_wrptr &= 0x3ff; - } + } else { m_fifo_b[offset-0x400] = data; @@ -496,7 +496,7 @@ WRITE8_MEMBER( asc_device::write ) } else { -// printf("ASC: %02x to %x (was %x)\n", data, offset, m_regs[offset-0x800]); +// printf("ASC: %02x to %x (was %x)\n", data, offset, m_regs[offset-0x800]); stream_update(m_stream); switch (offset) @@ -531,10 +531,10 @@ WRITE8_MEMBER( asc_device::write ) break; case R_WTCONTROL: -// printf("One-shot wavetable %02x\n", data); +// printf("One-shot wavetable %02x\n", data); break; - case 0x811: + case 0x811: m_phase[0] &= 0x00ffff; m_phase[0] |= data<<16; break; @@ -549,7 +549,7 @@ WRITE8_MEMBER( asc_device::write ) m_phase[0] |= data; break; - case 0x815: + case 0x815: m_incr[0] &= 0x00ffff; m_incr[0] |= data<<16; break; @@ -564,7 +564,7 @@ WRITE8_MEMBER( asc_device::write ) m_incr[0] |= data; break; - case 0x819: + case 0x819: m_phase[1] &= 0x00ffff; m_phase[1] |= data<<16; break; @@ -579,7 +579,7 @@ WRITE8_MEMBER( asc_device::write ) m_phase[1] |= data; break; - case 0x81d: + case 0x81d: m_incr[1] &= 0x00ffff; m_incr[1] |= data<<16; break; @@ -594,7 +594,7 @@ WRITE8_MEMBER( asc_device::write ) m_incr[1] |= data; break; - case 0x821: + case 0x821: m_phase[2] &= 0x00ffff; m_phase[2] |= data<<16; break; @@ -609,7 +609,7 @@ WRITE8_MEMBER( asc_device::write ) m_phase[2] |= data; break; - case 0x825: + case 0x825: m_incr[2] &= 0x00ffff; m_incr[2] |= data<<16; break; @@ -624,7 +624,7 @@ WRITE8_MEMBER( asc_device::write ) m_incr[2] |= data; break; - case 0x829: + case 0x829: m_phase[3] &= 0x00ffff; m_phase[3] |= data<<16; break; @@ -639,7 +639,7 @@ WRITE8_MEMBER( asc_device::write ) m_phase[3] |= data; break; - case 0x82d: + case 0x82d: m_incr[3] &= 0x00ffff; m_incr[3] |= data<<16; break; diff --git a/src/emu/sound/disc_dev.c b/src/emu/sound/disc_dev.c index 786883593a7..57799fdb40b 100644 --- a/src/emu/sound/disc_dev.c +++ b/src/emu/sound/disc_dev.c @@ -547,7 +547,7 @@ DISCRETE_STEP(dsd_555_mstbl) if (UNEXPECTED(DSD_555_MSTBL__C == 0)) { /* The trigger voltage goes high because the cap circuit is open. - * and the cap discharges */ + * and the cap discharges */ v_cap = info->v_pos; /* needed for cap output type */ context->cap_voltage = 0; diff --git a/src/emu/sound/disc_mth.c b/src/emu/sound/disc_mth.c index c3ed99658f9..e26d86885f6 100644 --- a/src/emu/sound/disc_mth.c +++ b/src/emu/sound/disc_mth.c @@ -2300,7 +2300,7 @@ DISCRETE_STEP(dst_xtime_and) //case XTIME__IN0_0__IN1_0__IN0_X__IN1_NOX: //case XTIME__IN0_0__IN1_1__IN0_NOX__IN1_X: //case XTIME__IN0_1__IN1_0__IN0_X__IN1_NOX: - // break; + // break; case XTIME__IN0_1__IN1_1__IN0_NOX__IN1_NOX: out = 1; @@ -2308,52 +2308,52 @@ DISCRETE_STEP(dst_xtime_and) case XTIME__IN0_0__IN1_1__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------- - * ...^....^... - * - * in1 1 ------------- - * 0 - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------- + * ...^....^... + * + * in1 1 ------------- + * 0 + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time0; break; case XTIME__IN0_1__IN1_0__IN0_NOX__IN1_X: /* - * in0 1 ------------- - * 0 - * ...^....^... - * - * in1 1 ------ - * 0 ------- - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------------- + * 0 + * ...^....^... + * + * in1 1 ------ + * 0 ------- + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time1; break; case XTIME__IN0_0__IN1_0__IN0_X__IN1_X: /* - * in0 1 ----- ------- - * 0 -------- ------ - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ------ -------- - * ...^....^... ...^....^... - * - * out 1 ----- ----- - * 0 ------- ------- - * ...^....^... ...^....^... - */ + * in0 1 ----- ------- + * 0 -------- ------ + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ------ -------- + * ...^....^... ...^....^... + * + * out 1 ----- ----- + * 0 ------- ------- + * ...^....^... ...^....^... + */ // use x_time of input that went to 0 first/longer if (x_time0 >= x_time1) x_time = x_time0; @@ -2363,92 +2363,92 @@ DISCRETE_STEP(dst_xtime_and) case XTIME__IN0_0__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 -- - * 0 ----- ----- ------------ - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 -- + * 0 ----- ----- ------------ + * ...^....^... ...^....^... + */ // may have went high for a bit in this cycle //if (x_time0 < x_time1) - // x_time = time1 - x_time0; + // x_time = time1 - x_time0; break; case XTIME__IN0_1__IN1_0__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 -- - * 0 ----- ----- ------------ - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 -- + * 0 ----- ----- ------------ + * ...^....^... ...^....^... + */ // may have went high for a bit in this cycle //if (x_time0 > x_time1) - // x_time = x_time0 - x_time1; + // x_time = x_time0 - x_time1; break; case XTIME__IN0_1__IN1_1__IN0_NOX__IN1_X: /* - * in0 1 ------------ - * 0 - * ...^....^... - * - * in1 1 ------ - * 0 ------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------------ + * 0 + * ...^....^... + * + * in1 1 ------ + * 0 ------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 1; x_time = x_time1; break; case XTIME__IN0_1__IN1_1__IN0_X__IN1_NOX: /* - * in1 0 ------ - * 0 ------ - * ...^....^... - * - * in1 1 ------------ - * 0 - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in1 0 ------ + * 0 ------ + * ...^....^... + * + * in1 1 ------------ + * 0 + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 1; x_time = x_time0; break; case XTIME__IN0_1__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------ -------- - * 0 ------ ---- - * ...^....^... ...^....^... - * - * in1 1 -------- ------ - * 0 ---- ------ - * ...^....^... ...^....^... - * - * out 1 ------ ------ - * 0 ------ ------ - * ...^....^... ...^....^... - */ + * in0 1 ------ -------- + * 0 ------ ---- + * ...^....^... ...^....^... + * + * in1 1 -------- ------ + * 0 ---- ------ + * ...^....^... ...^....^... + * + * out 1 ------ ------ + * 0 ------ ------ + * ...^....^... ...^....^... + */ out = 1; if (x_time0 < x_time1) x_time = x_time0; @@ -2520,7 +2520,7 @@ DISCRETE_STEP(dst_xtime_or) //case XTIME__IN0_0__IN1_1__IN0_X__IN1_NOX: //case XTIME__IN0_1__IN1_1__IN0_NOX__IN1_X: //case XTIME__IN0_1__IN1_1__IN0_X__IN1_NOX: - // break; + // break; case XTIME__IN0_0__IN1_0__IN0_NOX__IN1_NOX: out = 0; @@ -2528,54 +2528,54 @@ DISCRETE_STEP(dst_xtime_or) case XTIME__IN0_0__IN1_0__IN0_NOX__IN1_X: /* - * in0 1 - * 0 ------------- - * ...^....^... - * - * in1 1 ------ - * 0 ------- - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 + * 0 ------------- + * ...^....^... + * + * in1 1 ------ + * 0 ------- + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 0; x_time = x_time1; break; case XTIME__IN0_0__IN1_0__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------- - * ...^....^... - * - * in1 1 - * 0 ------------- - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------- + * ...^....^... + * + * in1 1 + * 0 ------------- + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 0; x_time = x_time0; break; case XTIME__IN0_0__IN1_0__IN0_X__IN1_X: /* - * in0 1 ----- ------- - * 0 -------- ------ - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ------ -------- - * ...^....^... ...^....^... - * - * out 1 ------- ------- - * 0 ----- ----- - * ...^....^... ...^....^... - */ + * in0 1 ----- ------- + * 0 -------- ------ + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ------ -------- + * ...^....^... ...^....^... + * + * out 1 ------- ------- + * 0 ----- ----- + * ...^....^... ...^....^... + */ out = 0; // use x_time of input that was 1 last/longer // this means at 0 for less x_time @@ -2587,94 +2587,94 @@ DISCRETE_STEP(dst_xtime_or) case XTIME__IN0_0__IN1_1__IN0_NOX__IN1_X: /* - * in0 1 - * 0 ------------ - * ...^....^... - * - * in1 1 ------ - * 0 ------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 + * 0 ------------ + * ...^....^... + * + * in1 1 ------ + * 0 ------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time1; break; case XTIME__IN0_1__IN1_0__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------ - * ...^....^... - * - * in1 1 - * 0 ------------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------ + * ...^....^... + * + * in1 1 + * 0 ------------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time0; break; case XTIME__IN0_0__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 ------------ ----- ----- - * 0 -- - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 ------------ ----- ----- + * 0 -- + * ...^....^... ...^....^... + */ // if (x_time0 > x_time1) /* Not sure if it is better to use 1 - * or the total energy which would smear the switch points together. - * Let's try just using 1 */ + * or the total energy which would smear the switch points together. + * Let's try just using 1 */ //x_time = xtime_0 - xtime_1; break; case XTIME__IN0_1__IN1_0__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 ------------ ----- ----- - * 0 -- - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 ------------ ----- ----- + * 0 -- + * ...^....^... ...^....^... + */ //if (x_time0 < x_time1) /* Not sure if it is better to use 1 - * or the total energy which would smear the switch points together. - * Let's try just using 1 */ + * or the total energy which would smear the switch points together. + * Let's try just using 1 */ //x_time = xtime_1 - xtime_0; break; case XTIME__IN0_1__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------ -------- - * 0 ------ ---- - * ...^....^... ...^....^... - * - * in1 1 -------- ------ - * 0 ---- ------ - * ...^....^... ...^....^... - * - * out 1 -------- -------- - * 0 ---- ---- - * ...^....^... ...^....^... - */ + * in0 1 ------ -------- + * 0 ------ ---- + * ...^....^... ...^....^... + * + * in1 1 -------- ------ + * 0 ---- ------ + * ...^....^... ...^....^... + * + * out 1 -------- -------- + * 0 ---- ---- + * ...^....^... ...^....^... + */ if (x_time0 > x_time1) x_time = x_time0; else @@ -2740,7 +2740,7 @@ DISCRETE_STEP(dst_xtime_xor) // these are all 1 //case XTIME__IN0_0__IN1_1__IN0_NOX__IN1_NOX: //case XTIME__IN0_1__IN1_0__IN0_NOX__IN1_NOX: - // break; + // break; case XTIME__IN0_1__IN1_1__IN0_NOX__IN1_NOX: case XTIME__IN0_0__IN1_0__IN0_NOX__IN1_NOX: @@ -2749,196 +2749,196 @@ DISCRETE_STEP(dst_xtime_xor) case XTIME__IN0_1__IN1_0__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------ - * ...^....^... - * - * in1 1 - * 0 ------------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------ + * ...^....^... + * + * in1 1 + * 0 ------------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ case XTIME__IN0_0__IN1_1__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------- - * ...^....^... - * - * in1 1 ------------- - * 0 - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------- + * ...^....^... + * + * in1 1 ------------- + * 0 + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time0; break; case XTIME__IN0_0__IN1_1__IN0_NOX__IN1_X: /* - * in0 1 - * 0 ------------ - * ...^....^... - * - * in1 1 ------ - * 0 ------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 + * 0 ------------ + * ...^....^... + * + * in1 1 ------ + * 0 ------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ case XTIME__IN0_1__IN1_0__IN0_NOX__IN1_X: /* - * in0 1 ------------- - * 0 - * ...^....^... - * - * in1 1 ------ - * 0 ------- - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------------- + * 0 + * ...^....^... + * + * in1 1 ------ + * 0 ------- + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ x_time = x_time1; break; case XTIME__IN0_0__IN1_0__IN0_X__IN1_NOX: /* - * in0 1 ------ - * 0 ------ - * ...^....^... - * - * in1 1 - * 0 ------------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------ + * 0 ------ + * ...^....^... + * + * in1 1 + * 0 ------------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ case XTIME__IN0_1__IN1_1__IN0_X__IN1_NOX: /* - * in1 0 ------ - * 0 ------ - * ...^....^... - * - * in1 1 ------------ - * 0 - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in1 0 ------ + * 0 ------ + * ...^....^... + * + * in1 1 ------------ + * 0 + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 0; x_time = x_time0; break; case XTIME__IN0_0__IN1_0__IN0_NOX__IN1_X: /* - * in0 1 - * 0 ------------ - * ...^....^... - * - * in1 1 ------ - * 0 ------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 + * 0 ------------ + * ...^....^... + * + * in1 1 ------ + * 0 ------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ case XTIME__IN0_1__IN1_1__IN0_NOX__IN1_X: /* - * in0 1 ------------ - * 0 - * ...^....^... - * - * in1 1 ------ - * 0 ------ - * ...^....^... - * - * out 1 ------ - * 0 ------ - * ...^....^... - */ + * in0 1 ------------ + * 0 + * ...^....^... + * + * in1 1 ------ + * 0 ------ + * ...^....^... + * + * out 1 ------ + * 0 ------ + * ...^....^... + */ out = 0; x_time = x_time1; break; case XTIME__IN0_0__IN1_0__IN0_X__IN1_X: /* - * in0 1 ----- ------- - * 0 ------- ----- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 -- -- - * 0 ----- ----- ----- ----- - * ...^....^... ...^....^... - */ + * in0 1 ----- ------- + * 0 ------- ----- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 -- -- + * 0 ----- ----- ----- ----- + * ...^....^... ...^....^... + */ case XTIME__IN0_1__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------ -------- - * 0 ------ ---- - * ...^....^... ...^....^... - * - * in1 1 -------- ------ - * 0 ---- ------ - * ...^....^... ...^....^... - * - * out 1 -- -- - * 0 ---- ------ ---- ------ - * ...^....^... ...^....^... - */ + * in0 1 ------ -------- + * 0 ------ ---- + * ...^....^... ...^....^... + * + * in1 1 -------- ------ + * 0 ---- ------ + * ...^....^... ...^....^... + * + * out 1 -- -- + * 0 ---- ------ ---- ------ + * ...^....^... ...^....^... + */ out = 0; /* Not sure if it is better to use 0 - * or the total energy which would smear the switch points together. - * Let's try just using 0 */ + * or the total energy which would smear the switch points together. + * Let's try just using 0 */ // x_time = abs(x_time0 - x_time1); break; case XTIME__IN0_0__IN1_1__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 ----- ----- ----- ----- - * 0 -- -- - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 ----- ----- ----- ----- + * 0 -- -- + * ...^....^... ...^....^... + */ case XTIME__IN0_1__IN1_0__IN0_X__IN1_X: /* - * in0 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * in1 1 ------- ----- - * 0 ----- ------- - * ...^....^... ...^....^... - * - * out 1 ----- ----- ----- ----- - * 0 -- -- - * ...^....^... ...^....^... - */ + * in0 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * in1 1 ------- ----- + * 0 ----- ------- + * ...^....^... ...^....^... + * + * out 1 ----- ----- ----- ----- + * 0 -- -- + * ...^....^... ...^....^... + */ /* Not sure if it is better to use 1 - * or the total energy which would smear the switch points together. - * Let's try just using 1 */ + * or the total energy which would smear the switch points together. + * Let's try just using 1 */ // x_time = 1.0 - abs(x_time0 - x_time1); break; } |