How to stream partial content with ASP.NET MVC FileStreamResult

前端 未结 3 1177
感动是毒
感动是毒 2021-02-20 06:46

We\'re using a FileStreamResult to provide video data to a Silverlight MediaElement based video player:

public ActionResult Preview(Guid id) {
    return new Fil         


        
3条回答
  •  长发绾君心
    2021-02-20 07:03

    There is a project on CodePlex which gives this exact functionality.

    http://mediastreamingmvc.codeplex.com/

    Take a look. It was created specifically for this scenario where you want to have an action representing a request for a virtual resource and return partial content if so requested without requiring the developer to do much to support it (an Action Filter and choice of Result types.)

提交回复
热议问题