Skip to content

NSF driver player update order

Persune edited this page Jan 23, 2023 · 1 revision
ft_music_play
    (delay handling)
    (tempo handling)
    ft_do_row_update
        (frame handling)
        ft_read_channels (foreach channels do:)
            ft_read_pattern
                ft_read_note
                    (switch case pattern command)
                        (handle volume commands)
                        (handle instrument commands)
                        (handle effect commands)
                    ft_push_echo_buffer
                    (handle note off)
                    (handle note release)
                    (load echo buffer)
                    ft_push_echo_buffer
                    (handle note)
            ft_read_is_done
    ft_skip_row_update (when no updates are available)
        (tempo handling)
    ft_loop_fx_state
        (Sxx handling)
        (delayed transpose/release handling)
    ft_loop_channels (foreach channels do:)
        ft_run_effects (handles the rest of the other effects)
        ft_run_instrument
        ft_calc_period
        (Nxy handling)
    ft_update_<chip> (foreach chip do:)
        (register writes)