Changelog
welcome to the hotmic changelog, where we post the versions of the different applications and what was changed let us know if you have questions! nov 3, 2024 android sdk version 1 9 6 updates added device idto new reactionpubnub message this should resolve the issue of reactions not reflecting in ios when reacted from android update instructions to update to this version, make sure that your build gradle(app) includes the following dependency implementation 'io hotmic player\ hotmic android sdk 1 9 6' july 19, 2024 ios sdk version 8 0 0 developer preview note this is a preview release, feedback is welcome updates added hmpollobserving protocol to observe poll data for powering a custom polls interface added hmparticipantobserving protocol to observe participant data for powering a custom people interface updated dependencies here is more detail on each of those additions poll observing to be notified of poll events as they occur, you can implement the hmmediaplayerpollobserving protocol doing so will suppress the provided poll interface, allowing you to build your own interface hmmediaplayer pollobserver = self when polls are fetched initially, the following function is called func pollsfetched( polls \[hmpoll]) { // persist the polls } when a poll is created, the following function is called func pollcreated( poll hmpoll) { // insert the poll } when a poll is updated, the following function is called func pollupdated( poll hmpoll) { // update the poll } when a poll is deleted, the following function is called func polldeleted( poll hmpoll) { // delete the poll } submit poll response to respond to a poll from your custom poll interface, call the following function hmmediaplayer submitpollresponse(pollid poll id, optionid optionid) { result in switch result { case success(let success) // check if success case failure(let error) // handle error } } participant observing to be notified when the participants changes, you can implement the hmmediaplayerparticipantobserving protocol doing so will suppress the provided people interface, allowing you to build your own interface hmmediaplayer participantobserver = self each time the participants are changed, the following function is called func updateparticipants(host hmparticipant, cohosts \[hmparticipant], guests \[hmparticipant], waiting \[hmparticipant], room \[hmparticipant]) { // update the participants } update instructions to update to this version, run pod update hotmicmediaplayer may 31, 2024 ios sdk version 7 0 0 developer preview note this is a preview release, feedback is welcome updates updated dependencies resolved an issue where people, tips, and polls sheets did not appear update instructions to update to this version, run pod update hotmicmediaplayer may 29, 2024 android sdk version 1 9 1 alpha1 updates target/compile sdk version upgraded to android 34 (from 33) using the android x library exoplayer in place of the deprecated com google version support for vertical video if using custom player, nothing will show on top of the player, including the player control overlay or countdown timer, for both vertical and 16 9 videos update instructions to update to this version, make sure that your build gradle(app) includes the following dependency implementation 'io hotmic player\ hotmic android sdk 1 9 1 alpha1' may 20, 2024 ios sdk version 7 0 0 developer preview note this is a preview release, feedback is welcome features added support for full screen portrait video orientation replaced updatepollsconfiguration(isavailable\ hasunansweredpolls ) with updatepollsconfiguration (isavailable\ unansweredpollscount ) replaced playerviewcontrollerchatconfiguration( ) with playerviewcontroller( viewcontrollerforcontext ) and playerviewcontrollerchathandler( ) removed chathandlerdidtapshowpeople( ) , chathandlerdidtapshowpolls( ) , and chathandlerdidtapshowtipping( ) added close() , minimizetopipifsupported() , showpeopleifavailable() , showpollsifavailable() , and showtipoptionsifavailable() to hmplayerviewcontroller added prefersvideocontrolshidden parameter to initializeplayerviewcontroller(streamid\ delegate\ supportsminimizingtopip ) replaced playerviewcontroller( playerforassetat ) with playerviewcontroller( playerfororientation ) added loadsource(url ) , displayimageoverlay(url ) , removeimageoverlay() , displaycountdown(date\ imageoverlayurl ) , and removecountdown() to hmplayer update instructions to update to this version, run pod update hotmicmediaplayer march 7, 2024 ios sdk version 6 0 0 features custom content improvements you can now replace the view area below the player with your own content, completely customizable to you this brings out of beta our feature from 5 1 0 added the ability to get data to populate the custom content area with chat information more details are in the docs with the most relevant section changes listed below more information when the player screen will display chat content, the following function is called allowing you to provide a custom chat handler and view controller to display provide nilif you'd like to use the default hotmic chat service and ui note the handler and view controller can be the same instance of your view controller if it conforms to hmchathandler func playerviewcontrollerchatconfiguration( viewcontroller hmplayerviewcontroller) > hmplayerviewcontroller chatconfiguration { return init(handler nil, viewcontroller nil) } chat handler the hmchathandlerprotocol defines functions you implement if you'd like to provide a custom view controller for chat while utilizing the hotmic chat service your implementation needs to store a reference to an hmchathandlerdelegateand call its functions to get information and inform the delegate when various events occur store the delegate in a weak optional variable to call its functions in the future func setdelegate( delegate hmchathandlerdelegate) { self delegate = delegate } store the host id and use it to indicate when a chat was sent by the host func sethostid( id string) { self hostid = id } update the configuration of the people feature make it accessible in the interface if available the number of people is provided, allowing you to display this in the interface, for example as a badge on the button func updatepeopleconfiguration(isavailable bool, count int) { peoplebutton ishidden = !isavailable peoplebutton badge = count } update the configuration of the polls feature make it accessible in the interface if available the state of unanswered polls is provided, allowing you to display an indicator in the interface, for example as an "unread" badge on the button func updatepollsconfiguration(isavailable bool, hasunansweredpolls bool) { pollsbutton ishidden = !isavailable pollsbutton unreadbadge ishidden = !hasunansweredpolls } update the configuration of the tipping feature make it accessible in the interface if available func updatetippingconfiguration(isavailable bool) { tippingbutton ishidden = !isavailable } update the top insets of your interface to avoid underlapping other interface elements func updatetopcontentinset( topinset cgfloat) { tableview\ contentinset top = topinset } make the chat input toolbar visible func displaychatinputtoolbar() becomefirstresponder() } dismiss the chat input toolbar func dismisschatinputtoolbar() { resignfirstresponder() } dismiss the keyboard if it is visible func dismisschatinputtoolbar() { inputaccessoryview? textfield resignfirstresponder() } handle the backlog of chats and tips to display them in your interface func handlebacklog(chats \[hmchat], tips \[hmtip]) { // update data source tableview\ reloaddata() } handle new chats, tips, and reactions to insert them into your interface this function is called periodically to give you the opportunity to handle the pending items return true if handled or false if not if not handled, the same items will be provided in the next invocation func handlepending(chats \[hmchat], tips \[hmtip], reactions \[hmchatreaction]) > bool { if !chats isempty || !tips isempty { // update data source tableview\ insertrows(at newindexpaths, with automatic) } if !reactions isempty { // update data source, update cell contents, update cell height } return true } remove a chat by id func handledeletedchat(id string) { // update data source tableview\ deleterows(at indexpath], with automatic) } remove a tip by id func handledeletedtip(id string) { // update data source tableview\ deleterows(at indexpath], with automatic) } remove a reaction by chat id, user id, and type func handledeletedreaction(chatid string, userid string, type hmchatreactiontype) { // update data source, update cell contents, update cell height } chat handler delegate the hmchathandlerdelegateprotocol defines functions your hmchathandlerimplementation calls to get information and inform hotmic when various events occur asks the delegate if the handler can display the chat input toolbar override var canbecomefirstresponder bool { delegate? chathandlercandisplaychatinputtoolbar(self) ?? false } asks the delegate if the currently authenticated user can moderate another user if delegate? chathandler(self, canmoderateuser userid) == true { // display options to block user from chat/tip and delete chat/tip } asks the delegate if the currently authenticated user can make another user a moderator if delegate? chathandler(self, canmakeusermoderator userid) == true { // display option to make user moderator } inform the delegate the handler invoked send chat delegate? chathandler(self, didtapsendchat text) inform the delegate the handler invoked add reaction delegate? chathandler(self, didtapaddreaction reactiontype, to chat id) inform the delegate the handler invoked remove reaction delegate? chathandler(self, didtapremovereaction reactiontype, from chat id) inform the delegate the handler invoked make user moderator delegate? chathandler(self, didtapmakeusermoderator userid) inform the delegate the handler invoked report chat delegate? chathandler(self, didtapreportchat chat) inform the delegate the handler invoked report tip delegate? chathandler(self, didtapreporttip tip) inform the delegate the handler invoked block user from chat delegate? chathandler(self, didtapblockuserfromchat chat) inform the delegate the handler invoked block user from tip delegate? chathandler(self, didtapblockuserfromtip tip) inform the delegate the handler invoked delete chat delegate? chathandler(self, didtapdeletechat chat) inform the delegate the handler invoked delete tip delegate? chathandler(self, didtapdeletetip tip) inform the delegate the handler invoked view a user's profile delegate? chathandler(self, didtapviewuserprofile userid) inform the delegate the handler invoked the people feature delegate? chathandlerdidtapshowpeople(self) inform the delegate the handler invoked the polls feature delegate? chathandlerdidtapshowpolls(self) inform the delegate the handler invoked the tipping feature delegate? chathandlerdidtapshowtipping(self) get chat reactions you can fetch reaction details for a specific chat use this to create an interface that lists people who reacted and which reaction they chose if you provide a custom view controller for chat hmmediaplayer getreactions(chatid chat id) { result in switch result { case success(let reactions) // display the list of reactions case failure(let error) // handle error } } breaking changes replaced playerviewcontroller( , viewcontrollerforcontext ) with playerviewcontrollerchatconfiguration( ) removed hmplayerviewcontroller customcontentcontext how custom content works we have supported custom content in previous versions, allowing you to implement your own video player to display stream content, in lieu of the hotmic default video player the code to do that looked something like this func playerviewcontroller( viewcontroller hmplayerviewcontroller, playerforassetat url url) > hmplayer? { return nil } you can continue to use custom video players as before, but now you can now further customize the content on the player screen you can now edit the section below the player, which typically includes chat content to do this, you can provide your own view controller, which means all the content in the view controller (effectively everything below the player) is customized the following function is called allowing you to provide a custom view controller to display in a given context return nil if you'd like to use the default view controller func playerviewcontroller( viewcontroller hmplayerviewcontroller, viewcontrollerforcontext context hmplayerviewcontroller customcontentcontext) > uiviewcontroller? { return nil } at this time, this feature should be considered beta you can add your own content to the view controller, but don't have information from hotmic (yet) to reproduce all existing features in an upcoming release, you will get an interface to interact with data from the stream this includes chats, reactions, and more this will allow you to build a completely alternate interface with all the features of the default hotmic provided view controller update instructions to update to this version, run pod update hotmicmediaplayer feb 23, 2024 android sdk version 1 9 0 alpha1 features custom content improvements (beta) you can now replace the view area below the player with your own content, completely customizable to you how custom content works we have supported custom content in previous versions, allowing you to implement your own video player to display stream content, in lieu of the hotmic default video player this still exists now, the sdk will allow you to replace the default chat fragment shown under the player with your own custom fragment for this, while calling the player, provide a custom fragment using the api setchatfragment a sample builder call will look something like val builder = hotmicplayer builder(this) setuicallback(playeruihandler) setstreamid(streamid) enabletroubleshootoption() credential("d34seae5 121b 4r3b a55c 2d7s34mbfwe3") setchatfragment(dummychatfragment()) show(r id player fragment container) at this time, this feature should be considered alpha you can add your own fragment, but don't have information from hotmic (yet) to reproduce all existing features in an upcoming release, you will get an interface to interact with data from the stream this includes chats, reactions, and more this will allow you to build a completely alternate interface with all the features of the default hotmic provided fragment upcoming releases will complete the ability to customize this view, including allowing you to have you own layout, and specify where the player, chat and other fragments should be shown for example, you can choose to remove the chat fragment or place the player fragment in a separate area of the screen or shrink the chat layout and introduce a new custom panel in between we will expose the chat apis and related data, using which, you can build and style your own custom chat fragment update instructions to update to this version, make sure that your build gradle(app) includes the following dependency implementation 'io hotmic player\ hotmic android sdk 1 9 0 alpha1' february 14, 2024 ios sdk version 5 1 0 features custom content improvements (beta) you can now replace the view area below the player with your own content, completely customizable to you improvement now built from xcode 15 (supporting ios 17) you may need to use xcode 15 to use this version of the sdk several dependencies were updated to improve performance and reduce bugs how custom content works we have supported custom content in previous versions, allowing you to implement your own video player to display stream content, in lieu of the hotmic default video player the code to do that looked something like this func playerviewcontroller( viewcontroller hmplayerviewcontroller, playerforassetat url url) > hmplayer? { return nil } you can continue to use custom video players as before, but now you can now further customize the content on the player screen you can now edit the section below the player, which typically includes chat content to do this, you can provide your own view controller, which means all the content in the view controller (effectively everything below the player) is customized the following function is called allowing you to provide a custom view controller to display in a given context return nil if you'd like to use the default view controller func playerviewcontroller( viewcontroller hmplayerviewcontroller, viewcontrollerforcontext context hmplayerviewcontroller customcontentcontext) > uiviewcontroller? { return nil } at this time, this feature should be considered beta you can add your own content to the view controller, but don't have information from hotmic (yet) to reproduce all existing features in an upcoming release, you will get an interface to interact with data from the stream this includes chats, reactions, and more this will allow you to build a completely alternate interface with all the features of the default hotmic provided view controller update instructions to update to this version, run pod update hotmicmediaplayer