public FourierTask(WaveSpectrumBufferCPU buffer, FourierCPU fourier, int index, int numGrids) : base(true) { if (m_index == -1) { throw new InvalidOperationException("Index can be -1. Fourier for multiple buffers is not being used"); } if (!(buffer is DisplacementBufferCPU)) //TODO - fix me { throw new InvalidOperationException("Fourier task currently only designed for displacement buffers"); } m_buffer = buffer as DisplacementBufferCPU; m_fourier = fourier; m_index = index; m_numGrids = numGrids; WaveSpectrumBufferCPU.Buffer b = m_buffer.GetBuffer(m_index); m_data = b.data; m_results = b.results; m_map = b.map; m_doublePacked = b.doublePacked; }
public InitSpectrumDisplacementsTask(DisplacementBufferCPU buffer, WaveSpectrumCondition condition, float time) : base(true) { this.Buffer = buffer; this.NumGrids = condition.Key.NumGrids; this.Size = condition.Key.Size; this.SpectrumType = condition.Key.SpectrumType; this.TimeValue = time; this.Reset(condition, time); this.CreateKTables(condition.InverseGridSizes()); }
public InitSpectrumDisplacementsTask(DisplacementBufferCPU buffer, WaveSpectrumCondition condition, float time) : base(true) { Buffer = buffer; NumGrids = condition.Key.NumGrids; Size = condition.Key.Size; SpectrumType = condition.Key.SpectrumType; TimeValue = time; Reset(condition, time); CreateKTables(condition.InverseGridSizes()); }
public FourierTask(WaveSpectrumBufferCPU buffer, FourierCPU fourier, int index, int numGrids) : base(true) { if (this.m_index == -1) { throw new InvalidOperationException("Index can be -1. Fourier for multiple buffers is not being used"); } if (!(buffer is DisplacementBufferCPU)) { throw new InvalidOperationException("Fourier task currently only designed for displacement buffers"); } this.m_buffer = (buffer as DisplacementBufferCPU); this.m_fourier = fourier; this.m_index = index; this.m_numGrids = numGrids; WaveSpectrumBufferCPU.Buffer buffer2 = this.m_buffer.GetBuffer(this.m_index); this.m_data = buffer2.data; this.m_results = buffer2.results; this.m_map = buffer2.map; this.m_doublePacked = buffer2.doublePacked; }
public InitSpectrumDisplacementsTask GetInitSpectrumDisplacementsTask(DisplacementBufferCPU buffer, float time) { return(new InitSpectrumDisplacementsTask(buffer, this, time)); }
public InitSpectrumDisplacementsTask GetInitSpectrumDisplacementsTask(DisplacementBufferCPU buffer, float time) { return new InitSpectrumDisplacementsTask(buffer, this, time); }