Free Training


C Language  |  CSS  |  MainFrame  |  VBScript  |  PHP  |  XML  |  C++ Tutorials  |  Ajax  |  JavaScript  |  CSS3  |  UML  |  jQuery  |  Microsoft AJAX

VB.NET 2005 Tutorials

 
Home Tutorials VB.NET 2005
 

Building Graphical Interface elements

 

Building Graphical Interface elements - Page 3

Page 3 of 3


Working with images


Visual Basic .NET comes with lots of features that makes working with images a real pleasure. We shall quickly see why this is so!

We deal with images in GDI+ that fall into three broad categories:

Two-dimensional (2-D) vector graphics
Imaging
Typography



2-D Vector Graphics

Two-dimensional vector graphics are concerned with primitives; such as lines, curves, and figures; that are specified by sets of points on a coordinate system. For example, a straight line is specified by its two endpoints, and a rectangle is specified by a point giving the location of its upper-left corner and a pair of numbers giving its width and height. A simple path is specified by an array of points that are connected by straight lines. A Bezier spline is a sophisticated curve specified by four control points.


Imaging

There are some kinds of pictures that are difficult or impossible to display with the techniques of vector graphics. For example, the pictures on toolbar buttons and the pictures that appear as icons are difficult to specify as collections of lines and curves. High-resolution digital photographs are even more difficult to create with vector techniques. Images of this type are stored as bitmaps, which are arrays of numbers that represent the colors of individual dots on the screen. GDI+ provides the System.Drawing.Bitmap class for displaying, manipulating, and saving bitmaps. GDI+ provides extensive support for this complex task.


Drawing images on forms and buttons can be achieved using the drawImage() method of the Graphics Object.


To a new project in the Visual Basic Express add the following lines of code to the form.


This output generated by this program is given below


Click here for the Sample Code




Programming in graphics with Visual Basic is a separate area of interest and this is huge. Visual Basic 2005 is loaded with a rich collection of Classes and objects that perform a variety of operations. Programming games applications is both fun and a challenge to the pursuer where you will be solving several challenges. So explore and you will undoubtedly have a rich and enthralling experience.




First Page: Building Graphical Interface elements


Read Next: Visual Studio Adding Controls to Windows Form



 

 

Comments



Post Your Comment:

Members Please Login
Your Name:*
e-mail ID:(required for notification)*
Image Verification: 
 
 Subscribe    

Weekly Offers

Sponsored Links