|
The code does not capture a video and I don't even know how you came to that conclusion. I would suggest you read the code and understand what is going on first. The code gets the current bitmap in the VMR renderer and ensures that it is in RGB24. pImage will end up as an array of RGBTRIPLEs that makes up the image. Note that he discards the bitmap header in GrabFrame() all you have is just the RGB24 data. If you want to create a HBITMAP with this, look up CreateDIBitmap on msdn.
|
|
|
|
|
Why are you posting here about a code guru article ? Code Guru should offer a place to post questions to the article author.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
|
OK, then he should ask in the forum for the article, if he wants to ask the author a question.
Or he should explain what he's doing in a more generic way, that doesn't reference the article, if he wants to ask for general help.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I posted this question on two forum "code project" and "code guru" because this article author posted the same .
aloha
|
|
|
|
|
Just because someone wrote an article does not mean they will read this forum on the day you happen to post a question. So, like I said, you need to either ask a generic question that does not refer to an article, or post the question in the forum for the article ( at the bottom of the article ) in order to generate an email that will alert the author, and then if the author is still supporting his articles, he will get back to you. So far, he probably doesn't even know that you asked a question.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I asked the author, but I don't know why doesn't reply so I posted on forum.If you are unpleasure, I'm sorry
aloha
|
|
|
|
|
To be frank, I really don't care, except that I'd like to see you get the help you need. If the author is not replying, then I'd try rewording the question so that it doesn't refer to the article and post it here again.
I'm sorry if you thought I was complaining, I was trying to direct you to where you'd be mostly likely to get the help you're wanting.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I'm sorry, I don't think you are complaining, thank for your direction
what's your nickname? I want to exchange on Yahoo Messenger
aloha
|
|
|
|
|
I don't have any messenger installed, sorry.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Can you help me to solve this problem?
aloha
|
|
|
|
|
_tcscpy and lstrcpy, both implement the same function, which one should I use if I want to copy a string in my project?
|
|
|
|
|
_UNICODE is not defined for this.
LPTSTR lstrcpy( LPTSTR lpString1,
LPTSTR lpString2
);
TCHAR is used to represent unicode strings.
So when you are working with unicode you should prefer TCHAR to LPTSTR
_TCHAR * _tcscpy(_TCHAR * to, const _TCHAR * from)
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
_AnShUmAn_ wrote: _UNICODE is not defined for this.
LPTSTR lstrcpy( LPTSTR lpString1,
LPTSTR lpString2
);
could you see LPTSTR lstrcpy( LPTSTR lpString1, ).. T in middle
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
_tcscpy is a CRT function while lstrcpy is a windows native function. It probably does not make a difference which you use, but _tcscpy is probably better for portability reasons.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
cgsp_wei wrote: _tcscpy
use C runtime Libarary
cgsp_wei wrote: lstrcpy
use Kernel32.dll..
IMHO, it better to use Window Based api!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
cgsp_wei wrote: _tcscpy and lstrcpy, both implement the same function, which one should I use if I want to copy a string in my project?
The lstrcpy function has an undefined behavior if source and destination buffers overlap.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
So does _tcscpy.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
PJ Arends wrote: So does _tcscpy.
No idea,not used yet.
LPTSTR lstrcpy(LPTSTR lpString1,LPTSTR lpString2);
Using lstrcpy function incorrectly can compromise the security of your application. The first argument, lpString1, must be large enough to hold lpString2 and the closing '\0', otherwise a buffer overrun may occur. Buffer overruns may lead to a denial of service attack against the application if an access violation occurs. In the worst case, a buffer overrun may allow an attacker to inject executable code into your process, especially if lpString1 is a stack-based buffer.
Mostly application getting crashed or Access violations during such behaviour's.
ref. MSDN 2003
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
Your username is broken, please fix the closing </font> tag.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
PJ Arends wrote: Your username is broken, please fix the closing tag.
Thank's, I have tried same earliar but name has limit of 50 characters due to which 't>' is missing.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
A_Laxman wrote: Thank's, I have tried same earliar but name has limit of 50 characters due to which 't>' is missing.
what about <font face="Monotype Corsiva" >A_Laxman</font>!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
Have you checked size of that ??? if size not set of the font then text not display's properly.
Any way thanks for your suggestion.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
|
You will have to store the index of the selected item somewhere . Say in a file or a registry, or in a variable in your code if the application keeps on running.
The next time you open your dialog set the item to which the index points to.
Correction::|Here I assumed that you are having a fixed number of items....
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
-- modified at 4:44 Saturday 17th June, 2006
|
|
|
|