Thread: gettin a movie screencap

  1. #1
    Android geek@02's Avatar
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    470

    gettin a movie screencap

    hi
    below i'm trying to get a movie screencap. but i get error no 259: "Driver cannot recognize the specified command parameter" error after the capture command returns. what i'm doing wrong here please?

    Code:
    int main(int argc, char* argv[])
    {
    	int err=0;
    	char errstr[256];
    
    	//open and play the video
    	mciSendString("open messwiththebest.mpg alias mwtb",0,0,0);
    	mciSendString("play mwtb",0,0,0);
    	//pause the movie when user hits a key
    	getch();
    	mciSendString("pause mwtb",0,0,0);
    	//try to get a capture
    	err = mciSendString("capture mwtb E:\\capture.jpg",0,0,0); //error no: 259 is returned
    	mciGetErrorString(err,errstr,256);
    
    	return 0;
    }
    GameJolt: https://gamejolt.com/@KasunL
    Game Development Youtube:
    https://is.gd/XyhYoP
    Amateur IT Blog: http://everything-geeky.blogspot.com/



    (and, sorry for my amateur English)

  2. #2
    Registered User OnionKnight's Avatar
    Join Date
    Jan 2005
    Posts
    555
    http://msdn2.microsoft.com/en-us/library/ms707265.aspx
    It seems that you forgot to provide the last parameter.

  3. #3
    Android geek@02's Avatar
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    470
    i've tried the capture command with the 'wait' parameter. but it gives the same error msg.
    GameJolt: https://gamejolt.com/@KasunL
    Game Development Youtube:
    https://is.gd/XyhYoP
    Amateur IT Blog: http://everything-geeky.blogspot.com/



    (and, sorry for my amateur English)

  4. #4
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    I think you're missing the "as":
    Code:
    err = mciSendString("capture mwtb as E:\\capture.jpg wait",0,0,0);
    Samples here.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Why am I getting this error?
    By tallguy in forum C++ Programming
    Replies: 17
    Last Post: 04-02-2007, 03:34 PM
  2. movie being filmed in my town, some actors went to my restauratn
    By Silvercord in forum A Brief History of Cprogramming.com
    Replies: 4
    Last Post: 09-15-2003, 01:51 PM
  3. A cool French movie!!!
    By shaik786 in forum A Brief History of Cprogramming.com
    Replies: 9
    Last Post: 03-27-2003, 03:45 PM
  4. Memento movie
    By WayTooHigh in forum A Brief History of Cprogramming.com
    Replies: 9
    Last Post: 09-07-2001, 01:00 PM