Sha256: caaa66c83ae0cfec5cf8e61b9a9d39bb0b1a1a4700384a780a4f6f3e26e0222d

Contents?: true

Size: 1.8 KB

Versions: 2

Compression:

Stored size: 1.8 KB

Contents

module FMOD
  module Core
    class AdvancedSettings < Structure

      def initialize(address = nil)
        types = Array.new(9, TYPE_INT) + [TYPE_VOIDP, TYPE_VOIDP] + Array.new(4,
                TYPE_FLOAT) + [TYPE_INT, TYPE_SHORT, TYPE_INT, TYPE_FLOAT] +
                Array.new(8, TYPE_INT)
        members = [ :cb_ize, :max_MPEG_codecs, :max_ADPCM_codecs,
                    :max_XMA_codecs, :max_Vorbis_codecs, :max_AT9_codecs,
                    :max_FADPCM_codecs, :max_PCM_codecs, :ASIO_channels,
                    :ASI_channel_list, :ASIO_speaker_list, :HRTF_min_angle,
                    :HRTF_max_angle, :HRTF_freq, :vol0_virtual_vol,
                    :default_decode_buffer_size, :profile_port,
                    :geometry_max_fade_time, :distance_filter_center_freq,
                    :reverb3D_instance, :dsp_buffer_pool_size,
                    :stack_size_stream, :stack_size_non_blocking,
                    :stack_size_mixer, :resampler_method, :command_queue_size,
                    :random_seed]
        super(address, types, members)
      end

      [:cb_ize, :max_MPEG_codecs, :max_ADPCM_codecs, :max_XMA_codecs,
       :max_Vorbis_codecs, :max_AT9_codecs, :max_FADPCM_codecs, :max_PCM_codecs,
       :ASIO_channels, :ASI_channel_list, :ASIO_speaker_list, :HRTF_min_angle,
       :HRTF_max_angle, :HRTF_freq, :vol0_virtual_vol,
       :default_decode_buffer_size, :profile_port, :geometry_max_fade_time,
       :distance_filter_center_freq, :reverb3D_instance, :dsp_buffer_pool_size,
       :stack_size_stream, :stack_size_non_blocking, :stack_size_mixer,
       :resampler_method, :command_queue_size, :random_seed].each do |sym|

        define_method(sym) { self[sym] }
        define_method("#{sym}=") { |value| self[sym] = value }
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
fmod-0.9.6 lib/fmod/core/advanced_settings.rb
fmod-0.9.5 lib/fmod/core/advanced_settings.rb