Platforms to show: All Mac Windows Linux Cross-Platform

Back to WindowsQOSMBS class.

WindowsQOSMBS.AddSocketToFlow(Socket as Integer, DestAddr as string, DestPort as Integer, TrafficType as Integer, Flags as Integer, byref FlowId as UInt32) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Adds a socket to a flow.

Socket: Identifies the socket that the application will use to flow traffic.
DestAddr: The destination IP address to which the application will send traffic. DestAddr and DestPort are optional if the socket is already connected. If this parameter is specified, the remote IP address and port must match those used in the socket's connect call.
If the socket is not connected, this parameter must be specified. If the socket is already connected, this parameter does not need to be specified. In this case, if the parameter is still specified, the destination host and port must match what was specified during the socket connect call.
Since, under TCP, the socket connect call can be delayed, AddSocketToFlow can be called before a connection is established, passing in the remote system's IP address and port number in the DestAddr parameter.
DestPort: The port for the connection.
TrafficType: A QOSTrafficType* constant that specifies the type of traffic for which this flow will be used.
Flags: Optional flag values. Can be QOSNonAdaptiveFlow.
FlowID: Receives a flow identifier. On input, this value must be 0. On output, the buffer contains a flow identifier if the call succeeds.
If a socket is being added to an existing flow, this parameter will be the identifier of that flow.
An application can make use of this parameter if multiple sockets used can share the same QoS flow properties. The QoS subsystem, then does not have to incur the overhead of provisioning new flows for subsequent sockets with the same properties. Note that only non-adaptive flows can have multiple sockets attached to an existing flow.
A FlowID is an unsigned 32-bit integer.

Lasterror is set.

The use of IPv4/v6 mixed addresses is not supported in qWAVE. The address specified by the DestAddr parameter must be either IPv4 or IPv6.
If there is a requirement for network experiments over a specific network interface, the socket must be bound to that particular interface. Otherwise the most appropriate interface for the experiment, as indicated by the network stack, is assigned by the qWAVE subsystem.
Network traffic associated with this flow is not affected by making this call alone. For example, packet prioritization does not occur immediately.
There are two categories of applications that use this function: adaptive and non-adaptive. An adaptive application makes use of notifications and information in the FlowFundamentals for adapting to network changes such as congestion. The qWAVE service uses Link Layer Topology Discovery (LLTD) QoS extensions for adaptive flows which can be present on the destination device.
After calling this function adaptive A/V applications should call the SetFlowRate function to affect network traffic.
A non-adaptive application either does not adapt to changing network characteristics or is sending traffic to an endpoint that does not support adaptive capabilities as indicated by ERROR_NOT_SUPPORTED.
Non-adaptive applications, or adaptive applications making non-adaptive flows, should call this function with the QOSNonAdaptiveFlow flag. After calling this function A/V applications should call the setOutgoingDSCPValue, setOutgoingRate or setTrafficType function with a Operation. They do not need to be called unless shaping is desired.

See also:

Some examples using this method:

WindowsQOSMBS.AddSocketToFlow(Socket as Integer, TrafficType as Integer, Flags as Integer, byref FlowId as UInt32) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Adds a socket to a flow.

Socket: Identifies the socket that the application will use to flow traffic.
DestAddr: The destination IP address to which the application will send traffic. DestAddr and DestPort are optional if the socket is already connected. If this parameter is specified, the remote IP address and port must match those used in the socket's connect call.
If the socket is not connected, this parameter must be specified. If the socket is already connected, this parameter does not need to be specified. In this case, if the parameter is still specified, the destination host and port must match what was specified during the socket connect call.
Since, under TCP, the socket connect call can be delayed, AddSocketToFlow can be called before a connection is established, passing in the remote system's IP address and port number in the DestAddr parameter.
DestPort: The port for the connection.
TrafficType: A QOSTrafficType* constant that specifies the type of traffic for which this flow will be used.
Flags: Optional flag values. Can be QOSNonAdaptiveFlow.
FlowID: Receives a flow identifier. On input, this value must be 0. On output, the buffer contains a flow identifier if the call succeeds.
If a socket is being added to an existing flow, this parameter will be the identifier of that flow.
An application can make use of this parameter if multiple sockets used can share the same QoS flow properties. The QoS subsystem, then does not have to incur the overhead of provisioning new flows for subsequent sockets with the same properties. Note that only non-adaptive flows can have multiple sockets attached to an existing flow.
A FlowID is an unsigned 32-bit integer.

Lasterror is set.

