[jitsi-dev] A Jitsi change set.


#1

Hi,
I have made a number of patches that optimise Jitsi when video calling on Windows. They will not function on other platforms because I have changed JawtRenderer and not updated the other implementations not due to an inherent incompatibility. I may have caused other breaking issues on other platforms of which I am unaware.

NOTE: These patches are not ready for submission to the trunk, they are merely being provided so that I am sharing my progress. If anyone requires a binary version please mail me privately.

The overall impact of the changes is dramatically improved video calling e.g. 720p is viable and looks great with high frame rate (with suitable hardware!) :slight_smile:

An overview of the changes is as follows:-

Video pipeline
The pipeline has been optimised significantly. Frames now pass directly as AVFrames from the source to their destination the renderer and or the JNIEncoder. Scaling and colour conversion is handled by the target rather than being placed in the pipeline.

For large frame sizes and frame rates this significantly reduces the amount of memory bandwidth being used to copy data back and forth.

Currently the JAWTRenerer has been updated to handle the conversion of pix formats inside the native code. This leaves the opportunity to HW accelerate this operation.

The performance improvements from these changes are significant. Previously at least one of my cores was being fully occupied just rendering the video!

H.264 Settings & New Profiles
A number of new settings have been added or enhanced. The changes are as follows:-

* Profiles - The following profiles have been added:-

1. The high 420 profile called "high".

2. The high 422 profile called "high422"

* Preset - It is now possible to set the H.264 encoding preset. This has a dramatic impact on encoding quality and clearly also on CPU utilisation.

1. Ultrafast (Default)

2. Superfast

3. Faster

4. Fast

5. Medium - Good results with this profile.

6. Slow - Good results with this profile.

7. Slower

8. Very Slow

* Tuning Profile - Experimental probably shouldn't even be there :). Just so I can test disabling zerolatency.

* Thread Count - It is now possible to adjust the number of threads. A good number seems to be the number of physical cores you have. But it is not quite that simple. Makes a huge difference when combined with choosing the right preset.

New Call Full Screen Mode
I've implemented a fullscreen mode which is handled by the call dialog rather than the OneToOneCallPanel. Theoretically it should be cross platform and should work for conference calls but neither of these cases are tested.

The none full screen UI is essentially the same as fullscreen as I have optimised the window layout to use the maximum space available for the peer video.

In full screen mode after 5 seconds the UI overlay will hide completely, giving you a chromeless display of the video call.

Local Video Display
The local video now displays overlayed on the remote video. There is still an issue where local video is sent but remote video is not as in this case the local video is not present.

Regards,
James
James M. Martin - Director / Chief Solutions Architect - ESP Technologies Limited
[cid:image001.jpg@01CDDF30.BB2E2440]
ESP Technologies Limited is registered with the Registrar of Companies, Dublin - No. 367933
Registered Address: Auburn House, Ard na Greine, Ennis, Co. Clare, Ireland

This email is intended for the addressees named above and any other use is prohibited. It may contain confidential information. If you received this email in error, please contact the sender by return email. ESP does not accept legal responsibility for the contents of this message if it has reached you via the Internet, as Internet communications are not secure. Any opinions expressed are those of the author and are not necessarily endorsed by ESP. All ESP communications are scanned for malware & virus infection using the latest anti-viral utilities.

Java-Jitsi-21122012.diff (64.2 KB)

Java-Libjitsi-21122012.diff (40.4 KB)

Native-jawtrenderer-21122012.diff (35.9 KB)

Native-jnffmpeg-21122012.diff (1.49 KB)