Is it possible to merge two or more videos in real-time like this?
DASH HTML5 video streaming already works by getting the player to load video in chunks that are usually about 10 seconds long.  You should be able to cook something up that gets the player to display your segment seamlessly, by giving it a DASH-like list of videos.

You might need to remux your video segments into .mp4, if some web browsers choke on the flv container format.  (assuming that's the container for f4v, which I've never seen before.)