Arachnid
asked on
How to save a single frame from a movie?
Not sure if this is possible or not....
i'm using the TMediaPlayer in my app to play movies (avi,mpeg).
is it possible to save a single frame from the movie playing ?
now i dont mean opening the file and grabbing a single frame since this will differ depending on movietype...
i was more interested in somehow saving the current frame shown in the assigned Tpanel.
i've tried to make the Canvas propery for Tpanel available but not really sure where to go from there... (was kinda expecting the "SaveToFile" functions to come with it... but since it didn't i'm kinda stuck)
/John
i'm using the TMediaPlayer in my app to play movies (avi,mpeg).
is it possible to save a single frame from the movie playing ?
now i dont mean opening the file and grabbing a single frame since this will differ depending on movietype...
i was more interested in somehow saving the current frame shown in the assigned Tpanel.
i've tried to make the Canvas propery for Tpanel available but not really sure where to go from there... (was kinda expecting the "SaveToFile" functions to come with it... but since it didn't i'm kinda stuck)
/John
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
http://home.t-online.de/home/Thomas.Schwobe/list11.htm
This code can give You any frame (Image) in an AVI file. You nead VFW.pas (about 180kB) and set Your Compiler to read from the "lib\delphi2" directory (Ole2 from delphi2) works fine for D4,5,6.
bullen
This code can give You any frame (Image) in an AVI file. You nead VFW.pas (about 180kB) and set Your Compiler to read from the "lib\delphi2" directory (Ole2 from delphi2) works fine for D4,5,6.
bullen
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
Accept gemarti's comment as answer
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
Thank you,
Russell
EE Cleanup Volunteer
I will leave a recommendation in the Cleanup topic area that this question is:
Accept gemarti's comment as answer
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
Thank you,
Russell
EE Cleanup Volunteer
Put an image, button and mediaplayer component on a form.
assign a movie to the media player and try this
procedure TForm1.Button1Click(Sender
begin
Image1.Canvas.CopyRect(Ima
Image1.Picture.SaveToFile(
end;