Click here to Skip to main content
15,867,835 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hey there,

I would like to know how to read out the first frame of a video and save it in a bitmap without previously saving it as an image file. I have already looked at many solutions on the Internet, but they all based on saving it as a file, but I would like a solution that looks something like this:

public static class ThumbnailGrabber
{
    public static Bitmap GetVideoThumbnail(string filePath)
    {
        ...
        return bitmap;
    }
}

Do you have any ideas?

I have heard of the NReco video converter, but I have no idea how to handle it and how to read out the thumbnail.

Looking forward for a reply.

LG

What I have tried:

I have only researched so far and have not found what somehow corresponds to my expectation.
Posted
Updated 7-May-18 8:48am
v2
Comments
[no name] 7-May-18 14:29pm    
Your requirement that "no saving" is involved is unjustified and therefore illogical.
Member 13814072 7-May-18 14:42pm    
Could you explain that? I just mean that I do not want to save this image before in an external file. I want to put it directly into a bitmap so it's just located in the RAM
Richard MacCutchan 7-May-18 15:32pm    
And then what are you planning to do with it?
Member 13814072 7-May-18 15:40pm    
I want to display it on my imageButton which you have to press to play this video.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900