public class WZStreamConfig extends WZMediaConfig implements Serializable
WZStreamConfig
class provides configuration properties for the streaming connectionModifier and Type | Field and Description |
---|---|
static String |
DEFAULT_APP
The default value for the name of the live streaming application (""live"")
|
static int |
DEFAULT_PORT
The default value for the server connection port number (1935)
|
static String |
DEFAULT_STREAM
The default value for the target stream name (""myStream"")
|
ALWAYS_LANDSCAPE, ALWAYS_PORTRAIT, AUDIO_CHANNELS_MONO, AUDIO_CHANNELS_STEREO, CROP_TO_FRAME, DEFAULT_AUDIO_BITRATE, DEFAULT_AUDIO_SAMPLE_RATE, DEFAULT_SCALE_MODE, DEFAULT_VIDEO_BITRATE, DEFAULT_VIDEO_BITRATE_SCALING_FACTOR, DEFAULT_VIDEO_FRAME_BUFFER_MULTIPLIER, DEFAULT_VIDEO_FRAME_HEIGHT, DEFAULT_VIDEO_FRAME_RATE, DEFAULT_VIDEO_FRAME_SIZE, DEFAULT_VIDEO_FRAME_SKIP_COUNT, DEFAULT_VIDEO_FRAME_WIDTH, DEFAULT_VIDEO_KEYFRAME_INTERVAL, FILL_FRAME, FILL_VIEW, FRAME_SIZE_1280x720, FRAME_SIZE_1440x1080, FRAME_SIZE_176x144, FRAME_SIZE_1920x1080, FRAME_SIZE_320x240, FRAME_SIZE_352x288, FRAME_SIZE_3840x2160, FRAME_SIZE_640x480, FRAME_SIZE_960x540, ORIENTATION_LANDSCAPE, ORIENTATION_LANDSCAPE_INVERTED, ORIENTATION_PORTRAIT, ORIENTATION_PORTRAIT_INVERTED, PRESET_CONFIGS, RESIZE_TO_ASPECT, SAME_AS_SOURCE, SUPPORTED_AUDIO_SAMPLE_RATES
Constructor and Description |
---|
WZStreamConfig()
The default constructor
|
WZStreamConfig(WZMediaConfig preset)
Construct a new instance using the property values from the specified preset configuration
|
WZStreamConfig(WZStreamConfig other)
Construct a new instance using the property values from the specified instance
|
Modifier and Type | Method and Description |
---|---|
String |
getApplicationName()
Returns the name of the live streaming application
|
WZDataMap |
getConnectionParameters() |
String |
getConnectionURL()
Returns a fully qualified connection URL for this instance
|
String |
getHostAddress()
Returns the hostname or IP address of the streaming server
|
int |
getLogLevel()
Deprecated.
Use
WZBroadcast.getLogLevel() instead |
String |
getPassword()
Returns the password for Source Authentication
|
int |
getPortNumber()
Returns the server connection port number
|
WZDataMap |
getStreamMetadata() |
String |
getStreamName()
Returns the target stream name
|
String |
getUsername()
Returns the username for Source Authentication
|
void |
set(WZMediaConfig preset)
Update the property values of this instance with the property values from the specified preset configuration
|
void |
set(WZStreamConfig other)
Update the property values of this instance with the property values from the specified instance
|
void |
setApplicationName(String applicationName)
Sets The name of the live streaming application
|
void |
setConnectionParameters(WZDataMap connectionParameters)
The elements in the specified data map will be added to the connection url
as query string parameters and accessible to Wowza Streaming Engine server
modules through the getQueryStr method of the IClient interface.
|
void |
setHostAddress(String address)
Set the hostname or IP address of the streaming server
|
void |
setLogLevel(int logLevel)
Deprecated.
Use
WZBroadcast.setLogLevel(int) instead |
void |
setPassword(String password)
Sets the password for Source Authentication
|
void |
setPortNumber(int port)
Set the server connection port number
|
void |
setStreamMetadata(WZDataMap streamMetadata)
The key/value pairs in the specified data map will be added to the stream metadata
and accessible to Wowza Streaming Engine server modules through the onMetadata method of the
IMediaStreamActionNotify2 interface.
|
void |
setStreamName(String streamName)
Sets the target stream name
|
void |
setUsername(String username)
Sets the username for Source Authentication
|
WZDataMap |
toDataMap(WZDataMap dataMap)
Returns a
WZDataMap containing the configuration properties |
String |
toString() |
WZStreamingError |
validateForBroadcast()
Validates that the minimum set of property values have been specified necessary to initiate
a live streaming broadcast
|
WZStreamingError |
validateForPlayback()
Validates that the minimum set of property values have been specified necessary to play a stream
|
bitrateLabel, compareTo, equals, fromFrameSizes, getAudioBitRate, getAudioChannels, getAudioSampleRate, getFrameBufferSizeMultiplier, getFrameRateLowBandwidthSkipCount, getLabel, getLabel, getLowBandwidthScalingFactor, getPresetLabel, getPresetLabelByFrameSize, getVideoBitRate, getVideoFrameHeight, getVideoFramerate, getVideoFrameSize, getVideoFrameWidth, getVideoKeyFrameInterval, getVideoProfileLevel, getVideoRotation, isABREnabled, isAudioEnabled, isLandscape, isLandscapeRotation, isPortrait, isPortraitRotation, isValidScaleMode, isVideoEnabled, keyFrameIntervalFramesToSeconds, orientationLabel, orientationToRotation, orientationToSurfaceRotation, resetToDefaults, rotationToOrientation, setABREnabled, setAudioBitRate, setAudioChannels, setAudioEnabled, setAudioSampleRate, setFrameBufferSizeMultiplier, setFrameRateLowBandwidthSkipCount, setLowBandwidthScalingFactor, setVideoBitRate, setVideoEnabled, setVideoFrameHeight, setVideoFramerate, setVideoFrameSize, setVideoFrameSize, setVideoFrameWidth, setVideoKeyFrameInterval, setVideoProfileLevel, setVideoProfileLevel, setVideoRotation, surfaceRotationToOrientation, toDataMap, toFrameSizes
public static final int DEFAULT_PORT
public static final String DEFAULT_APP
public static final String DEFAULT_STREAM
public WZStreamConfig()
public WZStreamConfig(WZStreamConfig other)
other
- The instance to replicatepublic WZStreamConfig(WZMediaConfig preset)
preset
- The preset configuration to replicatepublic void set(WZStreamConfig other)
other
- The instance with the property values to replicatepublic void set(WZMediaConfig preset)
set
in class WZMediaConfig
preset
- The preset configuration with the property values to replicatepublic String getHostAddress()
public void setHostAddress(String address)
address
- A hostname or IP addresspublic int getPortNumber()
public void setPortNumber(int port)
port
- A port numberpublic String getApplicationName()
public void setApplicationName(String applicationName)
applicationName
- The name of the live streaming applicationpublic String getStreamName()
public void setStreamName(String streamName)
streamName
- Tshe stream namepublic String getUsername()
public void setUsername(String username)
username
- The usernamepublic String getPassword()
public void setPassword(String password)
password
- The passwordpublic void setStreamMetadata(WZDataMap streamMetadata)
WZDataType.DATA_LIST
and WZDataType.DATA_MAP
will be ignored.streamMetadata
- A map of key/value pairs defining the metadata.public WZDataMap getStreamMetadata()
public void setConnectionParameters(WZDataMap connectionParameters)
WZDataType.DATE
values will be serialized as an Epoch-based
long value representing the number of seconds that have elapsed since January 1, 1970
and non-primitive elements of type WZDataType.DATA_LIST
and WZDataType.DATA_MAP
will be ignored.connectionParameters
- A map of key/value pairs defining the connection url's query string parameters.
Note that elements of type WZDataType.DATA_LIST
and WZDataType.DATA_MAP
will be ignoredpublic WZDataMap getConnectionParameters()
public String getConnectionURL()
public int getLogLevel()
WZBroadcast.getLogLevel()
insteadpublic void setLogLevel(int logLevel)
WZBroadcast.setLogLevel(int)
insteadpublic WZStreamingError validateForBroadcast()
true
> is validation succeeds, false
> otherwisepublic WZStreamingError validateForPlayback()
true
> is validation succeeds, false
> otherwisepublic String toString()
toString
in class WZMediaConfig
public WZDataMap toDataMap(WZDataMap dataMap)
WZDataMap
containing the configuration propertiestoDataMap
in class WZMediaConfig
dataMap
- a previouslly allocated data map in which to add the configuration properties© 2016 Wowza Media Systems, LLC. All rights reserved. Terms | Privacy | Trademarks | Legal