Click here to Skip to main content
15,891,372 members
Articles / Multimedia / DirectX

Perfect Panning in 3D (Zoom Too)

Rate me:
Please Sign up or sign in to vote.
4.91/5 (12 votes)
12 Oct 2009CPOL5 min read 74.4K   3.3K   32  
How to pan in perspective views so the point under the cursor stays under the cursor.
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by NewView.rc
//

#define IDS_APP_TITLE            103

#define IDR_MAINFRAME            128
#define IDD_VIEWING_DIALOG        102
#define IDD_ABOUTBOX            103
#define IDM_ABOUT                104
#define IDM_EXIT                105
#define IDI_VIEWING                107
#define IDI_SMALL                108
#define IDC_NEWVIEW                109
#define IDC_MYICON                2
#ifndef IDC_STATIC
#define IDC_STATIC                -1
#endif
// Next default values for new objects
// 
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS

#define _APS_NO_MFC                    130
#define _APS_NEXT_RESOURCE_VALUE    129
#define _APS_NEXT_COMMAND_VALUE        32771
#define _APS_NEXT_CONTROL_VALUE        1000
#define _APS_NEXT_SYMED_VALUE        110
#endif
#endif

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Founder Spatial Freedom
Australia Australia
Software engineer, mechanical engineer, electronics engineer, inventor, manager, entrepreneur, husband, father, friend.
B.Sc. B.E.(Hons) M.Eng.Sc.
Some things I've done
- Invented the Spaceball(R)/1983 and Astroid(R)/2002 3D mice
- Patents: 3D mouse, data compression, acoustic transducer
- Wrote animation software in mid 1980s for TV commercials
- Wrote a basic CAD drawing program in 1980s
- Lived in Boston, Massachusetts for 11 years
- Architected and managed full custom ASIC chip
- Reviewed bionic eye technology for investment purposes
- Product development on CPR aid for heart attacks
- Developed an electronic sports whistle
- Was actually stranded on a deserted Pacific island
- Software: lots - embedded, device driver, applications
Some things I want to do
- Develop more cool hardware/software products
- Solve the 3D mouse software barrier to proliferate 3D mice
- Help bring 3D to the masses
- Help others

Comments and Discussions