What I did:
I have created and installed the opencv module plugin in the Kurento Media Server. I am setting the constraints as width - 640 and frameRate - 30. Now I am getting the around 35 frames approx inside the Opencv plugin process method.
After that, I have added face detection filter in the process method. Now I am getting around 20 to 25 frames. It took some time for the face detection process. So the remote streaming gets some delay.
Now I can able to skip frames in the plugin side by doing some counter logic.
What I want:
1) But I want to skip the frames in the JS client side. Is it possible to skip the frames from the client JS?
2) By default, is any End to End FPS calculation available in the KMS?
3) Is it possible to send the grayscale frame to the KMS plugin from the JS Client? If yes, How do I change to coloured frame to grayscale frame in JS client?
1) But I want to skip the frames in the JS client side. Is it possible to skip the frames from the client JS?
Not that I'm aware of. You can mirror the video and things like that with CSS transformations, but I don't think you can skip frames in the client.
You can, however, limit the framerate that the client receives by instantiating a capsfilter
that limits that framerate. You'd need to put that filter before the endpoint that returns the video to the client.
2) By default, is any End to End FPS calculation available in the KMS?
Not in KMS. You can check that in the incoming/outgoing streams from the client. You want to look for the RTCMediaStreamTrackStats. Here is a SO answer about the stats API in RTCPeerConnection.
3) Is it possible to send the grayscale frame to the KMS plugin from the JS Client? If yes, How do I change to coloured frame to grayscale frame in JS client?
Maybe you can try this code. I've just checked the demo, but I suppose you can get that media stream and send it to KMS without much trouble. Check also the Media Capture Extensions.