|
Yes i do all that things, and it doesnt work, but if i do not redefine any window procedure it works ok. If you can send for my any example, I will be grateful.
|
|
|
|
|
Hello Mr Neliocc,
I have forwarded the sample source code to your voldem........@yahoo.com email address.
[OT] By the Way, you seems to be a big fan of Harry Potter
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
|
|
|
|
|
http://www.codeproject.com/dotnet/ManifestInjection.asp
http://www.codeproject.com/w2k/makexp.asp
http://www.codeproject.com/useritems/ManifestMacro.asp
http://www.codeproject.com/cpp/xpstylemfc.asp
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
can anybody help me about this?thanks
detail:i get CImageList using SHGetFileInfo(),and how i get the icon index from the CImageList just by a file's extension(not full file name)
thanks
|
|
|
|
|
Does this search help?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
hehe ,let me see tomorow,tonight is too late (in asia)
|
|
|
|
|
|
I tried replacing the toolbar in my application with a 24 bit color toolbar bitmap. Since I edited the original toolbar bitmap image the buttons are all in the right place, however, saving the image as a 24 bit bitmap makes it look (in the application) hideous.
Is there any way to simply increase the resolution of the toolbar bitmap as it is rendered in the application ? (from 4 bit to 8 bit color ?)
"One of the Georges," said Psmith, "I forget which, once said that a
certain number of hours' sleep a day--I cannot recall for the moment how
many--made a man something, which for the time being has slipped my
memory."
|
|
|
|
|
|
Hi people ,
I´m working on an application that must draw some graphics using OpenGL. The aproach I´m using is to
initialize the window ,to set graphics mode and to set render context for OpenGL at the mainthread < InitInstance() > and then call a thread that must keep rendering frames until the end of the program.
well... I noticed that everithing works fine at the main thread ( including GL´s drawing calls)but when I make the same calls inside the thread , they have no efect on the window.
I can´t understand , because all the variables I use inside the thread are global.
Can you help me ?
Ps: 1) I created the thread using CreateThread.
2) My project is a simple win32 application => WinMain , InitInstance , Createwindow , winProc , etc...
|
|
|
|
|
You can only update the window from the thread that created it, so you'll have to create the window inside the thread that's going to be doing the OpenGL rendering.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
I do this in one of my OpenGL window classes as well.
First you must/should do the following when:
registering the window class:
- add CS_OWNDC | CS_HREDRAW | CS_VREDRAW styles
- set hbrBackground to NULL
creating the window:
- add WS_CLIPCHILDREN | WS_CLIPSIBLINGS styles.
using the window:
- handle WM_ERASEBKGND and return true
- handle WM_WINDOWPOSCHANGED when !(flags & SWP_NOSIZE) to update the viewport
There can be any number of things wrong.
A couple of the more common are:
- the DC and RC must stay current to the rendering thread while rendering (i.e. the app thread can't use the DC/RC without some syncing with the render thread). generally you get the DC right after the window is created, get an RC for the DC, and keep hold of both until the window is destroyed.
- because the window is created by the app thread it gets the WM_PAINT msg. at some point before you return (true) you should call ::ValidateRect() to clear the WM_PAINT msg. if you don't call this, and return false, the default paint handler will paint with the background brush.
...cmk
Save the whales - collect the whole set
|
|
|
|
|
The Problem was that I needed to make a current rendering context inside the thread:->.
I created a window for the aplication , Initialized OpenGL on the aplication , and created a rendering context inside the thread.
It works fine now , and I´m geting 150 frames /second !!!!
|
|
|
|
|
My program suddenly stops working when it hits the third cout statement in my program. Has this ever happened to anyone before? Any solutions?
|
|
|
|
|
|
int main()
{
int numerator, denominator;
cout<<"--Reducing Fractions Program--\n";
cout<<endl;
="" numerator="" entry
="" cout<<"enter="" the="" numerator:="" ";
="" cin="">>numerator;
//denominator entry
cout<<"Enter the Denominator: ";
cin>>denominator;
cout<<"Starting Reduce\n";
-------------------------------------------------
I am using the iostream library
I get an abort before the line: cout<<"Starting Reduce\n";
|
|
|
|
|
Anonymous wrote:
I get an abort before the line: cout<<"Starting Reduce\n";
If that statement is removed, does the error persist?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
I figured it out. Thanks Guys.
|
|
|
|
|
How about sharing it with the rest of us?
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
There is no problem with the code check out the range of numerator and denominator ur providing.
|
|
|
|
|
The numerator and denominator were within range, but the debugger was stopping the program from working propperly.
|
|
|
|
|
Hi,
I want to do something like this, but not sure what the behavior will be:
<br />
class A<br />
{<br />
virtual void Init(int width, int height) = 0;<br />
};<br />
class B<br />
{<br />
virtual void Init(int width = 640, int height = 480);<br />
};<br />
class C<br />
{<br />
virtual void Init(int width = 800, int height = 600);<br />
};<br />
Does this mean if I say:
<br />
B *var1 = new B();<br />
A *pvar1 = &myB;<br />
pvar1->Init();
pvar1->Init(320,240);
This will call the correct function?
|
|
|
|
|
The easiest way to answer this type of question is to set a breakpoint within each Init() method and see how/when they are called.
"Ideas are a dime a dozen. People who put them into action are priceless." - Unknown
|
|
|
|
|
I assume that B derives from A. In that case, it will call the correct function (the one in B).
Default parameters are only significant at the calling point. If you don't provide parameters, the compiler puts them in for you. So pvar1->Init() will get compiled as pvar1->Init(640, 480); and will call B's implementation.
Regards
Senthil
_____________________________
My Blog | My Articles | WinMacro
|
|
|
|
|