?
Solved

VIewPort under win32 GDI

Posted on 1998-11-05
1
Medium Priority
?
914 Views
Last Modified: 2011-04-14
i would i concrete example of how to use the
setViewPortOrg, SetViewPortExtEx under windows...

with the  SetMapMode ( hDC,MM_ISOTROPIC);

how to use it, and what are the step to modified it
0
Comment
Question by:ct_consultant
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 2

Accepted Solution

by:
trillo earned 100 total points
ID: 1177075
Hi
First of all you should know the relation between the logical coordinates and the device coordinates (pixels).
For example if you have a DC that is 20 x 20 pixels, and you would like it to be, lets say, 50 x 50 units (for your personal purpose) you should specify something like:

SetViewportExtEx (hDC, 20, 20, NULL);
SetWindowExtEx (hDC, 50, 50, NULL);

You can set or offset the origin either in the window (logical coordinates) or in the viewPort (device coordinates) or in both.

0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question