The use of IPv4/v6 mixed addresses is not supported in qWAVE. The address specified by the DestAddr parameter must be either IPv4 or IPv6.
If there is a requirement for network experiments over a specific network interface, the socket must be bound to that particular interface. Otherwise the most appropriate interface for the experiment, as indicated by the network stack, is assigned by the qWAVE subsystem.
Network traffic associated with this flow is not affected by making this call alone. For example, packet prioritization does not occur immediately.
There are two categories of applications that use this function: adaptive and non-adaptive. An adaptive application makes use of notifications and information in the FlowFundamentals for adapting to network changes such as congestion. The qWAVE service uses Link Layer Topology Discovery (LLTD) QoS extensions for adaptive flows which can be present on the destination device.
After calling this function adaptive A/V applications should call the SetFlowRate function to affect network traffic.
A non-adaptive application either does not adapt to changing network characteristics or is sending traffic to an endpoint that does not support adaptive capabilities as indicated by ERROR_NOT_SUPPORTED.
Non-adaptive applications, or adaptive applications making non-adaptive flows, should call this function with the QOSNonAdaptiveFlow flag. After calling this function A/V applications should call the setOutgoingDSCPValue, setOutgoingRate or setTrafficType function with a Operation. They do not need to be called unless shaping is desired.

See also:

WindowsQOSMBS.Constructor

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
This function initializes the QOS subsystem.

On success Handle property is not zero.
Lasterror is set.

Every process intending to use qWAVE must first call Constructor.
If a machine enters a power save mode that interrupts connectivity such as sleep or standby, existing and active network experiments such as QOSStartTrackingClient must be reinitiated. This recreation of the flow mirrors the cleanup and creation activities also necessary for existing sockets. A new handle must be created, and the flow must be recreated and readmitted.

