Click here to Skip to main content
15,885,546 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am making a video stegnaography project in which i got the clone of the selected frames from the video and then i have to replace these embedded frames with the real frames in the video...i have used the avifile library so far and i use the cut function in the avi library...the cut function actually cut the a video stream of the given lenght but i have to cut on frame at a time ....the function returns a intptr ...i tried to make a bitmap from that intptr by using over loaded bitmap constructor...i am using c#.....

C#
p = editableStream.Cut(156, 157); Bitmap b = new Bitmap(300, 300, 400, PixelFormat.Format24bppRgb, p);


when i try to save the bitmap then it show the exception ...A generic error occurred in GDI+.

C#
b.Save(@"D:\MCS _2\New folder\aaaa.jpg", ImageFormat.Jpeg);
Posted
Updated 18-Feb-14 3:20am
v3
Comments
Sergey Alexandrovich Kryukov 18-Feb-14 18:30pm    
Why from IntPtr? What are you trying to achieve with that?
—SA
Adi5555 19-Feb-14 7:10am    
i have to replace the frame of the video....so first i have to cut the real frame and then paste the other frame...the code i am using return a intptr so i have to make the bitmap from that bitmap
Sergey Alexandrovich Kryukov 19-Feb-14 10:37am    
Well, I am not sure that the code you are using is the code you should be using...
—SA
Adi5555 19-Feb-14 10:50am    
@sergey plz telme which code is better for it...i havnt find any other code yet
Sergey Alexandrovich Kryukov 19-Feb-14 11:56am    
Not sure. If I knew exactly what to use, I would already advise you. Sorry...
—SA

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