|
VS locks up on me as a stated.
Visual Studio itself "locks up" during compiling.
If i go to the task manager it states Visual sutdio is not responding . however it is using about 99% of the processor.
I guesse the compiler is in a loop but i dont understand how those three lines of code could put it in a loop.
As well as i stated. It will work perfect in a console only app.
Any type of windowed app.. MFC or just old win32 API will lock the COMPILER up.
Im not doing any floating point ops.
Basicly if i use the app wiard and make a generic MFC dialog app and i insert this code anywhere in the premade code. . InitDialog(), OnButton() where ever i put this code will lock VS up.
Im running an AMD 500 on XP home editition.. VS Enterprise. .with service packs.
|
|
|
|
|
i did try this on another machine. AMD 900. .
and it works fine. ..
guesse it something with the hardware. . or maybe i got to reinstall.
|
|
|
|
|
I want to do something (minimize to tray) when a user hits my window's standard normal Minimize button on the title bar of the window. How do I trap this minimize box and call my tray functions instead?
-Jason
nirgle.bitdevil.com
|
|
|
|
|
|
My prog seems to get that right off the bat after loading. I assume that's normal? Any quick way to ensure that it's the user that clicked the minimize box and not some internal MFC or Windows thing?
-Jason
nirgle.bitdevil.com
|
|
|
|
|
maybe in your first ShowWindow you are passing SW_MINIMIZE as the nCmdShow parameter.
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|
|
Hello everybody!
Who knows, what codes are generated with multimedia and the Internet keys of keyboards?
If for different keyboards they various where to take the utility for viewing the codes generated by the keyboard!
Best regards,
Eugene Pustovoyt
Sonork ID 100.10002:Yaumen
|
|
|
|
|
Hi,
Is there any way to get the name of the font file for a given font along with its attributes like bold, italic, etc.?
Thanks,
Krishnan
|
|
|
|
|
GetTextMetrics often gives you all you need to know about a font. Why would you want to know a fonts filename?
/Mike
|
|
|
|
|
Mike Nordell wrote:
GetTextMetrics often gives you all you need to know about a font. Why would you want to know a fonts filename?
I have requirement to get the list of all fonts I am using in my application so that I can bundle them with my software.
|
|
|
|
|
I'm working on a project that will allow a trace window in release mode, by extending IOStream functionality. Rather than have people have to learn my new modifiers, etc., I am also writing macros to replace TRACE for different circumstances. I want to have a trace window per file, and a global one. I also want a variable watch window, so I can send a variable in such a way that instead of scrolling off in the trace window, it stays visible.
My problem is I'd like to define a macro so I can do something like
VARTRACE(myVariable);
and have the macro pass both the variable and it's name to the stream. Is there a way I can pass the name of the variable given to the macro as an argument ?
Thanks.
Christian
After all, there's nothing wrong with an elite as long as I'm allowed to be part of it!! - Mike Burston Oct 23, 2001
Sonork ID 100.10002:MeanManOzI live in Bob's HungOut now
|
|
|
|
|
I may be totally off base here, but I think you are looking for the ## token pasting operator.
---
It may be that your sole purpose in life is simply to serve as a warning to others.
|
|
|
|
|
Christian Graus wrote:
Is there a way I can pass the name of the variable given to the macro as an argument ?
The # preprocessor operator quotes a macro argument:
#define VARTRACE(var) YourTraceFunc ( #var, var ) So VARTRACE(myVariable) expands to YourTraceFunc( "myVariable", myVariable );
--Mike--
My really out-of-date homepage
Buffy's on. Gotta go, bye!
Sonork - 100.10414 AcidHelm
Big fan of Alyson Hannigan.
|
|
|
|
|
Thanks, mate - just what I needed.
Christian
After all, there's nothing wrong with an elite as long as I'm allowed to be part of it!! - Mike Burston Oct 23, 2001
Sonork ID 100.10002:MeanManOzI live in Bob's HungOut now
|
|
|
|
|
I suspect this should be really easy - it's just how!!!!
I have a single selection list control, in report view. The list may or may not fill the control. I want to ensure that one row in the list is always selected, ie the user cannot clickin the white space under the last item in the list, and deselect.
I had hoped there was just a style or flag I could set for this, but cannot find one. I have also looked at handling the NM_CLICK reflected message, but it appears this is too late.
Any help or ideas about how to deal with this would be appreciated!!!!
|
|
|
|
|
Just a guess, but handling the LVN_ITEMCHANGING, LVN_ITEMCHANGED, and LVM_SETITEMSTATE notification messages might be a good place to start. (See the Help for how to handle these notification messages.)
Peace!
-=- James.
|
|
|
|
|
I'd like to know what I need to be able to do the
following. I mean can I do all these using plain Win 32 API and a little MFC or
do I need to use some DirectX SDK or OpenGL 2d/3d/whatever?
- Read a PNG file
- Apply a circular mask, using the contrast between
the light subject and the dark background to size and position the mask - Apply a rectangular mask similarly, possibly
rotating the subject to be perpendicular to the canvas - Apply a feather to mask
- Black fill the background leaving the subject alone
- Write back the PNG to disk
I been asked by my boss whether all this is possible
and having no previous experience in graphics I am stuck. If it involves having
to download some complicated SDKs then I'll probably tell my boss that it is not
feasible. But if it can be done using MFC/API and maybe just a little bit of
Open GL I can make some serious attempts
Any help offered is immensely respected.
Regards
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|
|
Hiya Nish.
Nish [BusterBoy] wrote:
some DirectX SDK or OpenGL 2d/3d/whatever?
DirectX has DirectDraw, but OpenGL is all 3D AFAIK.
Nish [BusterBoy] wrote:
Read a PNG file
Easiest way is to use GDI+, but there are other ways around it if you need W95 support.
Nish [BusterBoy] wrote:
Apply a circular mask, using the contrast between
the light subject and the dark background to size and position the mask
Apply a rectangular mask similarly, possibly
rotating the subject to be perpendicular to the canvas
Apply a feather to mask
Black fill the background leaving the subject alone
This is all possible using Win32, your first step is to deal with a DIBSection so you have easy access to the bitmap data to start comparing light/darkness, etc. What the hell is a feather ?
You basically want to take a picture of something over a darker background, figure out it's position and draw a circle around it, then a rectangle ( rotating the image so that it's perpendicular ) and do a fill of the darker area ? Do you want to rotate in place, or to a bitmap of approproate size ?
The fill part is as easy as pie - step through the bits and any below a threshold get set to 0. The rest doesn't sound over hard, but it's probably of a jump off the deep end if it's your first ever graphics assignment. There is a class here on CP that loads and saves PNG from memory, and GDI+ does it also. Chris Maunder has a DIBSection class here, I am also writing one I could send you, it's simpler than his though. As for the rest, if you could provide some more details, and LMK if you intend on using GDI+ or not, I'd be happy to mail you some more detailed source code to get you started.
Christian
After all, there's nothing wrong with an elite as long as I'm allowed to be part of it!! - Mike Burston Oct 23, 2001
Sonork ID 100.10002:MeanManOzI live in Bob's HungOut now
|
|
|
|
|
Thanks Christian
I guess I'll need some help when I get started.
It's been a long time since I had to learn something totally new to me.
I'll start by checking out your GDI+ articles I guess.
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|
|
Nish [BusterBoy] wrote:
It's been a long time since I had to learn something totally new to me.
Cool. I had to write a paint package and I had *no* idea about PC grapihcs - it was a VERY bumpy ride ( two rewrites in my own time when I realised I'd taken the wrong track ), but I learned a LOT.
Nish [BusterBoy] wrote:
I'll start by checking out your GDI+ articles I guess.
If GDI+ is an option I suspect it will make a lot of this easier. If you could give me a better idea of what you're trying to do ( what is feathering for example, what sort of image are you dealing with, what's the purpose of all this ) then I might be able to help more specifically. If you like I can also send you the code for my next WDJ article, which was supposed to come out in Jan. It is a simple app that loads and saves images in different formats, but more to the point, it illustrates how to access the pixels directly in GDI+, which you'll need to do from the sound of it.
Christian
After all, there's nothing wrong with an elite as long as I'm allowed to be part of it!! - Mike Burston Oct 23, 2001
Sonork ID 100.10002:MeanManOzI live in Bob's HungOut now
|
|
|
|
|
Christian Graus wrote:
what is feathering for example
This is what I got from wepopedia:-
http://www.webopedia.com/TERM/f/feathering.html
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|
|
I see - a soften filter but only on the area we've decided is the edge. Easy stuff, done with a convolution matrix. I'll send you some code - can I get your email address from your CP account details ?
Christian
After all, there's nothing wrong with an elite as long as I'm allowed to be part of it!! - Mike Burston Oct 23, 2001
Sonork ID 100.10002:MeanManOzI live in Bob's HungOut now
|
|
|
|
|
Christian Graus wrote:
can I get your email address from your CP account details ?
Yes, you can.
I've also send you a mail with my email details.
My email fullname is "void main".
Please don't delete the mail thinking it is spam
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|
|
how do you do pseudocode for: while, do-while, and for loops. Ive been to a bunch of sites and a couple said there was no way to do a for loop and the while and do-while loops didnt seem very good. Is there an official pseudocode site i could go to?
-Raffi
|
|
|
|
|
I didnt think pseudocode had any set standards or formats
Nish
Sonork ID 100.9786 voidmain
www.busterboy.org
If you don't find me on CP, I'll be at Bob's HungOut
|
|
|
|