WindowsQOSMBS.getFlowFundamentals(FlowID as Integer, byref BottleneckBandwidthSet as boolean, byref BottleneckBandwidth as UInt64, byref AvailableBandwidthSet as boolean, byref AvailableBandwidth as UInt64, byref RTTSet as boolean, byref RTT as UInt32, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Queries flow fundamentals.

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.
Flags: Optional, can be QOSQueryFlowFresh.
BottleneckBandwidthSet: This Boolean value is set to true if the BottleneckBandwidth field contains a value.
BottleneckBandwidth: Indicates the maximum end-to-end link capacity between the source and sink device, in bits.
AvailableBandwidthSet: Set to true if the AvailableBandwidth field contains a value.
AvailableBandwidth: Indicates how much bandwidth is available for submitting traffic on the end-to-end network path between the source and sink device, in bits.
RTTSet: Set to true if the RTT field contains a value.
RTT: Measures the round-trip time between the source and sink device, in microseconds.

Lasterror is set. Returns true on success or false on failure.

WindowsQOSMBS.getOutgoingRate(FlowID as Integer, byref Bandwidth as UInt64, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Queries flow rate.

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.
Bandwidth: will contain a UINT64 value that indicates the flow rate specified when requesting the contract, in bits per second.
Flags: Optional, can be QOSQueryFlowFresh.
Lasterror is set. Returns true on success or false on failure.

WindowsQOSMBS.getPacketPriority(FlowID as Integer, byref ConformantDSCPValue as Integer, byref NonConformantDSCPValue as Integer, byref ConformantL2Value as Integer, byref NonConformantL2Value as Integer, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Queries packet priorities.

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.
Flags: Optional, can be QOSQueryFlowFresh.

ConformantDSCPValue: Differential Services Code Point (DSCP) mark used for flow traffic that conforms to the specified flow rate.
NonConformantDSCPValue: DSCP marking used for flow traffic that exceeds the specified flow rate. Non-conformant DSCP values are only applicable only if value is QOSUseNonConformantMarkings.
ConformantL2Value: Layer-2 (L2) tag used for flow traffic that conforms to the specified flow rate. L2 tags will not be added to packets if the end-to-end path between source and sink does not support them.
NonConformantL2Value: L2 tag used for flow traffic that exceeds the specified flow rate. Non-conformant L2 values are only applicable if value is QOSUseNonConformantMarkings.

Lasterror is set. Returns true on success or false on failure.

WindowsQOSMBS.RemoveAllSocketsFromFlow(FlowID as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
The RemoveSocketFromFlow function notifies the QOS subsystem that a previously added flow has been terminated by the application, and that the subsystem must update its internal information accordingly.

FlowId: A flow identifier. A QOS_FLOWID is an unsigned 32-bit integer.

Lasterror is set. Returns true on success or false on failure.
The plugin closes all flows in destructor.

Some examples using this method:

WindowsQOSMBS.RemoveSocketFromFlow(socketHandle as Integer, FlowID as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
The RemoveSocketFromFlow function notifies the QOS subsystem that a previously added flow has been terminated by the application, and that the subsystem must update its internal information accordingly.

Socket: Socket to be removed from the flow.
Only flows created with the QOSNonAdaptiveFlow flag may have multiple sockets added to the same flow. By passing the Socket parameter in this call, each socket can be removed individually. If the Socket parameter is not passed, the entire flow will be destroyed. If only one socket was attached to the flow, passing this socket as a parameter to this function and passing 0 as a socket are equivalent calls.
FlowId: A flow identifier. A QOS_FLOWID is an unsigned 32-bit integer.

Lasterror is set. Returns true on success or false on failure.
The plugin closes all flows in destructor.

WindowsQOSMBS.setOutgoingDSCPValue(FlowID as Integer, OutgoingDSCPValue as Integer, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Sets the outgoing DSCP value.

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.

Lasterror is set. Returns true on success or false on failure.

If StartTrackingClient has not already been called, calling QOSSetFlow will cause the QOS subsystem to perform the following.

  • Discover whether the end-to-end network path supports prioritization.
  • Track end-to-end network characteristics by way of network experiments. These experiments do not place any noteworthy stress on the network.

WindowsQOSMBS.setOutgoingRate(FlowID as Integer, Bandwidth as UInt64, ShapingBehavior as Integer, Reason as Integer, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Sets a new outgoing rate.

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.
Bandwidth: The rate at which data should be sent, in units of bits per second.
Note Traffic on the network is measured at the IP level, and not at the application level. The rate that is specified should account for the IP and protocol headers.
ShapingBehavior: A shaping constant that defines the shaping behavior of the flow.
Reason: A QOSFlowRate* constant that indicates the reason for a flow rate change.
Lasterror is set. Returns true on success or false on failure.

If StartTrackingClient has not already been called, calling QOSSetFlow will cause the QOS subsystem to perform the following.

  • Discover whether the end-to-end network path supports prioritization.
  • Track end-to-end network characteristics by way of network experiments. These experiments do not place any noteworthy stress on the network.#

Some examples using this method:

WindowsQOSMBS.setTrafficType(FlowID as Integer, TrafficType as Integer, Flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Sets the type of traffic

FlowID: A flow identifier. A flow id is an unsigned 32-bit integer.
TrafficType: One of the traffic type constants.
Lasterror is set. Returns true on success or false on failure.

If StartTrackingClient has not already been called, calling QOSSetFlow will cause the QOS subsystem to perform the following.

  • Discover whether the end-to-end network path supports prioritization.
  • Track end-to-end network characteristics by way of network experiments. These experiments do not place any noteworthy stress on the network.#

WindowsQOSMBS.StartTrackingClient(DestAddr as string, flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
The StartTrackingClient function notifies the QOS subsystem of the existence of a new client.

Calling this function increases the likelihood that the QOS subsystem will have gathered sufficient information on the network path to assist when calling QOSSetFlow to set the flow.
Note This call is not required to add a flow with the QOSAddSocketToFlow function although it is highly recommended. Not calling this function may require network experiments to be started during the QOSSetFlow call and can result in QOSSetFlow failing with ERROR_NETWORK_BUSY on initial use.

DestAddr: The IP address of the client device. Clients are identified by their IP address and address family. Any port number specified in the sockaddr structure will be ignored.
Flags: Reserved for future use. Must be set to 0.

On receipt of a QOSStartTrackingClient call the QoS subsystem begins gathering information about the client such as the QoS capabilities and available bandwidth on the end-to-end path.
An application should call this function as soon as it becomes aware of a client device that may need QoS flow. For example this function should be called when a media player device first connects to a media server application.
Network experiments performed by QOSStartTrackingClient do not introduce noteworthy load on the network even if no stream is started for a long period of time. The qWAVE service dynamically adjusts experiment traffic based on QoS subsystem activity.
Link Layer Topology Discovery (LLTD) must be implemented on the sink PC or device for this function to work.

Lasterror is set. Returns true on success or false on failure.

WindowsQOSMBS.StopTrackingClient(DestAddr as string, flags as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Network MBS Win Plugin 13.5 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
The StopTrackingClient function notifies the QoS subsystem to stop tracking a client that has previously used the StartTrackingClient function.

If a flow is currently in progress, this function will not affect it.

DestAddr: The IP address of the client device. Clients are identified by their IP address and address family. A port number is not required and will be ignored.
Flags: Reserved for future use.

Lasterror is set. Returns true on success or false on failure.

The items on this page are in the following plugins: MBS Win Plugin.


The biggest plugin in space...