| 125 | === Video orientation support === |
| 126 | |
| 127 | To send video in the proper orientation (i.e. head always up regardless of the device orientation), application needs to do the following: |
| 128 | |
| 129 | 1. Setup the device to get orientation change notification (by calling the API {{{UIDevice.beginGeneratingDeviceOrientationNotifications}}} and add a callback to receive {{{UIDeviceOrientationDidChangeNotification}}}). |
| 130 | 2. Inside the callback, call PJSUA API {{{pjsua_vid_dev_set_orient()}}} to set the video device to the correct orientation. |
| 131 | |
| 132 | For sample usage, please refer to [https://trac.pjsip.org/repos/changeset/5118#file4 ipjsua sample app]. Ticket #1861 explains this feature in detail. |