new to graphics
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: new to graphics

  1. #1
    Join Date
    Mar 2009
    Posts
    1

    new to graphics

    I've done some C++ console, and some JAVA and of course VB.

    now I want to get started with some simple apps with graphics, I want to be able to able to create apps that don't have the default window with minimize, maximize, ect. I want to be able to define everything myself.

    could anyone recommend some info, thanx

    also, any recommendations for free compliers? I have been using Codeblocks and MS visual C++ express
    Last edited by action_owl; March 9th, 2009 at 10:41 PM.

  2. #2
    Join Date
    Mar 2004
    Location
    KL, Malaysia
    Posts
    63

    Re: new to graphics

    Quote Originally Posted by action_owl View Post
    I've done some C++ console, and some JAVA and of course VB.

    now I want to get started with some simple apps with graphics, I want to be able to able to create apps that don't have the default window with minimize, maximize, ect. I want to be able to define everything myself.
    To go full screen on Win32 project, do this:

    Code:
    		DEVMODE dmScreenSettings;					// Device Mode
    		memset(&dmScreenSettings,0,sizeof(dmScreenSettings));	// Makes Sure Memory's Cleared
    		dmScreenSettings.dmSize=sizeof(dmScreenSettings);		// Size Of The Devmode Structure
    		dmScreenSettings.dmPelsWidth	= 800;				// Selected Screen Width
    		dmScreenSettings.dmPelsHeight	= 60;				// Selected Screen Height
    		dmScreenSettings.dmBitsPerPel	= 16;				// Selected Bits Per Pixel
    		dmScreenSettings.dmFields=DM_BITSPERPEL|DM_PELSWIDTH|DM_PELSHEIGHT;
    
    		// Try To Set Selected Mode And Get Results.  NOTE: CDS_FULLSCREEN Gets Rid Of Start Bar.
    		if (ChangeDisplaySettings(&dmScreenSettings,CDS_FULLSCREEN)!=DISP_CHANGE_SUCCESSFUL)
    		{
    			// If The Mode Fails, Offer Two Options.  Quit Or Use Windowed Mode.
    			if (MessageBox(NULL,"The Requested Fullscreen Mode Is Not Supported By\nYour Video Card. Use Windowed Mode Instead?","GL",MB_YESNO|MB_ICONEXCLAMATION)==IDYES)
    			{
                                    MessageBox(NULL,"Program Will Run in Windows Mode.","ERROR",MB_OK|MB_ICONSTOP);
    			}
    			else
    			{
    				MessageBox(NULL,"Program Will Now Close.","ERROR",MB_OK|MB_ICONSTOP);
    			}
    		}
    Hope this helps.

    Kevin Choong
    Last edited by ckweius; March 18th, 2009 at 09:22 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center