Class WebRTC

All Implemented Interfaces:
Serializable, Iterable<Component>, IEventSink, IEventSource, IFeedbackContributor, IConverterLocator, IMetadataContext<Serializable,Component>, IHeaderContributor, IRequestableComponent, IHierarchical<Component>, IClusterable

public abstract class WebRTC extends WebMarkupContainer
A WebRTC component to create a video conference based on SimpleWebRTC. http://www.html5rocks.com/en/tutorials/webrtc/basics/
https://github.com/andyet/signalmaster
https://github.com/HenrikJoreteg/SimpleWebRTC
https://github.com/HenrikJoreteg/webrtc.js
Author:
Tobias Soloschenko
See Also:
  • Constructor Details

  • Method Details

    • renderHead

      public void renderHead(IHeaderResponse response)
      Specified by:
      renderHead in interface IHeaderContributor
      Overrides:
      renderHead in class Component
    • getNoVideoResourceReference

      protected ResourceReference getNoVideoResourceReference()
      Gets the resource reference which is going to be shown if the access to the mic and the cam is not allowed by the user.
      Returns:
      the resource reference to be used if no access to mic and the cam is not allowed
    • getLocalVideo

      public abstract Video getLocalVideo()
      Gets the local video id of the video element which is going to display the local video recording
      Returns:
      the id of the local video
    • getRoomName

      public abstract String getRoomName()
      Gets the room name to which the users are joining
      Returns:
      the room name
    • getSocketIOUrl

      public abstract String getSocketIOUrl()
      Gets the url of the signal server based on socket.io. Important the URL must not contain a namespace like /socket.io at the end, because the signal server then never calls the connect event.
      Returns:
      the url of the socket io server
    • isDebug

      public Boolean isDebug()
      If the debug mode is enabled - this is causing the uncompressed version of the javascript files is going to be loaded
      Returns:
      if the debug mode is enabled
    • setDebug

      public void setDebug(Boolean debug)
      Sets the debug mode to be enabled - this is causing the uncompressed version of the javascript files is going to be loaded
      Parameters:
      debug - if the debug mode is enabled
    • getVolumeBars

      public Boolean getVolumeBars()
      If the volume bars are enabled or disabled
      Returns:
      if the volume bars are enabled or disabled
    • setVolumeBars

      public void setVolumeBars(Boolean volumeBars)
      Sets the volume bars to be enabled or disabled
      Parameters:
      volumeBars - if the volume bars are enabled or disabled
    • getFramesPerSeconds

      public Integer getFramesPerSeconds()
      Gets the frames per seconds which are going to be used for the videos
      Returns:
      the frames per seconds
    • setFramesPerSeconds

      public void setFramesPerSeconds(Integer framesPerSeconds)
      Sets the frames per seconds which are going to be used for the videos
      Parameters:
      framesPerSeconds - the frames per seconds as short
    • getMaxWidth

      public Integer getMaxWidth()
      Gets the max width of the videos - if the width is smaller less band width is used
      Returns:
      the max width of the videos
    • setMaxWidth

      public void setMaxWidth(Integer maxWidth)
      Sets the max width of the videos - if the width is smaller less band width is used
      Parameters:
      maxWidth - the max width the videos should be
    • getMaxHeight

      public Integer getMaxHeight()
      Gets the max height of the videos - if the height is smaller less band width is used
      Returns:
      the max height of the videos
    • setMaxHeight

      public void setMaxHeight(Integer maxHeight)
      Sets the max height of the videos - if the height is smaller less band width is used
      Parameters:
      maxHeight - the max height the videos should be
    • getErrorPage

      public Class<? extends Page> getErrorPage()
      Override this to provide an error page if video / audio is not available. If only audio is available getNoVideoResourceReference() is called and the image received by this method is shown.
      Returns:
      the page if video / audio is not available