Skip to content

Commit

Permalink
Let resolution change notification call eventHappened
Browse files Browse the repository at this point in the history
  • Loading branch information
mekya committed Jul 16, 2024
1 parent 9d4ee9c commit 9cfa341
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions WebRTCiOSSDK/api/AntMediaClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1021,8 +1021,13 @@ open class AntMediaClient: NSObject, AntMediaClientProtocol {
message: broadcastObject ?? [:]
)
}
else if definition == RESOLUTION_CHANGE_INFO_COMMAND {
let streamId = message[STREAM_ID] as? String ?? "";
self.delegate?.eventHappened(streamId: streamId, eventType: definition, payload: message)
}

break;

case ROOM_INFORMATION_COMMAND:
if let updatedStreamsInTheRoom = message[STREAMS] as? [String] {
//check that there is a new stream exists
Expand Down Expand Up @@ -1054,6 +1059,9 @@ open class AntMediaClient: NSObject, AntMediaClientProtocol {

}

break;
case "pong":
//dont do anything
break;
case "error":
guard let definition = message["definition"] as? String else {
Expand Down
1 change: 1 addition & 0 deletions WebRTCiOSSDK/api/AntMediaClientProtocol.swift
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ let EVENT_TYPE_CAM_TURNED_OFF = "CAM_TURNED_OFF";
let EVENT_TYPE_CAM_TURNED_ON = "CAM_TURNED_ON";
let GET_BROADCAST_OBJECT_COMMAND = "getBroadcastObject"
let BROADCAST_OBJECT_NOTIFICATION = "broadcastObject"
public let RESOLUTION_CHANGE_INFO_COMMAND = "resolutionChangeInfo"
public let EVENT_TYPE_TRACK_LIST_UPDATED = "TRACK_LIST_UPDATED"
public let EVENT_TYPE_VIDEO_TRACK_ASSIGNMENT_LIST = "VIDEO_TRACK_ASSIGNMENT_LIST";

Expand Down

0 comments on commit 9cfa341

Please sign in to comment.