mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-12 16:47:31 -05:00
Decouples DecoderState from the Decoder and makes DecoderState inherit
from Module so that Decoder can function independent of DecoderSTate and DecoderState can more cleanly interface with other modules. Resolves issue with LTR-type decoders where the AudioModule was filtering demodulated audio buffers before the decoder received the audio - demodulated audio buffers are now copied before creating AudioPackets.
This commit is contained in:
@@ -29,16 +29,16 @@ public class LTRCallEvent extends CallEvent
|
||||
private long mFrequency;
|
||||
private int mValidCallMessages = 1;
|
||||
|
||||
public LTRCallEvent( CallEventType callEventType,
|
||||
AliasList aliasList,
|
||||
String fromID,
|
||||
String toID,
|
||||
String channel,
|
||||
long frequency,
|
||||
String details )
|
||||
public LTRCallEvent( DecoderType type,
|
||||
CallEventType callEventType,
|
||||
AliasList aliasList,
|
||||
String fromID,
|
||||
String toID,
|
||||
String channel,
|
||||
long frequency,
|
||||
String details )
|
||||
{
|
||||
super( DecoderType.LTR_STANDARD, callEventType,
|
||||
aliasList, fromID, toID, details );
|
||||
super( type, callEventType, aliasList, fromID, toID, details );
|
||||
|
||||
mChannel = channel;
|
||||
mFrequency = frequency;
|
||||
@@ -163,6 +163,7 @@ public class LTRCallEvent extends CallEvent
|
||||
public static class Builder
|
||||
{
|
||||
/* Required parameters */
|
||||
private DecoderType mDecoderType;
|
||||
private CallEventType mCallEventType;
|
||||
|
||||
/* Optional parameters */
|
||||
@@ -173,8 +174,9 @@ public class LTRCallEvent extends CallEvent
|
||||
private String mChannel;
|
||||
private long mFrequency;
|
||||
|
||||
public Builder( CallEventType callEventType )
|
||||
public Builder( DecoderType decoderType, CallEventType callEventType )
|
||||
{
|
||||
mDecoderType = decoderType;
|
||||
mCallEventType = callEventType;
|
||||
}
|
||||
|
||||
@@ -226,7 +228,8 @@ public class LTRCallEvent extends CallEvent
|
||||
*/
|
||||
private LTRCallEvent( Builder builder )
|
||||
{
|
||||
this( builder.mCallEventType,
|
||||
this( builder.mDecoderType,
|
||||
builder.mCallEventType,
|
||||
builder.mAliasList,
|
||||
builder.mFromID,
|
||||
builder.mToID,
|
||||
|
||||
Reference in New Issue
Block a user