I ns t i t ut eofManage me nt & Te c hni c alSt udi e s
MACHINE DRAWING & COMPUTER GRAPHI CS
I
500
BACHELORI NMECHANI CALENGI NEERI NG www. i mt s i n s t i t u t e . c o m
IMTS (ISO 9001-2008 Internationally Certified)
MACHINE DRAWING & COMPUTER GRAPHICS
MACHINE DRAWING & COMPUTER GRAPHICS FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS CONTENTS: UNIT-1
01-30
MACHINE DESING AND MANUFACTURING CONDITIONS IN DESIGN Definition.Classifications of Machine Design.,General Considerations in Machine Design,General Procedure in Machine Design. Introduction.Manufacturing Processes. Casting. Casting Design ,Forging. Forging Design,Mechanical Working of Metals,Hot,Working,Hot Working Processes,Cold Working. ,Cold Working Processes,Interchangeability.Important Terms Used in Limit System. Fits ,Types of Fits,Basis of Limit System,Indian Standard System of Limits and Fits,Calculation of Fundamental Deviation for Shafts,Calculation of Fundamental Deviation for Holes,Surface Roughness and its Measurement,Preferred Numbers.
UNIT-II
31-39
SECTIONAL VIEWS Introductions ,Need for sectioning ,Hatching ,Inclination of hatching lines ,Spacing hatching lines ,Hatching of larger areas ,Hatching of adjacent parts ,Sketch and of ful1 section, ,Half sections ,Types of half section,Partial or local sections, ,Revolved or super imposed, ,Removed sections ,Offset sections.
UNIT – III
40-59
LIMITS, FITS AND TOLERANCES Introduction Definition of various term used in limits Hole basis system, Shaft basis system ,Types of fits, fits Shaft and Hole –Terminology Clearance ,classification of fits, FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
Selection of fit and applications ,Types of Tolerances,Form and position,Indication of tolerance and fits on the drawing
UNIT-IV
60-78
KEYS AND SURFACE FINISH Introduction ,Classification of keys,Sunk key,Saddle key,
Flat
key,Gib
head
key,Feather key,Peg key,Single head key,Double head key,Spline shaft,Woodruff key,Pin key,Cone key,Definitions,Nominal surface,Roughness,Waviness,Lay,Sampling length,Production method and surface quality,Symbol for lay,Indication of surface roughness for various machining operations,Surface texture symbol with all the characteristics,System of Indication surface texture symbols on drawing
UNIT-V
79-102
SCREW THREADS AND THREADED FASTENERS Introduction,Nomenclature of
Screw threads,Basic profiles or forms of screw
threads,Left hand thread,Right hand thread,Internal thread,External thread,V-Thread – whit worth thread,Square thread,Designation of threads,Bolt and nut,Drawing of hexagonal bolt and nut,Drawing of square head bolts,Riveted head,Types of rivet heads
UNIT VI
103-120
A Survey of Computer Graphics - Overview of Graphics Systems: Video Display Devices – Raster-Scan Systems – Random-Scan Systems – Input Devices – Hard-Copy Devices
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
UNIT VII
121-145
Output Primitives: Points and Lines – Line Drawing Algorithms - Loading the Frame Buffer – Circle-Generating Algorithms – Ellipse-Generating Algorithms – Other Curves – Parallel Curve Algorithms – Pixel Addressing and Object Geometry – Filled-Area Primitives - Character Generation – Attributes of Output Primitives : Line Attributes – Curve Attributes – Color and Grayscale Levels – Area-Fill Attributes – Character Attributes – Antialiasing.
UNIT VIII
146-177
Two-Dimensional Geometric Transformations : Basic Transformations – Matrix Representations and Homogeneous Coordinates – Composite Transformations - Other Transformations – Two-Dimensional Viewing : The Viewing Pipeline – Viewing Coordinate Reference Frame – Windows-to-Viewport Coordinate Transformation – Clipping Operations – Point Clipping – Line Clipping: Cohen-Sutherland Line Clipping – Liang-Barsky Line Clipping – Polygon Clipping: Sutherland-Hodgeman Polygon Clipping – Weiler-Atherton Polygon Clipping – Curve Clipping – Text Clipping – Exterior Clipping.
UNIT IX
178-202
Three-Dimensional Concepts: Three-Dimensional Display Methods - Three-Dimensional Geometric and Modeling Transformations: Translation – Rotation – Scaling – Other Transformations – Composite Transformations - Three-Dimensional Viewing: Viewing Pipeline – Viewing Coordinates – Projections – Clipping.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
UNIT X
203-231
Graphical User Interfaces and Interactive Input Methods: The User Dialogue – Input of Graphical Data – Input Functions – Interactive Picture – Construction Techniques. VisibleSurface Detection Methods: Classification of Visible-Surface Detection Algorithms – Back-Face Detection – Depth-Buffer Method. Basic Illumination Models - Color Models and Color Applications: Properties of Light – Standard Primaries and the Chromaticity Diagram – Intuitive Color Concepts – RBG Color Model – YIQ Color Model – CMY Color Model – HSV Color Model.
UNIT QUESTIONS
232-240
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT-I MACHINE DESIGN AND MANUFACTURING CONDITION IN DESIGN Definition
The subject Machine Design is the creation of new and better machines and improving the existing ones. A new or better machine is one which is more economical in the overall cost of production and operation. The process of design is a long and time consuming one. From the study of existing ideas, a new idea has to be conceived. The idea is then studied keeping in mind its commercial success and given shape and form in the form of drawings. In the preparation of these drawings, care must be taken of the availability of resources in money, in men and in materials required for the successful completion of the new idea into an actual reality. In designing a machine component, it is necessary to have a good knowledge of many subjects such as Mathematics, Engineering Mechanics, Strength of Materials, Theory of Machines, Workshop Processes and Engineering Drawing.
Classifications of Machine Design
The machine design may be classified as follows : 1. Adaptive design. In most cases, the designer’s work is concerned with adaptation of existing designs. This type of design needs no special knowledge or skill and can be attempted by designers of ordinary technical training. The designer only makes minor alternation or modification in the existing designs of the product.
2. Development design. This type of design needs considerable scientific training and design ability in order to modify the existing designs into a new idea by adopting a new material or different method of manufacture. In this case, though the designer starts from the existing design, but the final product may differ quite markedly from the original product.
3. New design. This type of design needs lot of research, technical ability and creative thinking. Only those designers who have personal qualities of a sufficiently high order can take up the work of a new design. The designs, depending upon the methods used, may be
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
1
MACHINE DRAWING & COMPUTER GRAPHICS
classified as follows :
(a) Rational design. This type of design depends upon mathematical formulae of principle of mechanics.
(b) Empirical design. This type of design depends upon empirical formulae based on the practice and past experience.
(c) Industrial design. This type of design depends upon the production aspects to manufacture any machine component in the industry.
(d) Optimum design. It is the best design for the given objective function under the specified constraints. It may be achieved by minimising the undesirable effects.
(e) System design. It is the design of any complex mechanical system like a motor car.
(f) Element design. It is the design of any element of the mechanical system like piston, crankshaft, connecting rod, etc.
(g) Computer aided design. This type of design depends upon the use of computer systems to assist in the creation, modification, analysis and optimisation of a design.
General Considerations in Machine Design
Following are the general considerations in designing a machine component :
1. Type of load and stresses caused by the load. The load, on a machine component, may act in several ways due to which the internal stresses are set up. The various types of load and stresses are discussed in chapters 4 and 5.
2. Motion of the parts or kinematics of the machine. The successful operation of any machine depends largely upon the simplest arrangement of the parts which will give the motion required. The motion of the parts may be :
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
2
MACHINE DRAWING & COMPUTER GRAPHICS
(a) Rectilinear motion which includes unidirectional and reciprocating motions. (b) Curvilinear motion which includes rotary, oscillatory and simple harmonic. (c) Constant velocity. (d) Constant or variable acceleration.
3. Selection of materials. It is essential that a designer should have a thorough knowledge of the properties of the materials and their behaviour under working conditions. Some of the important characteristics of materials are : strength, durability, flexibility, weight, resistance to heat and corrosion, ability to cast, welded or hardened, machinability, electrical conductivity, etc. The various types of engineering materials and their properties.
4. Form and size of the parts. The form and size are based on judgement. The smallest prac- ticable cross-section may be used, but it may be checked that the stresses induced in the designed cross-section are reasonably safe. In order to design any machine part for form and size, it is necessary to know the forces which the part must sustain. It is also important to anticipate any suddenly applied or impact load which may cause failure.
5. Frictional resistance and lubrication. There is always a loss of power due to frictional resistance and it should be noted that the friction of starting is higher than that of running friction. It is, therefore, essential that a careful attention must be given to the matter of lubrication of all surfaces which move in contact with others, whether in rotating, sliding, or rolling bearings.
6. Convenient and economical features. In designing, the operating features of the machine should be carefully studied. The starting, controlling and stopping levers should be located on the basis of convenient handling. The adjustment for wear must be provided employing the various take- up devices and arranging them so that the alignment of parts is preserved. If parts are to be changed for different products or replaced on account of wear or breakage, easy access should be provided and the necessity of removing other parts to accomplish this should be avoided if possible. The economical operation of a machine which is to be used for production, or for the processing of material should be studied, in order to learn whether it has the maximum capacity consistent with the production of good work.
7. Use of standard parts. The use of standard parts is closely related to cost, because the cost of standard
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
3
MACHINE DRAWING & COMPUTER GRAPHICS
4
or stock parts is only a fraction of the cost of similar parts made to order. The standard or stock parts should be used whenever possible parts for which patterns are already in existence such as gears, pulleys and bearings and parts which may be selected from regular shop stock such as screws, nuts and pins. Bolts and studs should be as few as possible to
Design considerations play important role in
the successful avoid the delay caused by changing production of machines. drills, reamers and taps and also to decrease the number of wrenches required.
8. Safety of operation. Some machines are dangerous to operate, especially those which are speeded up to insure production at a maximum rate. Therefore, any moving part of a machine which is within the zone of a worker is considered an accident hazard and may be the cause of an injury. It is, therefore, necessary that a designer should always provide safety devices for the safety of the operator. The safety appliances should in no way interfere with operation of the machine.
9. Workshop facilities. A design engineer should be familiar with the limitations of his employer’s workshop, in order to avoid the necessity of having work done in some other workshop. It is sometimes necessary to plan and supervise the workshop operations and to draft methods for casting, handling and machining special parts.
10. Number of machines to be manufactured. The number of articles or machines to be manu- factured affects the design in a number of ways. The engineering and shop costs which are called fixed charges or overhead expenses are distributed over the number of articles to be manufactured. If only a few articles are to be made, extra expenses are not justified unless the machine is large or of some special design. An order calling for small number of the product will not permit any undue expense in the workshop processes, so that the designer should restrict his specification to standard parts as much as possible.
11. Cost of construction. The cost of construction of an article is the most important consideration involved in design. In some cases, it is quite possible that the high cost of an article may immediately bar it from further considerations. If an article has been invented and tests of hand made samples have shown that it has commercial value, it is then possible to justify the expenditure of a considerable sum of money in the design and development of automatic machines to produce the article, especially if it can be sold in large numbers. The aim of design engineer under all conditions, should be to reduce the manufacturing cost to the minimum.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
12. Assembling. Every machine or structure must be assembled as a unit before it can function. Large units must often be assembled in the shop, tested and then taken to be transported to their place of service. The final location of any machine is important and the design engineer must anticipate the Car assembly line.exact location and the local facilities for erection.
1.4 General Procedure in Machine Design
In designing a machine component, there is no rigid rule. The problem may be attempted in several ways. However, the general procedure to solve a design problem is as follows :
1. Recognition of need. First of all, make a complete statement of the problem, indicating the need, aim or purpose for which the machine is to be designed.
2. Synthesis (Mechanisms). Select the possible mechanism or group of mechanisms which will give the desired motion.
3. Analysis of forces. Find the forces acting on each member of the machine and the energy transmitted by each member.
4. Material selection. Select the material best suited for each member of the machine.
5. Design of elements (Size and Stresses). Find the size of each member of the machine by considering the force acting on the member and the permissible stresses for the material used. It should be kept in mind that each member should not deflect or deform than the permissible limit.
6. Modification. Modify the size of the member to agree with Fig. 1.1. General procedure in Machine Design. the past experience and judgment to facilitate manufacture. The modification may also be necessary by consideration of manufacturing to reduce overall cost.
7. Detailed drawing. Draw the detailed drawing of each component and the assembly of
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
5
MACHINE DRAWING & COMPUTER GRAPHICS
6
the machine with complete specification for the manufacturing processes suggested.
8. Production. The component, as per the drawing, is manufactured in the workshop.
The
flow chart for the general procedure in machine design is shown in Fig. 1.1.
Manufacturing Considerations in Machine Design
introduction In the previous chapter, we have only discussed about the composition, properties and uses of various materials used in Mechanical Engineering. We shall now discuss in this chapter a few of the manufacturing processes, limits and fits, etc.
Manufacturing Processes
The knowledge of manufacturing processes is of great importance for a design engineer. The following are the various manufacturing processes used in Mechanical Engineering.
1. Primary shaping processes.
The processes used for the preliminary shaping of the machine component are known as primary shaping processes. The common operations used for this process are casting, forging, extruding, rolling, drawing, bending, shearing, spinning, powder metal forming, squeezing, etc.
2. Machining processes.
The processes used for giving final shape to the machine component, according to planned dimensions are known as machining processes. The common operations
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
used for this process are turning, planning, shaping, drilling, boring, reaming, sawing, broaching, milling, grinding, hobbing, etc.
3. Surface finishing processes.
The processes used to provide a good surface finish for the machine component are known as surface finishing processes. The common operations used for this process are polishing, buffing, honing, lapping, abrasive belt grinding, barrel tumbling, electroplating, superfinishing, sheradizing, etc.
4. Joining processes.
The processes used for joining machine components are known as joining processes. The common operations used for this process are welding, riveting, soldering, brazing, screw fastening, pressing, sintering, etc.
5. Processes effecting change in properties.
These processes are used to impart certain specific properties to the machine components so as to make them suitable for particular operations or uses. Such processes are heat treatment, hot-working, cold-working and shot peening. To discuss in detail all these processes is beyond the scope of this book, but a few of them which are important from the subject point of view will be discussed in the following pages.
Casting
It is one of the most important manufacturing process used in Mechanical Engineering. The castings are obtained by remelting of ingots* in a cupola or some other foundry furnace and
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
7
MACHINE DRAWING & COMPUTER GRAPHICS
then pouring this molten metal into metal or sand moulds. The various important casting processes are as follows:
1. Sand mould casting. The casting produced by pouring molten metal in sand mould is called sand mould casting. It is particularly used for parts of larger sizes.
2. Permanent mould casting. The casting produced by pouring molten metal in a metallic mould is called permanent mould casting. It is used for casting aluminium pistons, electric iron parts, cooking utensils, gears, etc. The permanent mould castings have the following advantages:
(a) It has more favourable fine grained structure.
(b) The dimensions may be obtained with close tolerances.
(c) The holes up to 6.35 mm diameter may be easily cast with metal cores.
3. Slush casting. It is a special application of permanent metal mould casting. This method is used for production of hollow castings without the use of cores.
4. Die casting. The casting produced by forcing molten metal under pressure into a permanent metal mould (known as die) is called die casting. A die is usually made in two halves and when closed it forms a cavity similar to the casting desired. One half of the die that remains stationary is known as cover die and the other movable half is called ejector die. The die casting method is mostly used for castings of non-ferrous metals of comparatively low fusion temperature. This process is cheaper and quicker than permanent or sand mould casting. Most of the automobile parts like fuel pump, carburettor bodies, Aluminium die casting component horn, heaters,
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
8
MACHINE DRAWING & COMPUTER GRAPHICS
wipers, brackets, steering wheels, hubs and crank cases are made with this process. Following are the advantages and disadvantages of die casting :
Advantages
(a) The production rate is high, ranging up to 700 castings per hour.
(b) It gives better surface smoothness.
(c) The dimensions may be obtained within tolerances.
(d) The die retains its trueness and life for longer periods. For example, the life of a die for zinc base castings is upto one million castings, for copper base alloys upto 75 000 castings and for aluminium base alloys upto 500 000 castings.
(e) It requires less floor area for equivalent production by other casting methods.
( f ) By die casting, thin and complex shapes can be easily produced.
( g ) The holes up to 0.8 mm can be cast.
Disadvantages
(a) The die casting units are costly.
(b) Only non-ferrous alloys are casted more economically.
(c) It requires special skill for maintenance and operation of a die casting machine.
5. Centrifugal casting. The casting produced by a process in which molten metal is poured and allowed to solidify while the mould is kept revolving, is known as centrifugal casting. The metal thus
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
9
MACHINE DRAWING & COMPUTER GRAPHICS
poured is subjected to centrifugal force due to which it flows in the mould cavities. This results in the production of high density castings with promoted directional solidification. The examples of centrifugal castings are pipes, cylinder liners and sleeves, rolls, bushes, bearings, gears, flywheels, gun barrels, piston rings, brake drums, etc.
Casting Design
An engineer must know how to design the castings so that they can effectively and efficiently render the desired service and can be produced easily and economically. In order to design a casting, the following factors must be taken into consideration :
1. The function to be performed by the casting, 2. Soundness of the casting, 3. Strength of the casting, 4. Ease in its production, 5. Consideration for safety, and 6. Economy in production.
In order to meet these requirements, a design engineer should have a thorough knowledge of production methods including pattern making, moulding, core making, melting and pouring, etc. The best designs will be achieved only when one is able to make a proper selection out of the various available methods. However, a few rules for designing castings are given below to serve as a guide:
1. The sharp corners and frequent use of fillets should be avoided in order to avoid concentration of stresses.
2. All sections in a casting should be designed of uniform thickness, as far as possible. If, however, variation is unavoidable, it should be done gradually.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
10
MACHINE DRAWING & COMPUTER GRAPHICS
3. An abrupt change of an extremely thick section into a very thin section should always be avoided.
4. The casting should be designed as simple as possible, but with a good appearance.
5. Large flat surfaces on the casting should be avoided because it is difficult to obtain true surfaces on large castings.
6. In designing a casting, the various allowances must be provided in making a pattern.
7. The ability to withstand contraction stresses of some members of the casting may be improved by providing the curved shapes e.g., the arms of pulleys and wheels.
8. The stiffening members such as webs and ribs used on a casting should be minimum possible in number, as they may give rise to various defects like hot tears and shrinkage, etc.
9. The casting should be designed in such a way that it will require a simpler pattern and its moulding is easier.
10. In order to design cores for casting, due consideration should be given to provide them adequate support in the mould.
11. The deep and narrow pockets in the casting should invariably be avoided to reduce cleaning costs. 12. The use of metal inserts in the casting should be kept minimum
13. The markings such as names or numbers, etc., should never be provided on vertical surfaces because they provide a hindrance in the withdrawl of pattern.
14. A tolerance of Âą 1.6 mm on small castings (below 300 mm) should be provided. In case more dimensional accuracy is desired, a tolerance of Âą 0.8 mm may be provided
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
11
MACHINE DRAWING & COMPUTER GRAPHICS
Forging
It is the process of heating a metal to a desired temperature in order to acquire sufficient plasticity, followed by operations like hammering, bending and pressing, etc. to give it a desired shape. The various forging processes are :
1. Smith forging or hand forging
2. Power forging,
3. Machine forging or upset forging, and
4. Drop forging or stamping
The smith or hand forging is done by means of hand tools and it is usually employed for small jobs. When the forging is done by means of power hammers, it is then known as power forging. It is used for medium size and large articles requiring very heavy blows. The machine forging is done by means of forging machines. The drop forging is carried out with the help of drop hammers and is particularly suitable for mass production of identical parts. The forging process has the following advantages :
1. It refines the structure of the metal.
2. It renders the metal stronger by setting the direction of grains.
3. It effects considerable saving in time, labour and material as compared to the production of a similar item by cutting from a solid stock and then shaping it.
4. The reasonable degree of accuracy may be obtained by forging.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
12
MACHINE DRAWING & COMPUTER GRAPHICS
13
5. The forgings may be welded.
It may be noted that wrought iron and various types of steels and steel alloys are the common raw material for forging work. Low carbon steels respond better to forging work than the high carbon steels. The common non-ferrous metals and alloys used in forging work are brass, bronze, copper, aluminium and magnesium alloys. The following table shows the temperature ranges for forging some common metals. Table 3.1. Temperature ranges for forging.
MATERIAL
FORGING TEMP.
MATERIAL
FORGING TEMP.
900-1300 Wrought iron
940-1180 Stainless steel
750-1300
Mild steel
Aluminium
and
750-1250
magnesium alloys
800-1150
COPPER,
350-500
Medium carbon steel
High
carbon
alloy steel
and
BRASS
600-950
AND BRONZE
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Forging Design
In designing a forging, the following points should always be considered. 1. The forged components should ultimately be able to achieve a radial flow of grains or fibres.
2. The forgings which are likely to carry flash, such as drop and press forgings, should preferably have the parting line in such a way that the same will divide them in two equal halves.
3. The parting line of a forging should lie, as far as possible, in one plane.
4. Sufficient draft on surfaces should be provided to facilitate easy removal of forgings from dies.
5. The sharp corners should always be avoided in order to prevent concentration of stress and to facilitate ease in forging.
6. The pockets and recesses in forgings should be minimum in order to avoid increased die wear.
7. The ribs should not be high and thin.
8. Too thin sections should be avoided to facilitate easy flow of metal.
Mechanical Working of Metals The mechanical working of metals is defined as an intentional deformation of metals plastically under the action of externally applied forces.
The mechanical working of metal is described as hot working and cold working depending upon whether the metal is worked above or below the recrystallisation temperature. The metal is subjected to mechanical working for the following purposes :
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
14
MACHINE DRAWING & COMPUTER GRAPHICS
1. To reduce the original block or ingot into desired shapes,
2. To refine grain size, and3. To control the direction of flow lines.
Hot Working
The working of metals above the *recrystallisation temperature is called hot working. This temperature should not be too high to reach the solidus temperature, otherwise the metal will burn and become unsuitable for use. The hot working of metals has the following advantages and disadvantages :
Advantages
1. The porosity of the metal is largely eliminated.
2. The grain structure of the metal is refined.
3. The impurities like slag are squeezed into fibres and distributed throughout the metal.
4. The mechanical properties such as toughness, ductility, percentage elongation, percentage reduction in area, and resistance to shock and vibration are improved due to the refinement of grains.
Disadvantages
1. It requires expensive tools.
2. It produces poor surface finish, due to the rapid oxidation and scale formation on the metal surface.
3. Due to the poor surface finish, close tolerance cannot be maintained.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
15
MACHINE DRAWING & COMPUTER GRAPHICS
Hot Working Processes
The various *hot working processes are described as below :
1. Hot rolling. The hot rolling process is the most rapid method of converting large sections into desired shapes. It consists of passing the hot ingot through two rolls rotating in opposite directions at the same speed. The space between the rolls is adjusted to conform to the desired thickness of the rolled section. The rolls, thus, squeeze the passing ingot to reduce its cross-section and increase its length. The forming of bars, plates, sheets, rails, angles, I-beam and other structural sections are made by
Hot Rolling : When steel is heated until it glows bright red, ithot rolling. becomes soft enough to form into elabrate shapes.
2. Hot forging. It consists of heating the metal to plastic state and then the pressure is applied to form it into desired shapes and sizes. The pressure applied in this is not continuous as for hot rolling, but intermittent. The pressure may be applied by hand hammers, power hammers or by forging machines.
3. Hot spinning. It consists of heating the metal to forging temperature and then forming it into the desired shape on a spinning lathe. The parts of circular cross-section which are symmetrical about the axis of rotation, are made by this process.
4. Hot extrusion. It consists of pressing a metal inside a chamber to force it out by high pressure through an orifice which is shaped to provide the desired form of the finished part. Most commercial metals and their alloys such as steel, copper, aluminium and nickel are directly extruded at elevated temperatures. The rods, tubes, structural shapes, flooring strips and lead covered cables, etc., are the typical products of extrusion.
5. Hot drawing or cupping. It is mostly used for the production of thick walled seamless tubes and cylinders. It is usually performed in two stages. The first stage consists of drawing a cup out of a hot circular plate with the help of a die and punch. The second stage consists of reheating the drawn
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
16
MACHINE DRAWING & COMPUTER GRAPHICS
cup and drawing it further to the desired length having the required wall thickness. The second drawing operation is performed through a number of dies, which are arranged in a descending order of their diameters, so that the reduction of wall thickness is gradual in various stages.
6. Hot piercing. This process is used for the Cold Rolled Steel : Many modern prodmanufacture of seamless tubes. In its operation, the heated ucts are made from easily shaped sheet cylindrical billets of steel are passed between two conical metal. shaped rolls operating in the same direction. A mandrel is provided between these rolls which assist in piercing and controls the size of the hole, as the billet is forced over it.
Cold Working The working of metals below their recrystallisation temperature is known as cold working. Most of the cold working processes are performed at room temperature. The cold working distorts the grain structure and does not provide an appreciable reduction in size. It requires much higher pressures than hot working. The extent to which a metal can be cold worked depends upon its ductility. The higher the ductility of the metal, the more it can be cold worked. During cold working, severe stresses known as residual stresses are set up. Since the presence of these stresses is undesirable, therefore, a suitable heat treatment may be employed to neutralise the effect of these stresses. The cold working is usually used as finishing operation, following the shaping of the metal by hot working. It also increases tensile strength, yield strength and hardness of steel but lowers its ductility. The increase in hardness due to cold working is called work-hardening.
In general, cold working produces the following effects :
1. The stresses are set up in the metal which remain in the metal, unless they are removed by subsequent heat treatment.
2. A distortion of the grain structure is created.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
17
MACHINE DRAWING & COMPUTER GRAPHICS
3. The strength and hardness of the metal are increased with a corresponding loss in ductility.
4. The recrystalline temperature for steel is increased.
5. The surface finish is improved.
6. The close dimensional tolerance can be maintained.
Cold Working Processes
The various cold working processes are discussed below:
1. Cold rolling. It is generally employed for bars of all shapes, rods, sheets and strips, in order to provide a smooth and bright surface finish. It is also used to finish the hot rolled components to close tolerances and improve their toughness and hardness. The hot rolled articles are first immersed in an acid to remove the scale and washed in water, and then dried. This process of cleaning the articles is known as pickling. These cleaned articles are then passed through rolling mills. The rolling mills are similar to that used in hot rolling.
2. Cold forging. The cold forging is also called swaging. During this method of cold working, the metal is allowed to flow in some pre-determined shape according to the design of dies, by a compressive force or impact. It is widely used in forming ductile metals. Following are the three, commonly used cold forging processes :
(a) Sizing. It is the simplest form of cold forging. It is the operation of slightly compressing a forging, casting or steel assembly to obtain close tolerance and a flat surface. The metal is confined only in a vertical direction.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
18
MACHINE DRAWING & COMPUTER GRAPHICS
(b) Cold heading. This process is extensively used for making bolts, rivets and other similar headed parts. This is usually done on a cold header machine. Since the cold header is made from unheated material, therefore, the equipment must be able to withstand the high pressures that develop. The rod is fed to the machine where it is cut off and moved into the header die. The operation may be either single or double and upon completion, the part is ejected from the dies. After making the bolt head, the threads are produced on a thread rolling machine. This is also a cold working process. The process consists of pressing the blank between two rotating rolls which have the thread form cut in their surface.
c) Rotary swaging. This method is used for reducing the diameter of round bars and tubes by rotating dies which open and close rapidly on the work. The end of rod is tapered or reduced in size by a combination of pressure and impact.
3. Cold spinning. The process of cold spinning is similar to hot spinning except that the metal is worked at room temperature. The process of cold spinning is best suited for aluminium and other soft metals. The commonly used spun articles out of aluminum and its alloys are processing kettles, cooking utensils, liquid containers, and light reflectors, etc.
4. Cold extrusion. The principle of cold extrusion is exactly similar to hot extrusion. The most common cold extrusion process is impact extrusion. The operation of cold extrusion is performed with the help of a punch and die. The work material is placed in position into a die and struck from top
5. Cold drawing. It is generally employed for bars, rods, wires, etc. The important cold drawing processes are as follows:
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
19
MACHINE DRAWING & COMPUTER GRAPHICS
a) Bar or rod drawing. In bar drawing, the hot drawn bars or rods from the mills are first pickled, washed and coated to prevent oxidation. A draw bench, is employed for cold drawing. One end of the bar is reduced in diameter by the swaging operation to permit it to enter a drawing die. This end of bar is inserted through the die and gripped by the jaws of the carriage fastened to the chain of the draw bench. The length of bars which can be drawn is limited by the maximum travel of the carriage, which may be from 15 metres to 30 metres. A high surface finish and dimensional accuracy is obtained by cold drawing. The products may be used directly without requiring any machining.
(b) Wire drawing. In wire drawing, the rolled bars from the mills are first pickled, washed and coated to prevent oxidation. They are then passed through several dies of decreasing diameter to provide the desired reduction in size. The dies are usually made of carbide materials.
c) Tube drawing. The tube drawing is similar to bar drawing and in most cases it is accomplished with the use of a draw bench.
6. Cold bending. The bars, wires, tubes, structural shapes and sheet metal may be bent to many shapes in cold condition through dies. A little consideration will show that when the metal is bend beyond the elastic limit, the inside of the bend will be under compression while the outside will be under tension. The stretching of the metal on the outside makes the stock thinner. Usually, a flat strip of metal is bend by roll forming. The materials commonly used for roll forming are carbon steel, stainless steel, bronze, copper, brass, zinc and aluminium. Some of its products are metal windows, screen frame parts, bicycle wheel rims, trolley rails, etc. Most of the tubing is now-a-days are roll formed in cold conditions and then welded by resistance welding.
7. Cold peening. This process is used to improve the fatigue resistance of the metal by setting up compressive stresses in its surface. This is done by blasting or hurling a rain of small shot at high
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
20
MACHINE DRAWING & COMPUTER GRAPHICS
velocity against the surface to be peened. The shot peening is done by air blast or by some mechanical means. As the shot strikes, small indentations are produced, causing a slight plastic flow of the surface metal to a depth of a few hundreds of a centimetre. This stretching of the outer fibres is resisted by those underneath, which tend to return them to their original length, thus producing an outer layer having a compressive stress while those below are in tension. In addition, the surface is slightly hardened and strengthened by the cold working operation.
Interchangeability
The term interchangeability is normally employed for the mass production of indentical items within the prescribed limits of sizes. A little consideration will show that in order to maintain the sizes of the part within a close degree of accuracy, a lot of time is required. But even then there will be small variations. If the variations are within certain limits, all parts of equivalent size will be equally fit for operating in machines and mechanisms. Therefore, certain variations are recognised and allowed in the sizes of the mating parts to give the required fitting. This facilitates to select at random from a large number of parts for an assembly and results in a considerable saving in the cost of production. In order to control the size of finished part, with due allowance for error, for interchangeable parts is called limit system.
It may be noted that when an assembly is made of two parts, the part which enters into the other, is known as enveloped surface (or shaft for cylindrical part) and the other in which one enters is called enveloping surface (or hole for cylindrical part).
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
21
MACHINE DRAWING & COMPUTER GRAPHICS
Notes: 1. The term shaft refers not only to the diameter of a circular shaft, but it is also used to designate any external dimension of a part.
Important Terms used in Limit System
The following terms used in limit system (or interchangeable system) are important from the subject point of view:
1. Nominal size. It is the size of a part specified in the drawing as a matter of convenience.
2. Basic size. It is the size of a part to which all limits of variation (i.e. tolerances) are applied to arrive at final dimensioning of the mating parts. The nominal or basic size of a part is often the same.
3. Actual size. It is the actual measured dimension of the part. The difference between the basic size and the actual size should not exceed a certain limit, otherwise it will interfere with the interchangeability of the mating parts.
4. Limits of sizes. There are two extreme permissible sizes for a dimension of the part as shown in Fig. 3.1. The largest permissible size for a dimension of the part is called upper or high or maximum limit, whereas the smallest size of the part is known as lower or minimum limit.
5. Allowance. It is the difference between the basic dimensions of the mating parts. The allowance may be positive or negative. When the shaft size is less than the hole size, then the allowance is positive and when the shaft size is greater than the hole size, then the allowance is negative.
6. Tolerance. It is the difference between the upper limit and lower limit of a dimension. In other words, it is the maximum permissible variation in a dimension. The tolerance may be unilateral
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
22
MACHINE DRAWING & COMPUTER GRAPHICS
or bilateral. When all the tolerance is allowed on one side of the nominal size, e.g. 20 – 0.004 , then it is said to be unilateral system of tolerance. The unilateral system is mostly used in industries as it permits changing the tolerance value while still retaining the same allowance or type of fit.
Fits
The degree of tightness or looseness between the two mating parts is known as a fit of the parts. The nature of fit is characterised by the presence and size of clearance and interference.
The clearance is the amount by which the actual size of the shaft is less than the actual size of the mating hole in an assembly as shown in Fig. 3.5 (a). In other words, the clearance is the difference between the sizes of the hole and the shaft before assembly. The difference must be positive.
The interference is the amount by which the actual size of a shaft is larger than the actual finished size of the mating hole in an assembly as shown in Fig. 3.5 (b). In other words, the interference is the arithmetical difference between the sizes of the hole and the shaft, before assembly. The difference must be negative.
Types of Fits
According to Indian standards, the fits are classified into the following three groups : 1. Clearance fit. In this type of fit, the size limits for mating parts are so selected that clearance between them always occur, as shown in Fig. 3.5 (a). It may be noted that in a clearance fit, the tolerance zone of the hole is entirely above the tolerance zone of the shaft. In a clearance fit, the difference between the minimum size of the hole and the maximum
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
23
MACHINE DRAWING & COMPUTER GRAPHICS
size of the shaft is known as minimum clearance whereas the difference between the maximum size of the hole and minimum size of the shaft is called maximum clearance.
The clearance fits may be slide fit, easy sliding fit, running fit, slack running fit and loose running fit.
2. Interference fit. In this type of fit, the size limits for the mating parts are so selected that interference between them always occur, as shown in Fig. 3.5 (b). It may be noted that in an interference fit, the tolerance zone of the hole is entirely below the tolerance zone of the shaft. In an interference fit, the difference between the maximum size of the hole and the minimum size of the shaft is known as minimum interference, whereas the difference between the minimum size of the hole and the maximum size of the shaft is called maximum interference, as shown in Fig. 3.5 (b). The interference fits may be shrink fit, heavy drive fit and light drive fit.
3. Transition fit. In this type of fit, the size limits for the mating parts are so selected that either a clearance or interference may occur depending upon the actual size of the mating parts, as shown in Fig. 3.5 (c). It may be noted that in a transition fit, the tolerance zones of hole and shaft overlap. The transition fits may be force fit, tight fit and push fit.
Basis of Limit System
The following are two bases of limit system: 1. Hole basis system. When the hole is kept as a constant member (i.e. when the lower deviation of the hole is zero) and different fits are obtained by varying the shaft size, as shown in Fig. 3.6 (a),
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
24
MACHINE DRAWING & COMPUTER GRAPHICS
then the limit system is said to be on a hole basis. 2. Shaft basis system. When the shaft is kept as a constant member (i.e. when the upper deviation of the shaft is zero) and different fits are obtained by varying the hole size, as shown in Fig. 3.6 (b), then the limit system is said to be on a shaft basis.
Indian Standard System of Limits and Fits
According to Indian standard [IS : 919 (Part I)-1993], the system of limits and fits comprises 18 grades of fundamental tolerances i.e. grades of accuracy of manufacture and 25 types of fundamental deviations indicated by letter symbols for both holes and shafts (capital letter A to ZC for holes and small letters a to zc for shafts) in diameter steps ranging from 1 to 500 mm. A unilateral hole basis system is recommended but if necessary a unilateral or bilateral shaft basis system may also be used. The 18 tolerance grades are designated as IT 01, IT 0 and IT 1 to IT 16. These are called standard tolerances. The standard tolerances for grades IT 5 to IT 7 are determined in terms of standard tolerance unit (i) in microns, where
Calculation of Fundamental Deviation for Shafts
We have already discussed that for holes, the upper deviation is denoted by ES and the lower deviation by EI. Similarly for shafts, the upper deviation is represented by es and the lower deviation by ei. According to Indian standards, for each letter symbol, the magnitude and sign for one of the two deviations (i.e. either upper or lower deviation), which is known as fundamental deviation, have been determined by means of formulae given in Table 3.7. The other deviation may be calculated by using the absolute value of the standard tolerance (IT) from the following relation:
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
25
MACHINE DRAWING & COMPUTER GRAPHICS
ei = es – IT
It may be noted for shafts a to h, the upper deviations (es) are considered whereas for shafts j to Zc, the lower deviation (ei) is to be considered.
Example 1. The dimensions of the mating parts, according to basic hole system, are given as follows : Hole : 25.00 mm
Shaft : 24.97 mm
25.02 mm
24.95 mm
Find the hole tolerance, shaft tolerance and allowance
Solution. Given : Lower limit of hole = 25 mm ; Upper limit of hole = 25.02 mm ; Upper limit of shaft = 24.97 mm ; Lower limit of shaft = 24.95 mm
Hole tolerance
We know that hole tolerance = Upper limit of hole – Lower limit of hole = 25.02 – 25 = 0.02 mm Ans.
Shaft tolerance We know that shaft tolerance = Upper limit of shaft – Lower limit of shaft = 24.97 – 24.95 = 0.02 mm Ans
Allowance We know that allowance = Lower limit of hole – Upper limit of shaft = 25.00 – 24.97 = 0.03 mm Ans.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
26
MACHINE DRAWING & COMPUTER GRAPHICS
Example 2. Calculate the tolerances, fundamental deviations and limits of sizes for the shaft designated as 40 H8 / f7.
Solution. Given: Shaft designation = 40 H8 / f 7
The shaft designation 40 H8 / f 7 means that the basic size is 40 mm and the tolerance grade for the hole is 8 (i.e. I T 8) and for the shaft is 7 (i.e. I T 7).
Tolerances Since 40 mm lies in the diameter steps of 30 to 50 mm, therefore the geometric mean diameter,
= 38.73 mm
We know that standard tolerance unit,
i = 0.45 D + 0.001 D 0.45 * 8.73 + 0.001 Ă— 38.73=1.55793
=.00156
mm
Surface Roughness and its Measurement
A little consideration will show that surfaces produced by different machining operations (e.g. turning, milling, shaping, planing, grinding and superfinishing) are of different characteristics. They show marked variations when compared with each other. The variation is judged by the degree of smoothness. A surface produced by superfinishing is the smoothest, while that by planing is the roughest. In the assembly of two mating parts, it becomes absolutely necessary to describe the surface finish in quantitative terms which is measure of micro- irregularities of the surface and expressed in microns. In order to prevent stress concentrations and proper functioning, it may be necessary to avoid or to have certain surface roughness. There are many ways of expressing the surface roughness
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
27
MACHINE DRAWING & COMPUTER GRAPHICS
numerically, but the following two methods are commonly used :
1. Centre line average method (briefly known as CLA method), and
2. Root mean square method (briefly known as RMS method). The centre line average method is defined as the average value of the ordinates between the surface and the mean line, measured on both sides of it. According to Indian standards, the surface finish is measured in terms of ‘CLA’ value and it is denoted by Ra.
Landing Gear : When an aircraft comes in to land, it has to lose a lot of energy in a very short time. the landing gear deals with this and prevents disaster. First, mechanical or liquid springs absorb energy rapidly by being compressed. As the springs relax, this energy will be released again, but in a slow controlled manner in a damper-the second energy absorber. Finally, the tyres absorb energy, getting hot in the process.
n where, y1, y2, ...yn are the ordinates measured on both sides of the mean line and n are the number of ordinates. The root mean square method is defined as the square root of the arithmetic mean of the squares of the ordinates. Mathematically,
y12 R.M.S. value (in microns) = n According to Indian standards, following symbols are used to denote the various degrees of surface roughness :
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
28
MACHINE DRAWING & COMPUTER GRAPHICS
SymbolSurface roughness (Ra) in microns ∇ 8 to 25 ∇ ∇ 1.6 to 8 ∇ ∇ ∇ 0.025 to 1.6 ∇ ∇ ∇ ∇ Less than 0.025
The following table shows the range of surface roughness that can be produced by various
manufacturing processes.
Preferred Numbers
When a machine is to be made in several sizes with different powers or capacities, it is necessary to decide what capacities will cover a certain range efficiently with minimum number of sizes. It has been shown by experience that a certain range can be covered efficiently when it follows a geometrical progression with a constant ratio. The preferred numbers are the conventionally rounded off values derived from geometric series including the integral powers of 10 and having as common ratio of the following factors:
10, 10 10, 20 10 and 40 10 These ratios are approximately equal to 1.58, 1.26, 1.12 and 1.06. The series of preferred numbers are designated as *R5, R10, R20 and R40 respectively. These four series are called basic series. The other series called derived series may be obtained by simply multiplying or dividing the
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
29
MACHINE DRAWING & COMPUTER GRAPHICS
basic sizes by 10, 100, etc. The preferred numbers in the series R5 are 1, 1.6, 2.5, 4.0 and 6.3. Table 3.12 shows basic series of preferred numbers according to IS : 1076 (Part I) – 1985 (Reaffirmed 1990).
Notes : 1. The standard sizes (in mm) for wrought metal products are shown in Table 3.13 according to IS : 1136 – 1990. The standard G.P. series used correspond to R10, R20 and R40.
2. The hoisting capacities (in tonnes) of cranes are in R10 series, while the hydraulic cylinder diameters are in R40 series and hydraulic cylinder capacities are in R5 series.
3. The basic thickness of sheet metals and diameter of wires are based on R10, R20 and R40 series. Wire diameter of helical springs are in R20 series.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
30
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT - II SECTIONAL VIEWS
INTRODUCTION The orthographic views viz., front, top and side views, the visible edges and faces are indicated by continuous lines, while its interior hollow portions, and invisible outer edges and faces are indicated by dashed lines. If the interior construction of the object is complex, there will be a network of mass of dashed lines in the orthographic views as shown in fig 1.1.in order to avoid this complication and to remove the hidden lines; one or more views are represented “in section”.
Fig1.1 Network of Dashed Lines
In section, the object is imagined as cut apart by planes so as to expose its interior. This imaginary process of cutting the object is called sectioning. The imaginary plane which cuts the object is called the section plane or cutting plane.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
31
MACHINE DRAWING & COMPUTER GRAPHICS
NEED FOR SECTIONING The sectional views are necessary 1. To show the internal features more clearly. 2. To remove hidden lines. 3. To avoid complication and ambiguity. 4. For ease of understanding.
HATCHING
Fig1.2 Sectioning
The sectional views of an object comprises of both sectioned and unsectioned surfaces. To differentiate between the sectioned and the unsectioned surfaces on the sectional views, a series of thin inclined lines,called section lines, parallel to themselves and inclined usually at 45ยบ to the horizontal, or to the main axis of the object, are drawn within the region of the cut surface as shown in fig 1.2. this process of executing parallel section lines is called hatching. The section lines, sometimes are also called as hatching lines.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
32
MACHINE DRAWING & COMPUTER GRAPHICS
33
INCLINATION OF HATCHING LINES The simplest form hatching, which will be usually adequate for general purposes, involves drawing of continuous thin parallel lines inclined at 45ยบ to the outlines as shown in fig 1.3
Fig 1.3 Other type of Hatching Lines
When the out line of the sectioned surfaces are themselves inclined at 45ยบ, the 45ยบ hatching lines will become parallel to the outlines and thus over shadows the cut surface. In such cases, hatching lines are drawn horizontal as shown
in fig.
SPACING BETWEEN HATCHINE LINES
Fig 1.4 Spacing between Hatching Lines
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
The hatching must be done in such a way that the sectioned surface does not appear as dark as the outlines of the object. This can be accomplished by drawing hatching hatching lines as thin lines with the appropriate spacing between them. A spacing of 2mm between the hatching lines will be appropriate for the general work. HATCHING OF LARGER AREAS Hatching of larger areas should be done only at the outer lines forming the boundary leaving blank space at the middle as shown in fig 1.5.
Fig1.5 Hatching of a Large Area Hatching of adjacent parts
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
34
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 1.6 Hatching more than Two Adjacent Parts
When two different parts are joined together as in the case riveted lap joint, then these 2 parts are to be cross hatched at 45ยบ but in opposite directions as shown in fig 1.6.
When three are more parts in contact such as riveted butt joints are to sectioned, then two of the adjacent parts should be cross hatched at an angle of 45ยบ, but in opposite directions and the remaining parts are to be hatched at different angles such as 30ยบ or 60ยบ and at different spacing .when thin sections like sheet metal, Gasket, washer etc., are to be shown in section, they are shown totally black leaving thin space between adjacent parts.
SKETCH AND OF FULL SECTION When a section plane passes through the object so as to cut it completely, the sectional view is called full sectional view or simply sectional view.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
35
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 1.7 Full Section
HALF SECTION When an object is symmetrical about one its axis, the drawing of its full sectional view involves repetition of hatching work on both the sides of its symmetrical axis which requires considerable labour and time. In such cases, only one half of the object is shown in section while its other half will be shown as unsectioned. Such a view which shows one half in section and the other half as unsectioned is called half sectional view.
Fig1.8
TYPES OF HALF SECTION The different types of half section about its horizontal or vertical axis depending on the portion of the interior details of the object to be shown in section.
1. Front view with right half in section 2. front view with top half in section top view with section
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
36
MACHINE DRAWING & COMPUTER GRAPHICS
3. top view with front half in section 4. left view with front half in section
Fig 1.9 Half Section
PARTIAL OR LOCAL SECTION In local section, only a small portion of the object surrounding the feature is assumed to be removed and the boundary of the section is shown by irregular lines, as showing in fig 1.10
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
37
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 1.10 Partial or Local Sections
REVOLVED OR SUPERIMPOSED SECTION Revolved section is obtained by revolving the section through 90ยบ, so that the section is made to align with the longitudinal view of the object as shown in fig 1.11
Fig 1.11 Revolved Section REMOVED SECTION When the section is to be shown on enlarged scale for the purpose of dimensioning, then the section cannot be aligned with any of the views. Instead, the section is drawn away from the view along the extension of the cutting plane line as shown in fig 1.12
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
38
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 1.12 Removed Section
OFFSET SECTION The section planes are usually assumed to pass through the axis of symmetry or the principal axis of the object. But when it becomes necessary to show still more details about the object, then the cutting plane is made to offset, so that it passes through different locations as shown in fig 1.13
Fig 1.13 Offset Section
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
39
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT – III LIMITS, FITS AND TOLERANCES
Introduction The maximum and minimum permissible sizes within which the actual machined size lies are called limits. The functional relationship between the two adjacent parts achieved by the specified tolerance is called fit. The amount of variation permitted for a basic size is called tolerance.
Definition of various terms used in limits
Fig 2.1 illustrates the various terms Basic size It is defined as the theoretical size of a part, derived from the design after rounding off to the nearest whole millimeter. The tolerances are always specified to the basic size. In fig 2.1 the dimension 30mm is the basic size. The basic size is also represented as “zero line”.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
40
MACHINE DRAWING & COMPUTER GRAPHICS
Actual size It is defined as the size actually obtained by machining. It is found by actual measurement using measuring instruments. In fig 2.1 the actual size of the diameter of the shaft is Ă˜29.925mm. Limits The two extreme permissible sizes between which the actual size lies are called limits.
Maximum limits It is the allowable maximum size of the component, which lies above the Basic size.
Minimum limit It is the allowable minimum size of the component, which lies below the Basic size.
Tolerance It is defined as the amount of variation permitted to a basic size. The difference between the maximum and minimum limits of a basic size is called tolerance. Tolerance = maximum limit – minimum limit
Deviation It is defined as the difference between the actual size or limit sizes, either maximum or minimum, and the corresponding basic size.
Actual deviation It is the algebraic difference between the actual measured size and the corresponding basic size.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
41
MACHINE DRAWING & COMPUTER GRAPHICS
Upper deviation It is defined as the algebraic difference between the maximum limit of size and the corresponding basic size.
Lower deviation It is defined as the algebraic difference between the minimum limit of size and the corresponding basic size. Tolerance zone It is the zone or area that lies between the upper limit and the lower limit. The actual size of the component that lies in the tolerance zone alone will be accepted.
Hole basis system In hole basis system, the basic size of a hole is kept constant and size of the shaft is varied above or below the zero line, so as to get a desired class of fit.
This system is popular in industries, as the standard tools such drills, reamers etc., are available for producing holes. For the holes, the lower deviation is zero and the minimum size of hole is equal to the design size, which is taken as the base for computing all the other limit dimensions. The limit dimensions on the hole and the shaft are computed by selecting suitable clearances and tolerances on the shaft and the hole.
Fig shows the clearance and transistion fits in the basis system. fig 2.2 A shows the tolerance zone for the hole having its lower limit equal to the basic size. The zero line is drawn through the lower limit since the lower deviation is zero. Both the limit dimensions of the shaft lie below the zero line for the clearance fit as shown in fig 2.2 B while they are above the zero line for the interference fit as shown in fig 2.2 C.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
42
MACHINE DRAWING & COMPUTER GRAPHICS
43
Fig 2.2 Hole Basis System
Shaft basis system In this system, the different types of fits are obtained by associating holes of varying limit dimensions with a single shaft, whose upper deviation is zero. When the upper deviation of the shaft is zero, the maximum limit of the shaft will be equal to its basic size, which is taken as the base for computing all other limit dimensions. The limit dimensions on the hole and the shaft are computed by selecting suitable clearance and tolerances on the shaft and the hole.
Fig shows the clearance and transition fits in the shaft basis system. Fig 2.3 A shows the tolerance zone for the shaft having its maximum limit equal to the basic size. The zero line is drawn through the maximum limit since its upper deviation is zero. Both the limit dimensions of the hole lie above the zero line for the clearance fit as shown in fig 2.3 B. While they are below the zero line for the interference fit as shown in
Fig 2.3 C.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 2.3 Shaft Basis System
TYPES OF FITS FITS A machine is built by assembling all its constituting parts. During assembling sometimes a part may be required to be filled into another part. In such cases, and during the working of the machine they may or may not be intended to have a relative motion between them. If there should be a relative motion between the two parts, they must be filled loose, or tight otherwise. The fitting of one part in to the other, either loose or tight depends on the relationship existing between their mating surfaces which in turn depends on the dimensional differences between the parts. The relationship existing between the mating surfaces of the parts because of the differences in their dimensions is called fit. SHAFT AND HOLE — TERMINOLOGY In mechanical engineering practice, generally a rod of circular cross section and a circular hole are termed as shaft and hole respectively. In the system of fits and tolerances, for the sake of simplicity even the non circular sections and also the space containing or contained by the two parallel faces of any part such as, the thickness of a key and the width of a keyway or a slot, are also referred as ‘shaft’ and ‘hole’ respectively. CLEARANCE It is defined as the difference between the dimensions of the hole and the shaft assigned intentionally to obtain a particular type of a fit. It may be positive or negative. When the shaft size is smaller than the hole size it will be positive and will be negative when the shaft size is bigger than the hole size. The value of the clearance will be maximum when the
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
44
MACHINE DRAWING & COMPUTER GRAPHICS
hole size is maximum and the shaft size is minimum. It will be minimum when the shaft size is maximum and the hole size is minimum. CLASSIFICATION OF FITS A fit is established when one part is inserted into the other, The type of fit Obtained between the two parts is governed by the dimensional deviations assigned for the basic size of the shaft and the hole. For a given basic size, the deviations assigned and the performance are interdependent. But since the performance is the ultimate objective, the deviations assigned for a basic size must satisfy the performance intended. But the performance itself is of varied type like, a shaft fitting tightly into a hole, or capable of just rotation, or sliding loosely in it. So, for a given basic size, we can have different performances. Therefore to obtain different performances we need to fix different deviations for the basic size of the shaft and the hole. Each set of deviations for the given basic size results in a particular type of performance For example, for the shaft to rotate in a hole, obviously its dimensions should be less than the hole. Alternately, when a shaft is to be held rigidly in a hole, its sizes should be greater than that of the hole, so that when the shaft is driven in to the hole, the outer surface of the shaft interferes with the inner surface of the hole, In the former, since there is a positive clearance between the two sizes, the fit is called clearance fit, while in the latter, because the surfaces interfere, the fit is called interference fit. A fit resulting due to the variations in the dimensions between that of the clearance fit and the interference fit is called transition fit. Thus the types of fits are
Clearance,
Interference and
Transition fits.
CLEARANCE FIT It is defined as the fit established when a positive clearance exists between the hole and the shaft. It is obtained by selecting the maximum and minimum limits of the shaft and the hole so that the clearance due to the difference between the dimensions of the smallest possible hole and the largest possible shaft is always positive. There are different classes in this type of fit depending on the clearance and the specific operating conditions of the given mating parts. They vary with the shaft speed, shaft bearing load, lubricating oil grade, temperature and the length of the mating surfaces.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
45
MACHINE DRAWING & COMPUTER GRAPHICS
46
Fig 2.4
Figure 2.4 shows a clearance fit. The clearance between and the largest possible shaft is
the smallest possible hole
= 29.95 — 29.90 = 0.05 mm. Figure shows the
conventional representation of a clearance fit, where the tolerance zone of the hole lies above that of the shaft. INTERFERENCE FIT It is defined as the fit established when a negative clearance exist between the sizes of the hole and the shaft. It is obtained by selecting the maximum and minimum limits of the shaft and the hole so that there is an interference of the surfaces and the clearance due to the difference between the dimensions of the largest possible hole and the smallest possible shaft is always negative. Interference fits are obtained by several methods, for instance, a shaft may be driven into the hole with a considerable force, or heating the part having the hole in order to increase the diameter of the hole, or by cooling the shaft and thus decreasing its diameter.
Fig 2.5
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Figure 2.5 shows an interference fit. The difference between the dimensions of the largest possible hole and the smallest possible shaft is = 30.25 — 30.30 = — 0.05mm. Figure shows the conventional representation of an interference fit, where the tolerance zone of the hole lies entirely below that of the shaft. The interference fit is obtained by driving a shaft into the hole with a considerable force. When the force applied is heavy the interference fit is called heavy force fit, and when a lighter force is used to drive the shaft into the hole, it is called light force fit. The interference fit can also be obtained by heating and subsequent cooling. The part containing the hole is heated so that the diameter of the hole will increase due to material expansion, and then after inserting the shaft in the hole, on cooling the hole will shrink to hold the shaft rigidly. TRANSITION FIT It is defined as the fit established when the dimensions of the hole and the shaft are such that there exists a positive clearance or a negative clearance when the shaft is fitted into the hole. It is obtained by selecting the maximum and minimum limits for the shaft and the hole such that there exists a positive clearance when the smallest possible shaft is fitted into the largest possible hole, or a negative clearance when the largest possible shaft is forced into the smallest possible hole.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
47
MACHINE DRAWING & COMPUTER GRAPHICS
48
Figure 2.6 shows a transition fit. Figure shows the fitting of the smallest possible shaft of 30.55 mm in the largest possible whole of 30.60mm allowing a positive clearance of 30.60 — 30.55 = 0.05mm. Figure 2.6 shows the fitting of the largest possible shaft of 30.65mm in the smallest possible whole of 30.50mm gives an interference fit
of
30.50 — 30.65 = — 0.15mm. Figure2.6 shows conventional representation of transition fits in which the tolerance zones of the hole and the shaft overlap. SELECTION OF FITS AND APPLICATIONS A wide range of fits may be obtained by various combinations of tolerance grades and fundamental deviations for both the shafts and the holes. But many of the possible combinations may not be of practical use. Majority of common engineering requirements may be satisfied on the basis of restricted selection of tolerance grades resulting in economy and ease of standardisation, yet leading to universally applicable and recommended fits. IS : 2709 – 1982 offers a comprehensive guide for the selection of fits. The most commonly used fits for general classes of work are given in the following tables.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
49
Commonly used type of fits I. For Holes Type of Fit
Class of Shaft
H7
H8
H9
-
-
-
-
c
-
-
-
d
-
d8*
d8*, d9, d10
e
e7*
e8
e8, e9*
Easy running fit
f
f6*
f7
f7, f8*
Normal running fit
g
g5*
g6
-
h
h5*
h6
h7, h8*, h9
Clearance
b
Transition
js
js5*
js6
H11
Remarks
H6*
a
a11 b11
Large clearance fit and widely used
-
c11
Slack running fit
d8*, d9, d10
d9
Loose running fit
Close running fit or sliding fir, also spigot and location fit h11
Precision sliding fit. Also fine spigot and location fit.
js7*
Push fit for very accurate location with easy assembly and disassembly
k
k5*
k6
k7*
Light keying fit (true transition) for keyed shafts, non-running locked pins, etc.,
m
m5*
m6*
m7*
Medium keying fit
n
n5*
n6
n7*
Heavy keying fit (for tight assembly mating surfaces)
P7*
Light press fit with easy dismantling for nonferrous parts. Standard press fit with easy dismantling for ferrous and non-ferrous parts assembly
r7*
Medium drive fit with easy dismantling for ferrous parts assembly Light drive fit with easy dismantling for ferrous parts assembly
s7*
Heavy drive fit for ferrous parts permanent or semipermanent assembly standard press fit for nonferrous parts
P
Interference
With Holes
r
s
P5*
r5*
s5*
P6
r6
s6
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
t
t5*
t6*
u
50
t7*
Force fit on ferrous parts for permanent assembly
u7*
Heavy force fit or shrink fit
* Second preference fits. Commonly used type of fits
II. For Shafts
Clearance
Type of Fit
Class of Shaft
H5*
H6
H7
H8*
H9
H11
Remarks
A
A11
B
B11
C
C11
Slack running fit
Large clearance fit and widely used
D11*
Loose running fit
D
D9*
D10
D10
E
E8*
E8*
E9
Easy running fit
F
F7*
F8
F8*
Normal running fit
G
H
js Transition
With Shafts
G6*
H6*
js6*
Close running fit or sliding fir, also spigot and location fit
G7
H7
js7
H8
H8
H8, H9
H11
Precision sliding fit. Also fine spigot and location fit.
js8*
Push fit for very accurate location with easy assembly and disassembly
K
K6*
K7
K8*
Light keying fit (true transition) for keyed shafts, nonrunning locked pins, etc.,
M
M6*
M7*
M8*
Medium keying fit
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
N
Interference
P
R
S
T
N6*
P6*
R6*
S6*
T6*
N7
N8*
51
Heavy keying fit (for tight assembly mating surfaces)
P7
Light press fit with easy dismantling for non-ferrous parts. Standard press fit with easy dismantling for ferrous and non-ferrous parts assembly
R7
Medium drive fit with easy dismantling for ferrous parts assembly Light drive fit with easy dismantling for ferrous parts assembly
S7
Heavy drive fit for ferrous parts permanent or semipermanent assembly standard press fit for nonferrous parts
T7
Force fit on ferrous parts for permanent assembly
* Second preference fits.
TYPES OF TOLERANCES Straightness Tolerance This type of form tolerance shown in Figure 2.7 refers to the axis of the cylindrical part, because the tolerance frame is connected to the dimension line which indicates the
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
diameter of the cylindrical part. The tolerance value ď Ś 0.08 mm means that the axis of the cylinder must be contained in a cylindrical zone of diameter 0.08 mm as shown in Figure 2.7.
Fig 2.7 Flatness Tolerance This type of form tolerance shown in Figure 2.8 refers to surface, because the leader line connecting the tolerance frame has its arrow resting on a surface. The tolerance value 0.08 mm means that the indicated surface should be contained between two parallel planes 0.08 mm apart.
Fig 2.8 Circularity Tolerance This type of form tolerance shown in Figure 2.9 refers to circularity, because the leader line connecting the tolerance frame has its arrow resting on the conical surface of the part. The tolerance value 0.1 mm means that the circumference of each cross section should be contained between two co-planar concentric circles 0.1 mm apart.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
52
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 2.9 Cylindricity Tolerance This type of form tolerance shown in Figure 2.10 refers to the cylindricity, because the leader line connecting the tolerance frame has its arrow resting on the cylindrical surface of the part. The tolerance value 0.1 mm means that the considered cylindrical surface should be contained between two coaxial cylinders 0.1 mm apart.
Fig 2.10
Profile Tolerance of a Line This type of form tolerance shown in Figure 2.11 refers to a profile because the leader line connecting the tolerance frame has its arrow resting on the profile of a surface. The tolerance value 0.04 mm means that the considered profile must be contained between two lines enveloping circles of diameter 0.04 mm, the centres of which are situated on a line having the correct geometrical profile.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
53
MACHINE DRAWING & COMPUTER GRAPHICS
54
Fig 2.11
Profile Tolerance of Any Surface This type of form tolerance shown in Figure 2.12 refers to the profile of a double curved surface because the leader line connecting the tolerance frame has its arrow resting on the profile of a double curved surface. The toleranced value
0.02 mm means that the
considered surface should be contained between two double curved surfaces enveloping spheres of diameter 0.02 mm, the centres of which are situated on a surface having the correct geometrical form.
Fig 2.12
Parallelism Tolerance This type of tolerance refers to the orientation of the axis of a feature with reference to a datum linc. The tolerance shown in Fig.2.13 refers to the orientation of the axis of the upper hole with reference to the axis of the lower hole which is considered as datum, The upper axis should be contained In a cylindrical tolerance zone of diameter 0.03 mm parallel to the lower axis A.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 2.13
Perpendicularity Tolerance This type of tolerance refers to the orientation of the axis (or a line) of a feature Perpendicular to a datum surface. The axis of the cylinder to the dimension of which the tolerance frame is connected as shown in Figure should be contained between two Parallel straight lines 0.1 mm apart, lying in a plane perpendicular to the datum plane as shown in Figure 2.14.
Fig 2.14
FORM & POSITION The tolerance for the sizes, called linear tolerances, are specified only to ensure that the actual manufacturing sizes are well within the acceptable limits. However, they have no control either over the geometry of the surface or its location, i.e., for example, a shaft may have its diameter well within the specified limits of size, but may not be truly circular. Similarly, a square slot may not have its surfaces exactly perpendicular, or, a hole may not have its centre correctly located. Thus it necessitates to specify the permissible deviations
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
55
MACHINE DRAWING & COMPUTER GRAPHICS
56
not only for its sizes but also for the geometrical variations in the form of the surfaces and the variations for their locations.
The geometry variations are called form variation and the
location variations are called position variation. Specifying of the permissible variations for both form and position using symbols and letter is called geometrical tolerancing. According to the characteristic form of the feature to be toleranced and the manner in which it is dimensioned, the tolerance zero that must be considered will be from any one of the following : (a) Area within a circle. (b) Area between two concentric circles. (c) Area between two parallel lines. (d) Space within a sphere. (e) Space within a cylinder or between coaxial cylinders. (f) Space between two parallel surfaces. (g) Space within a parallelepiped. The geometrical tolerances are indicated by specifying the form tolerances using symbols shown in Table and tolerance value in numerical values in the same unit of linear dimensions and positional tolerances referring the datum feature identified by a letter symbol. These indications are written in a rectangular frame which is divided into tow, sometimes, three compartments as shown in Figure. These compartments are filled in from left to right in the following order. (a) The symbol for the characteristic to be toleranced as shown in Table. (b) Tolerance value in the same unit used for linear dimensions. This value may be preceded by the shape identification symbols such as , , R, S, S, SR if required. (c) The letter identifying the referred datum feature.
TABLE Geometric Characteristic Symbols
FORM OF TOLERAN CES
Characteristics to be Toleranced
Form of Single Features
Symbol
Straightness Flatness
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Circularity (Roundness) Cylindricity Profile of any line Profile of any surface Parallelism Perpendicularity (Squareness) Orientation of Related Features
Angularity
POSITIONAL TOLERANCES
Runout Position Position of Related Features
Concentricity and Coaxiality Symmetry
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
57
MACHINE DRAWING & COMPUTER GRAPHICS
INDICATION OF TOLERANCE AND FITS ON THE DRAWINGS The different methods of indication of tolerance and fits on the drawings by using letter symbols and numerical values are shown in Figures.
Indications of Fits by Letter and Grade Symbols When it is required to indicate the fits by letter and grade symbol, the tolerance symbol for the hole must be placed before that of the shaft as shown in Figure2.15 A , or the tolerance symbol for the hole must be placed above that of the shaft as shown in Figure 2.15 B, and the symbols being preceded by the basic size indicated once only.
Fig 2.15
When it is also necessary to specify the numerical values of the deviations, they should be written in brackets as shown in Figure2.15 C.
Indication of Fits by Numerical Values The methods of indicating the fits by the numerical values are shown in Figure 2.16 A. The dimensions for each of the components of the assembled parts should be preceded by the name as shown in Figure 2.16 B, or item reference as shown in Figure, the dimension for the hole being placed in both the cases above the shaft.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
58
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 2.16
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
59
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT IV KEYS AND SURFACE FINISH
Introduction The common method to connect a shaft and a part is to drive a small piece of metal, known as key between the shaft and the hole made in the part mounted over it. The key will be driven such that it sits partly into the shaft and partly into the part mounted on it. To introduce the key, axial grooves, called key ways are cut both in the shaft and the part mounted on it as shown in the fig 3.1. The key is fitted between the shaft and the part mounted over it as shown in fig 3.1 . While transmitting the power, the key will be subjected to shear and crushing forces.
Keys are extensively used to hold pulleys, gears, couplings, clutches, sprockets, etc., and the shafts rigidly so that they rotate together. They are also used to mount the milling cutters, riding wheels, etc., on their spindles.
Fig 3.1
Classification of Keys Keys are classified into two types, (i) Taper keys and (ii) Parallel or feather keys.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
60
MACHINE DRAWING & COMPUTER GRAPHICS
Taper key: A taper key is of rectangular cross section having uniform width and tapering thickness. The taper keys are used to transmit only the turning moment between the shaft and the hub without any relative rotational and axial motion between them.
The examples of tapered keys are, i.
Taper sunk key
ii.
Saddle key,
iii.
Flat key and
iv.
Gib-head key.
Parallel Key (or) Feather key : A parallel key or feather key is also of rectangular cross section of uniform width and thickness throughout. Parallel keys are used to transmit the turning moment between the shaft and the hub along with the provision to allow a small sliding axial motion between them wherever required.
The examples of the parallel keys are, (i) Parallel sunk key, (ii) Peg key, (iii) Single head key, (iv) Double head key and (v) Spline shaft.
The woodruff key, cone key and pin key are the special purpose keys are used for specific applications.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
61
MACHINE DRAWING & COMPUTER GRAPHICS
Sunk Taper Key A sunk taper key shown in fig 3.2 is of rectangular or square cross section of uniform width having its bottom surface straight and top surface tapered. The key is driven between the shaft and the hub with half of its thickness to fit in the flat key way made in the shaft and the other half having the tapered surface to fit in the tapered key way made in the hub. This type of key is generally used to transmit heavy loads. The proportions of the key are as follows.
Fig 3.2
If D = diameter of the shaft in mm, W = width of the key and T = thickness of key, Width of key = 0.25 D+ 2mm Nominal Thickness = 0.66 W Standard Taper = 1:100
Hollow Saddle Key A hollow saddle key is of uniform width but tapering in thickness having its upper side flat and the underside hollow so as to sit on a shaft as shown in fig 3.3. Since the saddle key
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
62
MACHINE DRAWING & COMPUTER GRAPHICS
holds the shaft and the part mounted on it only by friction, it is not suitable for heavy loads. This key is used when there is frequent alterations in the position of the key on the shaft is expected.
Fig 3.3
The proportions of the keys are as follows: If D = diameter of the shaft in mm, W=width of the key and T = thickness , Width of key = 0.25 D+ 2mm Nominal Thickness = 0.33 W Standard Taper = 1:100
Flat Saddle Key A flat saddle key is similar to a hollow saddle key, except that it’s underneath surface is flat. The key sits over the flat surface formed on the shaft and fits into the key way in the hub as shown in fig 3.4. When the shaft rotates, the key will be wedged between the flat
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
63
MACHINE DRAWING & COMPUTER GRAPHICS
surface on the shaft and the key way in the hub, and thus holds them to rotate together. This key cannot be used for heavy loads and will not be suitable for shafts which frequently change their direction of rotation.
Fig 3.4 The proportions of this key are as follows: If D = diameter of the shaft in mm, W=width of the key and T = thickness of the key, Width of key = 0.25 D+ 2mm Nominal Thickness = 0.33 W Standard Taper = 1:100 Gib – Head key When a tapered sunk key is used, it can be removed by striking at its exposed thin end. If this end is not accessible, a head called gib is provided integral with the sunk taper key at its thicker end as shown in fig 3.5 . When a gib –head key is to be removed, a wedge is forced vertically in the gap between the head of the key and the vertical face of the hub.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
64
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 3.5
The proportions of the key are as follows. If D = diameter of the shaft in mm, W=width of the key and T = thickness of key,
Width of key = 0.25 D+ 2mm Height of Gib-Head =1.75 T Nominal Thickness = 0.66 W Width of Gib- Head = 1.5 T Standard Taper = 1:100
Feather Key or Parallel Key A feather key or parallel key permits an axial sliding movement for the wheel over a shaft when both of them are rotating together. This facility will be required in several power transmission applications, such as , for example, in gear boxes, loose pulleys, clutches, universal and flexible types of coupling, etc. in a gear box, for example, any one of the driven gears have to be moved axially over the driven shaft so as to engage with the driving gear to obtain different speeds.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
65
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 3.6
A feather key is rectangular or square cross section with uniform width and thickness as shown in fig 3.6. The ends of a feather key are usually rounded and the key will be sunk into the shaft for half of its thickness so that it fits snugly into the key way recess in it with a press fit. The press fit prevents the key from moving axially over the shaft when the driven wheel slides on it. In cases of higher power transmission, the feather key instead of press fit will be secured to the shaft by countersunk set screws. The proportions of the key are as follows: If D = diameter of the shaft in mm, W=width of the key and T = thickness of key, Width of key = 0.25 D+ 2mm Nominal thickness = 0.66 W
Peg Key A peg key is a feather type of key having a peg provided in the centre of the top face of the key as shown in
Fig 3.7. The peg fits in the hole drilled in the key way in the hub.
The key is a sliding fit in the key way of the shaft. The proportions of the key are as follows. If D = diameter of the shaft in mm, W=Width of the key and
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
66
MACHINE DRAWING & COMPUTER GRAPHICS
T = Thickness of key, H= Thickness of peg, Width of key = 0.25 D+ 2mm Thickness of peg = 0.5 T Nominal thickness = 0.66 W
Fig 3.7
Single Head Key A single head key is also a feather type of key provided with a gib head at one of its ends as shown in fig 3.8 . The key is connected to the hub by a screw. The key is a sliding fit in the shaft. The proportions of the key are as follows. If D = diameter of the shaft in mm, T = Thickness of key, h = height of the head, b= width of the head. Width of key = 0.25 D+ 2mm Height of the head = 1.75 T Nominal thickness = 0.66 W Width of the head = 1.5 T
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
67
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 3.8 Single Head Key
Double Head Key A double head key is also a feather type of key having integral gib head at its ends as shown in fig 3.9 . It fits tight in the hub and slides along with it in the key way in the shaft. Its proportions are as follows.
Fig 3.9 If D = diameter of the shaft in mm, T = Thickness of key, H = height of the head, B = width of the head. Width of key = 0.25 D+ 2mm Height of the head = 1.75 T Nominal thickness = 0.66 W
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
68
MACHINE DRAWING & COMPUTER GRAPHICS
Width of the head = 1.5 T
Spline Shaft A spline shaft has a series of lengthwise rectangular grooves extending for a small portion of its length leaving an equal number of feathers in between them as shown in fig 3.10. These feathers engage with corresponding recesses provided in the hub. As compared to a keyed joint, a splined joint offers the following advantage; transmission of heavier loads, accurate centering of hub, increased strength of the joint.
Fig 3.10 Spline Shaft Woodruff A woodruff key shown in fig 3.11 differs from those dealt earlier in that, it is not primarily intended to withstand shear forces and is used in light classes of work for holding the hub over the shaft so as to prevent it from slipping. It has a uniformly thick curved-base disc of shape somewhat less than a semicircle. It fits into a similarly shaped key way in the tapered shaft or the spindle.
Fig 3.11 Woodruff Key
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
69
MACHINE DRAWING & COMPUTER GRAPHICS
The hub of the wheel has a tapered bore to suit the tapered shaft. The wheel is driven on the tapered shaft until it fits tightly over it. When a nut is then tightened –up hard against the outer face of the hub, the key grips the hub by the wedging action and locks it on the tapered shaft. The pressure exerted by the nut therefore relieves the shear stress. The proportions of the key are as follows. If
D= diameter of the shaft in mm, d = diameter of the key, h= height of the key, b= width of the key. Width of key = 0.25 D Diameter of key = 4 W Height of key = 1.75 W
Pin Key
Fig 3.12 Pin Key
A pin key shown in the fig 3.12 is either a plain or a tapered rod driven in the hole partly drilled in the shaft and partly in the hub. Pin keys are used generally to hold small toothed wheels, hand wheels, levers, etc., on the spindles to prevent them from slipping. Sometimes a pin key is also used with shrunk- on wheel hub. In such cases, the hub of the wheel is board with a hole equal to or less than the diameter of the shaft. The hub is then heated to expand slightly and is driven on the shaft when it is still hot. As the hub cools, it contracts and grips the shaft. To provide an extra positive hold a pin key is also used. The proportions of the key are as follows.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
70
MACHINE DRAWING & COMPUTER GRAPHICS
If D= diameter of the shaft, d = diameter of the pin, Diameter of pin = 0.2 D Taper 1:50 Cone Key Cone key are used when pulleys having holes larger than shaft are to mounted on them. A cone key consists of three segments of a hollow conical bush as shown in fig 3.13. The hub of the pulley will have a tapered bore to suit that of the cone key. The segments of the cone key are driven between the shaft and the hub so as to hold them from slipping by the friction grip.
Fig 3.13 Cone Key DEFINITION Nominal SurfaceThe surface of an object is its exterior boundary. A surface that has been finished by any one of the machining processes contains numerous small peaks and valleys that deviate from the theoretical geometrically perfect surface, called nominal surface, Fig 3.14 .
Fig 3.14
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
71
MACHINE DRAWING & COMPUTER GRAPHICS
Roughness The cutting edges of the cutting tools and the abrasive grains of the grinding tools cause the texture of the surface to consist of surface irregularities. The spacing and the size of these valleys and peaks of the surface irregularities depend on the degree of sharpness of cutting tools and fineness of the abrasive grain. Roughness, as shown in Fig 3.14 B, is the microirregularity-of a surface produced by the cutting action of the edges of the tool or abrasive grains.
Waviness The waviness, as shown in Fig 3.14 C, is the surface undulations of larger magnitudes, i.e., surface irregularities with larger sizes and spacing than the roughness. Waviness may result from machine or work deflections, vibrations, warping, strains, or other causes. Roughness may be Considered as being superposed on a wavy surface as shown Figure. Lay Lay is the predominant direction of tool marks that make a characteristic pattern on a machined Surface. The direction of lay is determined by the production method employed.
Sampling Length Sampling Length is a particular length of the profile decided for the evaluation of the surface irregularities on any chosen portion of the machined surface. This length is also known as cut-off length.
The sampling length is selected depending upon the type of
machining process as indicated in Table. It is recommended to choose smaller value for the finer grade and larger value for the coarser grade for a given machining process when more than one values are given. Production Method And Surface Quality The value of surface roughness which is the arithmetical mean deviation from the mean line of the profile, is expressed in micrometer. Table shows the recommended values of surface roughness. it indicated in the specified place in the surface texture symbol. if the surface roughness is obtained by any production method other than machining the value
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
72
MACHINE DRAWING & COMPUTER GRAPHICS
surface roughness ,say 12.5 micrometer, is indicated in the basic symbol as shown in fig3.15 . if the surface roughness is obtained by removing the material by machining, the value of surface roughness, say 12.5 micrometer, should be indicated as shown in fig3.15 .if the surface roughness is to be obtained without the removal of the material or when it results from the previous production process, the value of surface roughness say 12.5 micrometer, should be indicated as shown in fig 3.15
Fig 3.15 Indication of Surface Roughness Values in Surface Texture Symbol
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
73
MACHINE DRAWING & COMPUTER GRAPHICS
Table 3.1 Surface Roughness Expected from Different Manufacturing Process
SYMBOL FOR LAY The direction of lay is represented in the symbol form, from the following series recommended by the Bureau of Indian Standards : =
┴XMCR
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
74
MACHINE DRAWING & COMPUTER GRAPHICS
75
Fig 3.16
Table illustrates the interpretation of these recommended symbols.
The lay is
indicated on to the right of the surface texture symbol as shown in Fig 3.16. Unless otherwise specified the surface roughness is measured across the direction of lay.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
INDICATION OF SURFACE ROUGHNESS FOR VARIOUS MACHINING OPERATIONS When it s required to produce the final surface texture by a particular machining method, this should be indicated in words like MILLED, REAMED, LAPPED, HONED, etc., on the horizontal extension of the longer leg of the symbol as shown in Fig 3.17.
Fig 3.17 When the surfaces are to receive additional treatment or coating, the type of treatment or coating like, CHROME PLATED, ENAMELLED, OXIDISED, CARBURISED, SAND BLASTED, etc., should be indicated on the same extension line as shown in Fig 3.17. Unless otherwise stated, as mentioned the numerical value of roughness applies to the surface texture after treatment of the coating.
When it is necessary to indicate the surface texture both before and after treatment, it should be explained by a suitable note or by specifying the value or grade of the surface texture before coating on the finished surface and the name of the coating and the value or grade of surface texture after coating on the symbolic thick chain line which represents the additional treatment as shown in Fig 3.17. The surface roughness grade N10 shown in Fig 3.17 is the texture required before coating and the surface texture of Nil is required after chrome plating. SURFACE TEXTURE SYMBOL WITH ALL THE CHARACTERISTICS Fig 3.18 shows a surface texture symbol with all the characteristics of the surface
corresponding grade number may be indicated.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
76
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 3.18
SYSTEM OF INDICATION SURFACE TEXTURE SYMBOLS ON DRAWING The surface texture symbol along with the inscriptions should be orientated such that they may be read from the bottom or right hand edge of the drawing sheet as explained in aligned system of dimensioning, which is the general system used for dimensioning the drawings.
Fig 3.19 shows the different methods of indicating the surface texture symbol on the drawing. The surface texture symbol may be placed with its apex touching the line representing the surface, or on the leader line terminating in an arrow on the surface, or on the extension line of the surface as shown in Figure.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
77
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 3.19 If it is not practicable to orient the surface texture symbol so as to be read from the bottom or right hand edge of the drawing sheet, it may be drawn in any position provided it does not carry any indication of machining method or machining allowances as shown in Fig. 3.19. Note that the roughness values are written so as to be read from the right hand edge of the drawing sheet.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
78
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT-V
INTRODUCTION A Screw is a cylinder or a conical rod with a helical groove cut on it. Its function is to transform the input motion of rotation into output motion of translation. A screw thread is a continuous helical ridge formed by cutting a helical groove on a cylinder or conical shank. Basically screw threads are used to fasten the parts together, or to transmit motion and so power, or for the relative adjustments of the adjacent parts. To perform these specific functions, threads of different profiles are used.
SCREW THREAD TERMINOLOGY The following definitions refer to the various terms used in screw threads. The various elements of a screw thread are shown in fig.4.1. The external thread is the thread cut on the outer surface of a rod. The internal thread is the thread cut on the inner surface of a hole.
Fig 4.1 ROOT: It is the bottom portion of the surface of a thread, either flat or rounded which joins the sides of the adjacent threads. CREST: It is the top portion of the surface of a thread, either flat or rounded which joins the sides of the same thread.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
79
MACHINE DRAWING & COMPUTER GRAPHICS
FLANK: It is the surface of a thread that connects the crest with the root and also it offers the surface contact with its counterpart.
ANGLE OF THE THREAD: It is the angle included between the sides of the two adjacent threads and is measured on an axial plane.
DEPTH OF THE THREAD: It is distant between the crest and the root of a thread which is measured normal to the axis on an axial plane. It is designated as h3.
NOMINAL DIAMETER: It is the diameter of the cylindrical rod on which the threads are cut. This diameter specifies the size of the screw.
MAJOR DIAMETER: It is the diameter of an imaginary coaxial cylinder which bounds the crests of an external thread or the roots of an internal thread. D and d denote the major diameters of the internal and external threads respectively. MINOR DIAMETER: It is the diameter of an imaginary coaxial cylinder which bounds the roots of an external threads, or the crests of an internal threads. D1 and d3 denote the minor diameters of the internal and external threads respectively. PITCH DIAMETER: It is the diameter of the thread at which an imaginary coaxial cylinder that can passed so as to cut the thread so that the width of the cut thread will be equal to the width of the groove.D2 and d2 denote the pitch diameters of internal and external threads respectively.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
80
MACHINE DRAWING & COMPUTER GRAPHICS
HEIGHT OF THE FUNDAMENTAL TRIANGLE: The imaginary equilateral triangle which bounds a V-thread is called a fundamental triangle. Its height, H is measured normal to the axis on an axial plane.
PITCH: It is the distance from a point on a screw thread to a corresponding point on the next thread, measured parallel to the axis. It may be indicated as the distance from crest to crest, or from root to root, but former is the convention.
LEAD: It is the axial distance advanced by a nut for its one full turn over a threaded rod. It is also defined as the product of the pitch and number of starts.
Basic profiles or forms of screw threads The profile of a screw thread is based on whether it functions as a fastening device or a power transmission element. The profile is triangular, known as V thread in the former, and square or its modified in the latter. Thus the two basic profiles, or forms of screw threads are: (i) V threads (ii) Square thread.
V-Threads Bureau of Indian Standards(BIS) adopts ISO metric thread profile as a basic profile of screw threads. The V-threads is in the form of symmetrical “V” ,the angle of thread is 60˚. The roots of both the internal and external threads are rounded, while the crests are parallel to the axis of the screw.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
81
MACHINE DRAWING & COMPUTER GRAPHICS
Fig 4.2
Square thread The square thread has its flanks at right angle to the axis, so that they are parallel to each other. For the same nominal diameter, the pitch of the square thread is more than that of the V-thread, hence the square thread provides more axial movement. The depth and the thickness of the thread are equal and equal to half the pitch.
The square thread is generally used for high power transmission such as screw jack, vice, lead screw of lathe etc.,
Fig 4.3
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
82
MACHINE DRAWING & COMPUTER GRAPHICS
Left hand threads A left hand thread is one which advances into the nut, when turned in a counter clockwise direction, and the slope of the lines representing the thread will be downward from left to right. An abbreviation LH is used to indicate the left hand thread. unless otherwise specified, a thread should be considered as a right hand thread.
Practical application of these threads is made in coupler-nut or turn-buckle.
Fig 4.4
Right hand threads:
Fig 4.5
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
83
MACHINE DRAWING & COMPUTER GRAPHICS
A right hand threads is one which advances into the nut, when turned in a clockwise direction. It can be seen from the above fig. that when the axis of screw is vertical, the lines representing the thread will have slope downwards from right to left.
Internal Thread The internal thread is a continuous helical ridge formed by cutting a helical groove on inside of a cylinder or conical shank. The conventional representation of the Internal Thread shown in Fig.
External Thread The external thread is a continuous helical ridge formed by cutting a helical groove on outside of a cylinder or conical shank. The conventional representation of the External Thread shown in Fig.
4.8 V-Threads
Fig 4.6 Whitworth thread
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
84
MACHINE DRAWING & COMPUTER GRAPHICS
This thread was introduced by Sir Joseph Whitworth and was standardized as British Standard thread, abbreviated as BSW. The profile of this thread with standard proposition is shown in fig 4.6. It has a thread angle of 55째 and is rounded off at the crest and root which renders it less liable to damage than a sharp V thread. Square Thread The basic form of a square thread is shown in fig 4.7. The flanks or the sides of this thread are perpendicular to the axis of the thread. The depth and the thickness of the thread is equal to half the pitch.
Fig 4.7
Standard form of square thread:
Fig 4.8
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
85
MACHINE DRAWING & COMPUTER GRAPHICS
86
The profile of the square thread adopted by the Bureau of Indian Standards in fig 4.8 . The depth of the external thread is equal to half the pitch. The sharp corners at the root of the external threads are rounded off to the radius R-0.25 mm The depth of the internal threads is equal to 0.5P+0.25mm. The sharp corners at the crest of the internal threads are chamfered to 0.25mm*45째.
DESIGNATION OF
THREADS Threads are designated by indicating the type of thread, the major diameter and the pitch.V-threads of ISO profile are designated by the letter M followed by the major diameter and the pitch, the two being separated by x symbol. For example, V-threads of major diameter 10 mm and pitch 1.25 mm is designated as M10 x l.25 as shown in Fig 4.9.
Sometimes when the V-threads are designated without indicating the pitch, for example Ml0 as shown in Figure, it will mean that the threads are cut with coarse pitch, whose value is to be obtained from the relevant Indian Standard fig 4.9 Codes.
Fig. 4.9 FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Multistart threads are designated by specifying the number of starts as shown in Figure.
The screw threads are always considered as right hand unless otherwise specified. When left hand threads are to be designated the abbreviation LH must be used as shown in Figure.
The square threads are designated by the ď ż symbol as shown in Fig 4.10. The trapezoidal threads are designated by the letters Tr as shown in Fig 4.11.
Fig 4.10
Fig 4.11
BOLTS AND NUTS A bolt is a fastening element comprising of a head at one end and a threaded portion over its cylindrical shank at the other end. The parts to be fastened temporarily by bolts and
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
87
MACHINE DRAWING & COMPUTER GRAPHICS
nuts, admit the bolts through the holes in them having suitable clearances. The projected threaded end of the bolt in turn now admits the washer and nut, an internally threaded member, which after sufficient turn offers necessary clamping grip. Bolts and nuts of various shapes are used for different purposes but the hexagonal head and square head are very common. Although the square shape provides a better spanner grip than the hexagon, but needs one-fourth of a turn to bring it into the same position for inserting spanner again, whereas a hexagon need only one-sixth of a turn and hence preferred. Although an octagonal shape would require one-eighth of a turn, the spanner grip reduces a it is more liable to slip. In general, the hexagonal bolts and nuts are preferred for fastenings in machines wherever the space and other conditions permit. The square head bolts are used instead of hexagonal bolts when frequent loosening and tightening is required, for example, on job holding devices like, vices, tools posts in machines, etc.
DRAWING OF HEXAGONAL BOLT AND NUT In machine drawing practice, hexagonal bolts and nuts are drawn all most in all the drawings. Drawing of these to the actual dimensions involves laborious drafting work arid unnecessary time. Since the bolts and nuts are standard items, they need not be drawn in the assembly drawings to accurate sizes, instead they are drawn conventionally to empirical proportions listed in Table. All the. proportions are expressed in terms of the major diameter of the bolt and nut.
Step by Step Procedure: I Step : Draw the shank of the bolt equal to the given diameter d and length. The thickness of bolt head equal to 0.8d and the thickness of nut equal to 0.9d are marked. Measure the width across corners equal to 2dand complete the three faces of the bolt head and the nut in thin lines.
The right view of the bolt and nut assembly is drawn as follows. With any point C 1 on the axis as centre and radius equal to d, draw a thin circle. Draw the vertical diameter 1-2 of this circle. With 1 and 2 as centres and radius equal to d cut the circle on either side of the vertical axis and inscribe the hexagon. The chamfer circle is drawn as a thick circle with the centre C1 and radius C1E.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
88
MACHINE DRAWING & COMPUTER GRAPHICS
89
TABLE 4.1 Empirical Proportions of Hexagon and Square Head Bolt & Nut Detail
Proportion
Nominal Diameter
d = Size of Bolt or Nut, mm
Width Across Flats
s = 1.5d + 3 mm
Width Across Corners
e = 2d
Thickness of Bolt Head
k = 0.8 d
Thickness of Nut
m = 0.9 d
Root Diameter
d1 = d – (2 X Depth of Thread) or = d (4 X Thickness of Lines) Or = 0.9 d (approximate)
Length of Bolt
l = As specified
Thread Length
b = 2d + 6 mm (for l < 150 mm) = 2d + 12 mm (for l > 150 mm)
Radius of Bolt End
r = d (for spherical ends)
Chamfer of Bolt End
z = Depth of Thread X 45 or
O
= 0.1 d (Approximate) Chamfer Angle of Bolt Head &
O
= 30
Nut
II Step : The chamfer arcs in the three face view of bolt head and nut are drawn as O
follows. Through the corner B, draw a line at 30 to the axis of the bolt or nut to cut it at O1, With O1 as centre and radius O1A draw the chamfer arc in the centre face. The chamfer arcs on the two side faces are drawn as follows. Draw the perpendicular bisector of BC to cut BO 1 at O2. With O2 as centre and radius O2D draw the chamfer arc. Repeat the construction on the other side face.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
90
III Step : The chamfer lines on he side faces of the three face views of the bolt head O
and nut are drawn as follows. Through the points P and Q draw lines inclined at 30 to the O
flat face of the bolt head or nut. The end of the bolt is chamfered to 0.1 d X 45 .
The threaded portion of the shank is indicated by drawing two thin lines at a distance equal to d1 = 0.9d. The root circle in the right view is represented by a thin three-fourth of a circle drawn with centre CT and diameter O.9d.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
The two face view of the bolt head and the nut is projected from the side view. If the side view is not drawn, then the distance across the flats is measured equal to 1.5d + 3mm. The chamfer arcs in the two face view are drawn as follows. Project P to get X. Mark Y the midpoint of FG. Draw the perpendicular bisector of XY and FG to intersect each other at 0 3. With centre 03 and radius 03Y draw the chamfer arc. Repeat the construction on the other face.
DRAWING OF SQUARE HEAD BOLT The square head bolt and nut are drawn to the proportions shown in Table. I Step: Draw the shank of the bolt equal to the given diameter d and the length of the bolt. The thickness of the bolt head equal to 0.8d and the thickness of the nut equal to 0.9d are marked. The right view of the bolt and the nut assembly is drawn as follows. With any point C1 on the axis as centre and diameter equal to 1.5d + 3mm draw the chamfer circle. Draw a square circumscribing the chamfer circle with its sides inclined at 45째 to the axis. Project the corners 1 and 2 to get points P. Draw a thick circle with diameter to indicate the nominal diameter.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
91
MACHINE DRAWING & COMPUTER GRAPHICS
II Step: The chamfer arcs in the view across the corners of the bolt and nut are drawn as follows. Through the corner P, draw a line inclined at 30째 to the axis. Draw the perpendicular bisector of PQ to intersect the 30째 line at O. With O as centre and radius. OR draw the chamfer arc. Repeat the construction on the other face.
III Step: The chamfer line is drawn at 30째 to the flat face of the bolt head and nut. The threaded portion on the shank of the bolt is indicated conventionally by drawing two thin lines spaced at a distance equal to the root diameter d, O.9d. The root circle in the right view is represented by a thin three-fourth of a circle drawn with centre C1 and diameter 0.9d. The end of the bolt is chamfered to 0.1d x 45째.
RIVETED HEAD A riveted joint is a permanent type of fastener used to join the metal plates or rolled steel sections together. Riveted joints are extensively used in structural works such as bridges and roof trusses and in the construction of pressure vessels such as storage tanks, boilers, etc. Although welded joints are best suited to several of these applications than the riveted joints, however, riveted joints are ideal in cases where the joints will be subjected to pronounced vibrating loads. Riveted joints are also used when a non-metallic plate and a metallic plate are to be connected together. They are also used when the joints are not expected to be heated while joining as in welding, which may cause warping and tempering of the finished surfaces of the joints.
The disadvantages of riveted joints are (i) more metal is removed while making of the holes, which weakens the working cross sections along the line of centres of the rivet holes, and (ii) weight of the rivets increases the weight of the riveted members. Differences between a Bolt and a Rivet As a fastener, a rivet resembles a bolt, but differs from it in the shape and the application as well. Although the shape of a rivet is similar to that of a bolt, unlike the bolts, its shank end is not threaded. With regards to the application, it is used as a Permanent fastener to withstand shear forces acting perpendicular to its axis, whereas a bolt is used as a temporary fastener to Withstand axial tensile forces.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
92
MACHINE DRAWING & COMPUTER GRAPHICS
Rivet A rivet is a round rod made either from mild steel or nonferrous materials such as copper, aluminium, etc., with a head of any one of the shapes shown in Figure, formed at one end during its manufacture and its tail end being slightly tapered as shown in Figure. The length of the shank of the rivet must be sufficient enough to accommodate the connecting plates and also provide enough material for forming a head at its shank end. In general, the length of the shank of the rivet will be equal to sum of the thicknesses of the connecting plates plus 1.5 to 1.7 times the diameter of the rivet.
If
l = length of the shank of the rivet d = diameter of rivet t = thickness of each of the connecting plates
then, l =ď&#x192;Ľ
TYPES Various types of rivet heads for use in general engineering work and boiler work as recommend by the Bureau of Indian Standards are shown in Figure. The different proportions of these rivet heads are given in terms of the nominal diameter d of the rivet. The rivet heads to be used for general purposes for diameters below 12 mm are specified in the Indian Standard Code IS: 2155-1962 and for diameters between 12 and 48 mm are specified in the Indian Standard Code IS: 1929-1961. The rivet heads to be used for boiler work are specified in the Indian Standard Code IS: 1928-1961. The rivet heads to be used for ship building are specified in the Indian Standard Code IS : 4732-1968.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
93
MACHINE DRAWING & COMPUTER GRAPHICS
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
94
MACHINE DRAWING & COMPUTER GRAPHICS
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
95
MACHINE DRAWING & COMPUTER GRAPHICS
103
UNIT VI INTRODUCTION TO COMPUTER GRAPHICS
UNIT STRUCTURE 6.0 Introduction 6.1 Objectives 6.2 A Survey of Computer Graphics 6.2.1 Computer-Aided Design 6.2.2 Presentation Graphics 6.2.3 Computer Art 6.2.4 Entertainment 6.2.5 Education and Training 6.2.6 Visualization 6.2.7 Image Processing 6.2.8 Graphical User Interface 6.3 Video Display Devices 6.3.1 Refresh Cathode Ray Tubes 6.3.2 Raster Scan Displays 6.3.3 Random Scan Displays 6.3.4 Color CRT Monitors 6.3.5 Direct View Storage Tubes 6.3.6 Flat Panel Displays 6.3.7 Three Dimensional Viewing Devices
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
104
6.3.8 Stereoscopic and Virtual Reality Systems 6.4 Raster Scan Systems 6.4.1 Video Controller 6.4.2 Raster Scan Display Processor 6.5 Random Scan Systems 6.6 Input Devices 6.6.1 Keyboards 6.6.2 Mouse 6.6.3 Trackball and Spaceball 6.6.4 Joystick 6.6.5 Data Glove 6.6.6 Digitizer 6.6.7 Image Scanner 6.6.8 Touch Panel 6.6.9 Light Pen 6.6.10 Voice Systems 6.7 Hard Copy Devices 6.8 Summary 6.9 Self Assessment questions 6.10 Answers to Self Assessment questions INTRODUCTION Computers have become a powerful tool for the rapid and economical production of pictures. Graphics capabilities for both two-dimensional and three-dimensional applications are now
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
105
common on general purpose computers. Various devices are available for data input on graphics workstations.
6.1 OBJECTIVES At the end of this unit, you should be able to
Know the introductory concepts of computer graphics and the survey of computer graphics
Familiar with the various video display devices
Have a thorough study about the raster and random scan systems
Study the various graphical input devices.
6.2 A SURVEY OF COMPUTER GRAPHICS Computers have become a powerful tool for the rapid and economical production of pictures. Computer graphics used routinely in science, engineering, medicine, business, industry, government, art, entertainment, advertising, education, and training.
6.2.1 Computer-Aided Design CAD, computer-aided design methods are now routinely used in the design of buildings, automobiles, aircraft, watercraft, spacecraft, computers, textiles. Objects are first displayed in a wireframe outline form that shows the overall shape and internal features of objects. Wireframe displays also allow designers to quickly see the effects of interactive adjustments to design shapes. Animations are often used in CAD applications. Real-time animations using wireframe displays on a video monitor are useful for testing performance of a vehicle or system. Wireframe displays allow the designer to see into the interior of the vehicle and to watch the behavior of inner components during motion. Animations in virtual-reality environments are used to determine how vehicle operators are affected by certain motions. The manufacturing process is also tied in to the computer description of designed objects to automate the construction of the product. A circuit board layout, for example can be transformed into a description of the individual processes needed to construct the layout.
Architects
use
interactive
graphics methods to lay out floor plans. The positioning of rooms, doors, windows, stairs, shelves, counter, and other building features. Working from the display of a building layout on a video monitor, an
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
106
electrical designer can try out arrangements for wiring, electrical outlets, and fire warning systems. With virtual-reality systems, designers can even go for a simulated “walk” through the rooms or round the outsides of buildings.
6.2.2 Presentation Graphics Another major application area is presentation graphics, used to produce illustrations for reports or to generate 35-mm slides or transparencies for use with projectors. Presentation graphics is commonly used to summarize financial, statistical, mathematical, scientific, and economic data for research reports, managerial reports, consumer information bulletins, and other types of reports. Typical examples of presentation graphics are bar charts, line graphs, surface graphs, pie charts, and other displays showing relationships between multiple parameters.
6.2.3 Computer Art Artists use a variety of computer methods, including special-purpose hardware, artist’s paintbrush programs (such as Lumena), other paint packages (such as PixelPaint and SuperPaint), specially developed software, symbolic mathematics packages (such as mathematica), CAD packages, desktop publishing software, and animation packages that provide facilities for designing object shapes and specifying object motions. Paintbrush program allows artists to “paint” pictures on the screen of a video monitor. The picture is usually painted electronically on a graphics tablet (digitizer) using a stylus, which can stimulate different brush strokes, brush widths, and colors. To create pictures the artist uses a combination of threedimensional modeling packages, texture mapping, drawing programs, and CAD software. For “mathematical” art the artist uses a combination of mathematical functions, fractal procedures, Mathematica software, ink-jet printers, and other system to create a variety of three-dimensional and twodimensional shapes and stereoscopic image pairs.
6.2.4 Entertainment Computer graphics methods are now commonly used in making motion pictures, music videos, and television shows. Graphics objects can be combined with the live action or graphics and image processing techniques can be used to produce a transformation of one person or object into another (morphing).
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
107
6.2.5 Education and Training Models of physical systems, physiological systems, population trends, or equipment, such as the color-coded diagram help trainees to understand the operation of the system. Examples of specialized systems are the simulators for practice sessions or training of ship captains, aircraft pilots, heavy-equipment operators, and air traffic-control personnel. Some simulators have no video screens; for example, a flight simulator with only a control panel for instrument flying.
6.2.6 Visualization Producing graphical representations for scientific, engineering, and medical data sets and processes is generally referred to as scientific visualization. Business visualization is used in connection with data sets related to commerce, industry, and other nonscientific areas.
6.2.7 Image Processing In computer graphics, a computer is used to create a picture. Image processing, on the other hand, applies techniques to modify or interpret existing pictures, such as photographs and TV scans. Two principal applications of image processing are (1) improving picture quality and (2) machine perception of visual information, as used in robotics. Medical applications also make extensive use of image-processing techniques for picture enhancements, in tomography and in simulations of operations. Tomography is a technique of X-ray photography that allows cross-sectional views of physiological systems to be displayed. Both computed X-ray tomography (CT) and position emission tomography (PET) use projection methods to reconstruct across sections from digital data. These techniques are also used to monitor internal functions and show cross sections during surgery. Other medical imaging techniques include ultrasonics and nuclear medicine scanners. With ultrasonics, high frequency sound waves, instead of X-rays, are used to generate digital data. Nuclear medicine scanners collect digital data from radiation emitted from ingested radionuclides and plot color-coded images.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
108
The last application is generally referred to as computer-aided surgery. Two-dimensional cross sections of the body are obtained using imaging techniques. Then the slices are viewed and manipulated using graphics methods to simulate actual surgical procedures and to try out different surgical cuts. 6.2.8 Graphical User Interfaces It is common now for software packages to provide a graphical interface. A major component of a graphical interface is a window manager that allows a user to display multiple-window areas. Each window can contain a different process that can contain graphical or nongraphical displays.Interfaces also display menus and icons for fast selection of processing operations or parameter values. An icon is a graphical symbol that is designed to look like the processing option it represents. 6.3 VIDEO DISPLAY DEVICES Typically, the primary output device in a graphics system is a video monitor. The operation of most video monitors is based on the standard cathode-ray tube (CRT) design. 6.3.1 Refresh Cathode-Ray Tubes A beam of electrons (cathode rays) emitted by an electron gun, passes through focusing and deflection systems that direct the beam toward specified positions on the phosphor-coated screen. The phosphor then emits a small spot of light at each position contacted by the electron beam. Because the light emitted by the phosphor fades very rapidly, some method is needed for maintaining the screen picture. One way to keep the phosphor glowing is to redraw the picture repeatedly by quickly directing the electron beam back over the same points. This type of display is called a refresh CRT. Persistence is defined as the time it takes the emitted light from the screen to decay to one-tenth of its original intensity. Lower-persistence phosphors require higher refresh rates to maintain a picture on the screen without flicker. A phosphor with low persistence is useful for animation; a high-persistence phosphor is useful for displaying highly complex, static pictures. The maximum number of points that can be displayed without overlap on a CRT is referred to as the resolution. A more precise definition of resolution is the number of points per centimeter that can be plotted horizontally and vertically, although it is often simply stated as the total number of points in each direction. High-resolution systems are often referred to as high-definition systems. Another property of video monitors is aspect ratio. This number gives the ratio of vertical points to horizontal. The following diagram shows the basic design of a magnetic deflection CRT.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
109
Figure 1: Basic design of a magnetic deflection CRT
6.3.2 Raster Scan Displays The most common type of graphics monitor employing a CRT is the raster-scan display, based on television technology. In a raster-scan system, the electron beam is swept across the screen, one row at a time from top to bottom. As the electron beam moves across each row, the beam intensity is turned on and off to create a pattern of illuminated spots. Picture definition is stored in a memory area called the refresh buffer or frame buffer. This memory area holds the set of intensity values for all the screen points. Stored intensity values are then retrieved from the refresh buffer and â&#x20AC;&#x153;paintedâ&#x20AC;? on the screen one row (scan line) at a time. Each screen point is referred to as a pixel or pel (shortened forms of picture element). Home television sets and printers are examples of other systems using raster-scan methods. In a simple black-and-white system, each screen point is either on or off, so only one bit per pixel is needed to control the intensity of screen positions. For a bi-level system, a bit value of 1 indicates that the electron beam is to be turned on at that position, and a value of 0 indicates that the beam intensity is to be off. On a black-and-white system with one bit per pixel, the frame buffer is commonly called a bitmap. For systems with multiple bits per pixel, the frame buffer is often referred to as a pixmap. Refreshing on raster-scan displays is carried out at the rate of 60 to 80 frames per second, although some systems are designed for higher refresh rates. Sometimes, refresh rates are described in units of cycles per second, or Hertz (Hz), where a cycle corresponds to one frame. At the end of each scan line, the electron beam returns to the left side of the screen to begin displaying the next scan line. The return to the left of the screen, after refreshing each scan line, is called the horizontal retrace of the electron beam. And at the end of each frame (displayed in1/80th to 1/60th of a second), the electron beam returns (vertical retrace) to the top left corner of the screen to begin the next frame. The following
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
110
figure shows the raster scan system that displays an object as a set of discrete points across each scan line.
Figure 2: Raster scan system that displays an object as a set of discrete points across each scan line 6.3.3 Random Scan Displays When operated as a random-scan display unit, a CRT has the electron beam directed only to the parts of the screen where a picture is to be drawn. Random-scan monitors draw a picture one line at a time and for this reason are also referred to as vector displays (or stroke-writing or calligraphic displays). A pen plotter operates in a similar way and is an example of a random-scan, hard-copy device. Refresh rate on a random-scan system depends on the number of lines to be displayed. Picture definition is now stored as a set of line-drawing commands in an area of memory referred to as the refresh display file. Sometimes the refresh display file is called the display list, display program, or simply the refresh buffer. Random-scan systems are designed for line drawing applications and cannot display realistic shaded scenes. 6.3.4 Color CRT Monitor A CRT monitor displays color pictures by using a combination of phosphors that emit differentcolored light. The two basic techniques for producing color displays with a CRT are the beam-penetration method and the shadow-mask method.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
111
The beam-penetration method for displaying color pictures has been used with random-scan monitors. Two layers of phosphor, usually red and green, are coated onto the inside off the CRT screen, and the displayed color depends on how far the electron beam penetrates into the phosphor layers. A beam of slow electrons excites only the outer red layer. A beam of very fast electrons penetrates through the red layer and excites the inner green layer. At intermediate beam speeds, combination of red and green light is emitted to show two additional colors, orange and yellow. Shadow-mask methods are commonly used in raster-scan systems (including color TV) because they produce a much wider range of colors than the beam-penetration method. A shadow-mask CRT has three phosphor color dots at each pixel position. One phosphor dot emits a red light, another emits a green light, and the third emits a blue light. This type of CRT has three electron guns, one for each color dot, and a shadow-mask grid just behind the phosphor-coated screen. The three electron beams are deflected and focused as a group onto the shadow mask, which contains a series of holes aligned with the phosphor-dot patterns. When the three beams pass through a hole in the shadow mask, they activate a dot triangle, which appears as a small color spot on the screen. The phosphor dots in the triangles are arranged so that each electron beam can activate only its corresponding color dot when it passes through the shadow mask. Color CRTs in graphics systems are designed as RGB monitors. These monitors use shadowmask methods and take the intensity level for each electron gun (red, green, and blue) directly from the computer system without any intermediate processing. An RGB color system with 24 bits of storage per pixel is generally referred to as a full-color system or a true-color system. The following figure shows a random scan system that draws the component lines of an object in any order specified.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
112
Figure 3: A random scan system that draws the component lines of an object in any order specified
6.3.5 Direct-View Storage Tube An alternative method for maintaining a screen image is to store the picture information inside the CRT instead of refreshing the screen. A direct-view storage tube (DVST) stores the picture information as a charge distribution just behind the phosphor-coated screen. Two electron guns are used in DVST. One, the primary gun, is used to store the picture pattern; the second, the flood gun, maintains the picture display. A DVST monitor has both disadvantages and advantages compared to the refresh CRT. Because no refreshing is needed, very complex pictures can be displayed at very high resolutions without flicker. Disadvantages of DVST systems are that they ordinarily do not display color and that selected parts of a picture cannot be erased. The following figure shows the operation of a delta-delta shadow mask CRT.
Figure 4: Operation of a delta-delta shadow mask CRT 6.3.6 Flat-Panel Displays The term flat-panel display refers to a class of video devices that have reduced volume, weight, and power requirements compared to a CRT. A significant feature of flat-panel displays is that they are thinner that CRTs and we can hang them on walls or wear them on our wrists.We can separate flat-panel
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
113
displays into two categories: emissive displays and nonemissive displays. The emissive displays (or emitters) are devices that convert electrical energy into light. Plasma panels, thin-film electroluminescent displays, and light-emitting diodes are examples of emissive displays. Nonemmissive displays (or nonemitters) use optical effects to convert sunlight or light from some other source into graphics patterns. The most important example of a nonemissive flat-panel display is a liquid-crystal device. Plasma panels, also called gas-discharge displays, are constructed by filling the region between two glass plates with a mixture of gases that usually includes neon. Thin-film electroluminescent displays are similar in construction to a plasma panel. The difference is that the region between the glass plates is filled with a phosphor, such as zinc sulfide doped with manganese, instead of a gas. A third type of emissive device is the light-emitting diode (LED). A matrix of diodes is arranged to form the pixel positions in the display, and picture definition is stored in a refresh buffer. As in scan-line refreshing of a CRT, information is read from the refresh buffer and converted to voltage levels that are applied to the diodes to produce the light patterns in the display. Liquid-crystal displays (LCDs) are commonly used in small systems, such as calculators and portable, laptop computers. The term liquid crystal refers to the fact that these compounds have a crystalline arrangement of molecules, yet they flow like a liquid. 6.3.7 Three-Dimensional Viewing Devices Graphics monitors for the display of three-dimensional scenes have been devised using a technique that reflects a CRT image from a vibrating, flexible mirror. A Genisco Space Graph uses a vibrating mirror to project three dimensional objects into a 25cm by 25cm by 25cm volume. 6.3.8 Stereoscopic and Virtual Reality Systems Stereoscopic views provide a three-dimensional effect by presenting a different view to each eye of an observer so that scenes appear to have depth. One way to produce a stereoscopic effect is to display each of the two views with a raster system on alternate refresh cycles. Stereoscopic viewing is also a component in virtual-reality systems. An interactive virtual reality environment can also be viewed with stereoscopic glasses and a video monitor instead of a headset. 6.4 RASTER SCAN SYSTEMS Interactive raster graphics systems typically employ several processing units. In addition to the central processing unit, or CPU, a special-purpose processor, called the video controller or display controller, is used to control the operation of the display device.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
114
6.4.1 Video Controller A fixed area of the system memory is reserved for the frame buffer, and the video controller is given direct access to the frame-buffer memory. Frame-buffer locations, and the corresponding screen positions, are referenced in Cartesian coordinates. The coordinate origin is defined at the lower left screen corner. The screen surface is then represented as the first quadrant of a two-dimensional system, with positive x values increasing to the right and positive y values increasing from bottom to top. (On some personal computers, the coordinate origin is referenced at the upper left corner of the screen, so the y values are inverted.) Scan lines are then labeled from ymax at the top of the screen to 0 at the bottom. Along each scan line, screen pixel positions are labeled from 0 to x max. Two registers are used to store the coordinates of the screen pixels. Initially, the x register is set to 0 and the y register is set to ymax. The value stored in the frame buffer for this pixel position is then retrieved and used to set the intensity of the CRT beam. Then the x register is incremented by 1, and the process repeated for the next pixel on the top scan line. This procedure is repeated for each pixel along the scan line. A number of other operations can be performed by video controller, besides the basic refreshing operations. For various applications, the video controller can retrieve pixel intensities from different memory areas on different refresh cycles. In high-quality systems, for example, two frame buffers are often provided so that one buffer can be used for refreshing while the other is being filled with intensity values. Then the two buffers can switch roles. This provides a fast mechanism for generating real-time animations, since different views of moving objects can be successively loaded into the refresh buffers. Finally, some systems are designed to allow the video controller to mix the frame-buffer image with an input image from a television camera or other input device. The following figure shows the architecture of a simple raster graphics system.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
115
Figure 5: Architecture of a simple raster graphics system
6.4.2 Raster Scan Display Processor The organization of a raster system containing a separate display processor, sometimes referred to as a graphics controller or a display coprocessor. The purpose of the display processor is to free the CPU from the graphics chores. In addition to the system memory, a separate display-processor memory area can also be provided. A major task of the display processor is digitizing a picture definition given in an application program into a set of pixel-intensity values for storage in the frame buffer. This digitization process is called scan conversion. One way to do this is to store each scan line as a set of integer pairs. One number of each pairs indicates an intensity value, and the second number specifies the number of adjacent pixels on the scan line that are to have that intensity. This technique, called run-length encoding, can result in a considerable saving in storage space if a picture is to be constructed mostly with long runs of a single color each. The disadvantages of encoding runs are that intensity changes are difficult to make and storage requirements actually increase as the length of the runs decreases.
6.5 RANDOM SCAN SYSTEMS Graphics commands in the application program are translated by the graphics package into a display file stored in the system memory. This display file is accessed by the display processor to refresh the screen. The display processor cycles through each command in the display file program once during every refresh cycle. Sometimes the display processor in a random-scan system is referred to as a display processing unit or a graphics controller. The following figure shows the architecture of a random scan system with a display processor.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
116
Figure 6: Architecture of a random scan graphics system with a display processor
6.6 INPUT DEVICES
6.6.1 Keyboards An alphanumeric keyboard on a graphics system is used primarily as a device for entering text strings. The keyboard is an efficient device for inputting such nongraphic data as picture labels associated with a graphics display. Cursor-control keys and function keys are common features on general-purpose keyboards. Function keys allow users to enter frequently used operations in a single keystroke, and cursor-control keys can be used to select displayed objects or coordinate positions by positioning the screen cursor. Other types of cursor-positioning devices, such as a trackball or joystick, are included on some keyboards.
6.6.2 Mouse A mouse is small hand-held box used to position the screen cursor. Wheels rollers on the bottom of the mouse can be used to record the amount and direction of movement. Another method for detecting mouse motion is with an optical sensor. The mouse is moved over a special mouse pad that has a grid of horizontal and vertical lines. The optical sensor detects movement across the lines in the grid.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
117
6.6.3 Trackball and Spaceball As the name implies, a trackball is a ball that can be rotated with the fingers or palm of the hand. While a trackball is a two-dimensional positioning device, a spaceball provides six degrees of freedom. Unlike the trackball, a spaceball does not actually move.
6.6.4 Joystick A joystick consists of a small, vertical lever (called the stick) mounted on a base that is used to steer the screen cursor around. Most joysticks select screen positions with actual stick movement; others respond to pressure on the stick. The distance that the stick is moved in any direction from its center position corresponds to screen-cursor movement in that direction.
6.6.5 Data Glove Data glove can be used to grasp a “virtual” object. The glove is constructed with a series of sensors that detect hand and finger motions.
6.6.6 Digitizer A common device for drawing, painting, or interactively selecting coordinate positions on an object is a digitizer. These devices can be used to input coordinate values in either a two-dimensional or a three-dimensional space. One type of digitizer is the graphics tablet (also referred to as a data tablet), which is used to input two-dimensional coordinates by activating a hand cursor or stylus at selected positions on a flat surface. A hand cursor contains cross hairs for sighting positions, while a stylus is a pencil-shaped device that is pointed at positions on the tablet. Acoustic (or sonic) tablets use sound waves to detect a stylus position. Either strip microphones or point microphones can be used to detect the sound emitted by an electrical spark from a stylus tip. The position of the stylus is calculated by timing the arrival of the generated sound at the different microphone positions. An advantage of two-dimensional acoustic tablets is that the microphones can be placed on any surface to form the “tablet” work area.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
118
6.6.7 Image Scanner Drawings, graphs, color and black-and-white photos, or text can be stored for computer processing with an image scanner by passing an optical scanning mechanism over the information to be stored.
6.6.8 Touch Panel As the name implies, touch panels allow displayed objects or screen positions to be selected with the touch of a finger. A typical application of touch panels is for the selection of processing options that are represented with graphical icons. Optical touch panels employ a line of infrared light-emitting diodes (LEDs) along one vertical edge and along one horizontal edge of the frame.
6.6.9 Light Pen Pencil-shaped devices are used to select screen positions by detecting the light coming from points on the CRT screen. They are sensitive to the short burst of light emitted from the phosphor coating at the instant the electron beam strikes a particular point. An activated light pen, pointed at a spot on the screen as the electron beam lights up that spot, generates an electrical pulse that causes the coordinate position of the electron beam to be recorded. Although light pens are still with us, they are not as popular as they once were since they have several disadvantages compared to other input devices that have been developed. And prolonged use of the light pen can cause arm fatigue.
6.6.10 Voice Systems Speech recognizers are used in some graphics workstations as input devices to accept voice commands. The voice-system input can be used to initiate graphics operations or to enter data. These systems operate by matching an input against a predefined dictionary of words and phrases. A dictionary is set up for a particular operator by having the operator speak the command words to be used into the system.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
119
6.7 HARD-COPY DEVICES We can obtain hard-copy output for our images in several formats. The quality of the pictures obtained from a device depends on dot size and the number of dots per inch, or lines per inch, that can be displayed. To produce smooth characters in printed text strings, higher-quality printers shift dot positions so that adjacent dots overlap. Impact printer press formed character faces against an inked ribbon onto the paper. A line printer is an example of an impact device. Nonimpact printers and plotters use laser techniques, ink-jet sprays, xerographic processes (as used in photocopying machines), electrostatic methods, and electro thermal methods to get images onto paper. Character impact printers often have a dot-matrix print head containing a rectangular array of producing wire pins, with the number of pins depending on the quality of the printer. In a laser device, a laser beam creates a charge distribution on a rotating drum coated with a photoelectric material, such as selenium. Toner is applied to the drum and then transferred to paper. Ink-jet methods produce output by squirting ink in horizontal rows across a roll of paper wrapped on a drum. The electrically charged ink stream is deflected by an electric field to produce dot-matrix patterns. An electrostatic device places a negative charge on the paper, one complete row at a time along the length of the paper. Then the paper is exposed to a toner. The toner is positively charged and so is attracted to the negatively charged areas. Electro thermal methods use heat in a dot-matrix print head to output patterns on heat-sensitive paper.
1.8
SUMMARY In this unit the major hardware and software features of computer graphics systems are
surveyed. The predominant graphics display device is the raster refresh monitor. Flat panel display technology is commonly used and replaces raster displays in the near future. For graphical input, keyboards, button boxes and dials are used to input text, data values. Hard copy devices for graphics workstations include standard printers and plotters.
1.9
SELF ASSESSMENT QUESTIONS
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
120
Answer the following questions
1.
Define the term scientific visualization.
2.
________________ are commonly used in calculators and laptop computers.
3. Define the term resolution. 4. What is a trackball? 5. Name some of the hard copy devices.
1.10
1.
ANSWERS TO SELF ASSESSMENT QUESTIONS
The process of producing graphical representations for scientific, engineering and medical data sets and processes is referred to as scientific visualization.
2.
Liquid Crystal Display.
3.
The maximum number of points that can be displayed without overlap on a CRT is referred to as resolution.
4.
A trackball is a ball that can be rotated with the fingers or palm of the hand. A trackball is mounted on a keyboard.
5.
Dot matrix, laser, ink jet, electrostatic, electro thermal printers and pen plotting devices are some of the hard copy devices.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
121
UNIT VII OUTPUT PRIMITIVES AND ATTRIBUTES OF OUTPUT PRIMITIVES
UNIT STRUCTURE 7.0 Introduction 7.1 Objectives 7.7 Output Primitives 7.2.1 Points and Lines 7.2.2 Line Drawing Algorithms 7.2.3 Loading the Frame Buffer 7.2.4 Circle Generating Algorithms 7.2.5 Ellipse Generating Algorithms 7.2.6 Other Curves 7.2.7 Parallel Curve Algorithms 7.2.8 Pixel Addressing and Object Geometry 7.2.9 Filled Area Primitives 7.2.10 Character Generation 7.3 Attributes of Output Primitives 7.3.1 Line Attributes 7.3.2 Curve Attributes 7.3.3 Color and Grayscale Levels 7.3.4 Area Fill Attributes 7.3.5 Character Attributes
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
122
7.3.6 Antialiasing 7.4 Summary 7.5 Self Assessment questions 7.6 Answers to Self Assessment questions
7.0 INTRODUCTION Each output primitive is specified with input coordinate data and other information about the way that objects are to be displayed. The discussion is about picture generation procedures by examining device-level algorithms for displaying two-dimensional output primitives with particular emphasis on scan conversion methods for raster graphics systems. This unit describes the output primitives and the attributes of the output primitives.
7.1 OBJECTIVES At the end of this unit, you should be able to
Know the line drawing, circle drawing and ellipse drawing algorithms
Have a overview of the attributes of the output primitives
Have a thorough study about the antialiasing techniques
Study the process of character generation.
7.2 OUTPUT PRIMITIVES Graphics programming packages provide functions to describe a scene in terms of these basic geometric structures, referred to as output primitives. Each output primitive is specified with input coordinate data and other information about the way that objects are to be displayed. Additional output primitives that can be used to construct a picture include circles and other conic sections, quadric surfaces, spline curves and surface, polygon color areas, and character strings.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
123
7.2.1 Points and Lines Point plotting is accomplished by converting a single coordinate position furnished by an application program into appropriate operations for the output device in use. With a CRT monitor, for example, the electron beam is turned on to illuminate the screen phosphor at the selected location. For a black-and-white raster system, on the other hand, a point is plotted by setting the bit value corresponding to a specified screen position within the frame buffer to 1. Line drawing is accomplished by calculating intermediate positions along the line path between two specified endpoint positions. An output device is then directed to fill in these positions between the endpoints. For analog devices, such as a vector pen plotter or a random-scan display, a straight line can be drawn smoothly from one endpoint to the other. To load a specified color into frame buffer at a position corresponding to column x along scan line y, we will assume we have available a low-level procedure of the form setPixel (x, y)
To retrieve the current frame-buffer intensity setting for a specified location.We accomplish this with the low-level function
getPixel (x, y)
7.7.2 Line Drawing Algorithms The Cartesian slope-intercept equation for a straight line is y=m.x+b With m representing the slope of the line and b as the y intercept. Given that the two endpoints of a line segment are specified at positions (x1, y1) and (x7, y7). We can determine values for the slope m and y intercept b with the following calculations: m = y7 - y1 / x7 - x1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
124
b = y1 – m. x1
For any given x interval ∆x along a line, we can compute the corresponding y interval ∆y
∆y = m ∆x
Similarly, we can obtain the x interval ∆x corresponding to a specified ∆y as ∆x = ∆y / m
DDA Algorithm The digital differential analyzer (DDA) is a scan-conversion line algorithm based on calculating either ∆y or ∆x.
#include “device.h” #define ROUND (a) ( (int) (a+0.5) ) Void lineDDA (int xa, int ya, int xb, int yb) { int dx – xb – xa, dy = yb – ya, steps, k; float xIncrement, yIncrement, x = xa, y = ya;
if (abs (dx) > abs (dy) ) steps = abs (dx); else steps = abs (dy);
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
125
xIncrement = dx / (float) steps; yIncrement = dy / (float) steps;
setPixel (ROUND (x), ROUND (y) ); for (k=0; k<steps; k++); { x += xIncrement; y +=yIncrement; setPixel (ROUND(x), ROUND(y) ); } }
The DDA algorithm is a faster method for calculating pixel positions.
Bresenham’s Line Algorithm An accurate and efficient raster line-generating algorithm, developed by Bresenham, scan converts line using only incremental integer calculations that can be adapted to display circles and other curves. The vertical axes show scan-line positions, and the horizontal axes identify pixel columns.
1. Input the two line endpoints and store the left endpoint in (x0, y0). 2. Load (x0, y0) into the frame buffer; that is, plot the first point. 3. Calculate constants ∆x, ∆y, 2∆y, and 2∆y - 2∆x, and obtain the starting value for the decision parameter as p0 = 2∆y - ∆x 4. At each xk along the line, starting at k = 0, perform the following test: If pk < 0, the next point to plot is (xk + 1, yk )
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
126
pk+1 = pk + 2∆y
otherwise, the next point to plot is (xk + 1, yk + 1) and
pk+1 = pk + 2∆y - 2∆x
5. Repeat step 4 ∆x times.
7.2.3 Loading the Frame Buffer When straight line segments and other objects are scan converted for display with a raster system, frame-buffer positions must be calculated. Scan-conversion algorithms generate pixel positions at successive unit intervals. This allows us to use incremental methods to calculate frame-buffer addresses. As a specific example, suppose the frame-buffer array is addressed in row-major order and that pixel positions vary from (0, 0) at the lower left screen corner to (x max, ymax) at the top right corner. For a bilevel system (1 bit per pixel), the frame-buffer bit address for pixel position (x,y) is calculated as
addr(x, y) = addr(0, 0) + y(xmax + 1) + x
Moving across a scan line, we can calculate the frame-buffer address for the pixel at (x + 1, y) as the following offset from the address for position (x, y):
addr(x + 1, y) = addr(x, y) +1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
127
Stepping diagonally up to the next scan line from (x, y), we get to the frame-buffer address of (x + 1, y + 1) with the calculation addr (x + 1, y + 1) = addr(x, y) + xmax + 2
where the constant xmax + 2 is precomputed once for all line segments.
7.2.4 Circle Generating Algorithms Since the circle is a frequently used component in pictures and graphs, a procedure for generating either full circles or circular arcs is include in most graphics packages.
Properties of Circles A circle is defined as the set of points that are all at a given distance r from a center position (x c, yc). this distance relationship is expressed by the Pythagorean theorem in Cartesian coordinates as
2
2
(x - xc) + (y - yc) = r
2
Expressing the circle equation in parametric polar form yields the pair of equations
x = xc + r cosθ y = yc + r sinθ
Midpoint Circle Algorithm To apply the midpoint method, we define a circle function: 2
2
fcircle(x, y) = x + y - r
2
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
128
Any point (x, y) on the boundary of the circle with radius r satisfies the equation f circle(x, y) = 0. If the point is in the interior of the circle, the circle function is negative. And if the point is outside the circle, the circle function is positive. To summarize, the relative position of any point (x, y) can be determined by checking the sign of the circle function:
fcircle(x, y)={ < 0, if (x, y) is inside the circle boundary = 0, if (x, y) is on the circle boundary > 0, if (x, y) is outside the circle boundary
1. Input radius r and circle center (xc, yc) and obtain the first point on the circumference of a circle centered on the origin as
(x0, y0) = (0, r)
2. Calculate the initial value of the decision parameter as
p0 = 5/4 â&#x20AC;&#x201C; r
3. At each xk position, starting at k=0, perform the following test: If p k < 0, the next point along the circle centered on (0, 0) is (xk + 1, yk) and
pk + 1 = pk + 2xk + 1 + 1
Otherwise, the next point along the circle is (x k + 1, yk â&#x20AC;&#x201C; 1) and
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
129
pk + 1 = pk + 2xk + 1 + 1 – 2y k + 1
where 2xk + 1 = 2xk + 2 and 2y k + 1 = 2y k – 2.
4. Determine symmetry points in the other seven octants. 5. Move each calculated pixel position (x, y) onto the circular path centered on (x c, yc) and plot the coordinate values:
x = x + xc,
y = y + yc
6. Repeat steps 3 through 5 until x ≥ y.
7.2.5 Ellipse Generating Algorithms An ellipse is an elongated circle.
Properties of Ellipse An ellipse is defined as the set of points such that the sum of the distances from two fixed positions (foci) is the same for all points. If the distances to the two foci from any point P = (x, y) on the ellipse are labeled d1 and d2, then the general equation of an ellipse can be stated as
d1 + d2 = constant
Midpoint Ellipse Algorithm 2
We define an ellipse function from (x - xc / rx) + (y - yc / ry )
2
2
2
2
2
2
= 1 with (xc, yc) = (0, 0) as
2
fellipse(x, y) = ry x + rx y - rx ry
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
130
which has the following properties:
fellipse(x, y) ={ < 0, if (x, y) is inside the ellipse boundary = 0, if (x, y) is on the ellipse boundary > 0, if (x, y) is outside the ellipse boundary
1. Input rx, ry, and ellipse center (xc, yc), obtain the first point on an ellipse centered on the origin as
(x0, y0) = (0, ry)
2. Calculate the initial value of the decision parameter in region 1 as
2
2
2
p10 = ry – rx ry + ¼ r x
3. At each xk position in region 1, starting at k = 0, perform the following test: If p1 k < 0, the next point along the ellipse centered on (0, 0) is (x k + 1, y k)and
2
2
p1k + 1 = p1k + 2ry xk + 1 + ry
Otherwise, the next point along the circle is (x k + 1, y k – 1) and
2
2
2
p1k + 1 = p1k + 2ry xk + 1 - 2rx yk + 1 + ry
with
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
2
2
131
2
2
2
2
2ry x k + 1 = 2ry x k + 2ry , 2rx y k + 1 = 2rx y k - 2rx
2
2
and continue until 2ry x ≥ 2rx y
4. Calculate the initial value of the decision parameter in region 2 using the last point (x 0, y0) calculated in region 1 as
2
2
2
2
2
2
p20 = ry (x0 + ½) + rx (y0 – 1) - rx ry
5. At each yk position in region 2, starting at k = 0, perform the following test: If p2k > 0, the next point along the ellipse centered on (0, 0) is (xk, yk – 1) and
2
2
p2k + 1 = p2k - 2rx yk + 1 + r x
Otherwise, the next point along the circle is (x k + 1, yk – 1) and
2
2
2
p2k + 1 = p2k + 2ry x k + 1 - 2rx yk + 1 + r x
Using the same incremental calculations for x and y as in region 1. 6. Determine symmetry points in the other three quadrants. 7. Move each calculated pixel position (x, y) onto the elliptical path centered on (x c, yc) and plot the coordinate values:
x = x + xc,
y = y + yc
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
132
2
2
8. Repeat the steps for region 1 until 2ry x ≥ 2rx y
7.2.6 Other Curves Various curve functions are useful in object modeling, animation path specifications, data and function graphing, and other graphics applications. Commonly encountered curves include conics, trigonometric and exponential functions, probability distributions, general polynomials, and spline functions. A straightforward method for displaying a specified curve function is to approximate it with straight line segments. Straight-line or curve approximations are used to graph a data set of discrete coordinate points.
Conic Sections In general, we can describe a conic section (or conic) with the second-degree equation: 2
2
Ax + By + Cxy +Dx + Ey + F = 0 where values for parameters A, B, C, D, E, and F determine the kind of curve we are to display. Given this set of collections, we can determine the particular conic that will be generated by evaluating the 2
discriminant B – 4AC:
2
B – 4AC {< 0, generates an ellipse (or circle) = 0, generates a parabola > 0, generates a hyperbola
Polynomials and Spline Curves A polynomial function of nth degree in x is defined as
y = ∑ akx
k
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
= a0 + a1x + … + an-1x
n-1
+ anx
133
n
where n is a nonnegative integer and the ak are constants, with an ≠ 0. We get a quadratic when n = 2; a cubic polynomial when n = 3; a quartic n = 4 and a straight line when n =1.
7.2.7 Parallel Curve Algorithms We can either adapt a sequential algorithm by allocating processors according to curve partitions. A parallel midpoint method for displaying circles is to divide the circular arc from 90° to 45° into equal sub arcs and assign a separate processor to each sub arc. Pixel positions are then calculated throughout each sub arc, and positions in the other circle octants are then obtained by symmetry. A parallel ellipse midpoint method divides the elliptical arc over the first quadrant into equal sub arcs and parcels these out to separate processors. Pixel positions in the other quadrants are determined by symmetry. Each processor uses the circle or ellipse equation to calculate curve-intersection coordinates.
7.2.8 Pixel Addressing and Object Geometry Several coordinate references associated with the specification and generation of a picture. Object descriptions are given in a world-reference frame, chosen to suit a particular application, and input world coordinates are ultimately converted to screen display positions. Another approach is to map world coordinates onto screen positions between pixels, so that we align object boundaries with pixel boundaries instead of pixel centers.
Screen Grid Coordinates A screen coordinate position is then the pair of integer values identifying a grid intersection position between two pixels. With the coordinate origin at the lower left of the screen, each pixel area can be referenced by the integer grid coordinates of its lower left corner. We identify the area occupied by a pixel with screen coordinates (x, y) as the unit square with diagonally opposite corners at (x, y) and (x + 1, y + 1).this pixel-addressing scheme has several advantages: It avoids half-integer pixel boundaries, it facilitates precise object representations, and it simplifies the processing involved in many scanconversion algorithm and in other raster procedures.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
134
Maintaining Geometric Properties of Displayed Objects When we convert geometric descriptions of objects into pixel representations, we transform mathematical points and lines into finite screen areas. For an enclosed area, input geometric properties are maintained by displaying the area only with those pixels that are interior to the object boundaries. The rectangle defined with the screen coordinate vertices, for example, is larger when we display it filled with pixels up to and including the border pixel lines joining the specified vertices.
7.2.9 Filled Area Primitives A standard output primitive in general graphics packages is a solid-color or patterned polygon area. Other kinds of area primitives are sometimes available, but polygons are easier to process since they have linear boundaries. There are two basic approaches to area filling on raster systems. One way to fill an area is to determine the overlap intervals for scan lines that cross the area. Another method for area filling is to start from a given interior position and paint outward from this point until we encounter the specified boundary conditions. The scan-line approach is typically used in general graphics packages to fill polygons, circles, ellipses, and other simple curves.
Scan-Line Polygon Fill Algorithm For each scan line crossing a polygon, the area-fill algorithm locates the intersection points of the scan line with the polygon edges. These intersection points are then sorted from left to right, and the corresponding frame-buffer positions between each intersection pair are set to the specified fill color. A scan line passing through a vertex intersects two polygon edges at that position, adding two points to the list of intersections for the scan line. The topological difference between scan line y and scan line y' is identified by noting the position of the intersecting edges relative to the scan line. For scan line y, the two intersecting edges sharing a vertex are on opposite sides of the scan line. But for scan line y', the two intersecting edges are both above the scan line. Thus, the vertices that require additional processing are those that have connecting edges on opposite sides of the scan line.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
135
One way to resolve the question as to whether we should count a vertex as one intersection or two is to shorten some polygon edges to split those vertices that should be counted as one intersection.
Inside-Outside Tests We apply the odd-even rule, also called the odd parity rule or the even-odd rule, by conceptually drawing a line from any position P to a distance point outside the coordinate extends of the object and counting the number of edge crossings along the line. If the number of polygon edges crossed by this line is odd, then P is an interior point. Otherwise, P is an exterior point. Another method for defining interior regions is the nonzero winding number rule, which counts the number of times the polygon edges wind around a particular point in the counterclockwise direction, this count is called the winding number, and the interior points of a two-dimensional object are defined to be those that have a nonzero value for the winding number.
Scan-Line Fill of Curved Boundary Areas In general, scan-line fill of regions with curved boundaries requires more work than polygon filling, since intersection calculations now involve nonlinear boundaries. We only need to calculate the two scanline intersections on opposite sides of the curve. Symmetries between quadrants (and between octants for circles) are used to reduce the boundary calculations. Similar methods can be used to generate a fill area for a curve section. The interior region is bounded by the ellipse section and a straight-line segment that closes the curve by joining the beginning and ending positions of the arc.
Boundary-Fill Algorithm Another approach to area filling is to start at a point inside a region and paint the interior outward toward the boundary. If the boundary is specified in a single color, the fill algorithm proceeds outward pixel by pixel until the boundary color is encountered. This method, called the boundary-fill algorithm, is particularly useful in interactive painting packages, where interior points are easily selected.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
136
A boundary-fill procedure accepts as input the coordinates of an interior point (x, y), a fill color, and a boundary color. Starting from (x, y), the procedure tests neighboring positions to determine whether they are of the boundary color. If not, they are painted with fill color, and their neighbors are tested. This process continues until all pixels up to the boundary color for the area have been tested.
Flood-Fill Algorithm Sometimes we want to fill in (or recolor) an area that is not defined within a single color boundary. We can paint such areas by replacing a specified interior color instead of searching for a boundary color value. This approach is called a flood-fill algorithm. We start from a specified interior point (x, y) and reassign all pixel values that are currently set to a given interior color with the desired fill color. If the area we want to paint has more than one interior color, we can first reassign pixel values so that all interior points have the same color.
7.2.10 Character Generation Letters, numbers, and other characters can be displayed in a variety of sizes and styles. The overall design style for a set (or family) of characters is called a type-face. Examples of a few common typefaces are courier, Helvetica, New York, Palatino, and Zapf Chancery. The term font referred to a set of cast metal character forms in a particular size and format, such as 10-point Courier italic or 12-point Palatino Bold. The terms font and typeface are often used interchangeably. Typefaces (or fonts) can be divided into two broad groups: serif and sans serif. Serif type has small lines or accents at the ends of the main character strokes, while sans-serif type does not have accents. Serif type is generally more readable; that is, it is easier to read in longer blocks of text. Sansserif type is said to be more legible. Since sans-serif characters can be quickly recognized, this typeface is good for labeling and short headings. A simple method for representing the character shapes in a particular typeface is to use rectangular grid patterns. The set of characters are then referred to as a bitmap font (or bitmapped font). Another, more flexible, scheme is to describe character shapes using straight-line and curve sections, as in PostScript, for example. In this case, the set of characters is called an outline font. Bitmap fonts are the simplest to define and display: The character grid only needs to be mapped to a frame-buffer position.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
137
7.3 ATTRIBUTES OF OUTPUT PRIMITIVES Any parameter that affects the way a primitive is to be displayed is referred to as an attribute parameter. Some attribute parameters, such as color and size, determine the fundamental characteristics of a primitive. Others specify how the primitive is to be displayed under special conditions. Examples of attributes in this class include depth information for three-dimensional viewing and visibility or detectability options for interactive object-selection programs.
7.3.1 Line Attributes Basic attributes of a straight line segment are its type, its width, and its color. In some graphics packages, line can also be displayed using selected pen or brush options.
Line Type Possible selections for the line-type attribute include solid lines, dashed lines, and dotted lines. We modify a line-drawing algorithm to generate such lines by setting the length and spacing of displayed solid sections along the line path. A dash line could be displayed by generating an interdash spacing that is equal to the length of the solid sections. A dotted line can be displayed by generating very short dashes with the spacing equal to or greater than the dash size. Pixel counts for the span length and interspan spacing can be specified in a pixel mask, which is a string containing the digits 1 and 0 to indicate which positions to plot along the line path.
Line Width A heavy line on a video monitor could be displayed as adjacent parallel lines, while a pen plotter might require pen changes. We set the line-width attribute with the command: setLinewidthScaleFactor (lw)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
138
Line-width parameter lw is assigned a positive number to indicate the relative width of the line to be displayed. A value of 1 specifies a standard-width line. Values greater than 1 produce lines thicker than the standard. We can adjust the shape of the line ends to give them a better appearance by adding line caps. One kind of line cap is the butt cap obtained by adjusting the end positions of the component parallel lines so that the thick line is displayed with square ends that are perpendicular to the line path. Another line cap is the round cap obtained by adding a filled semicircle to each butt cap. The circular arcs are centered on the line endpoints and have a diameter equal to the line thickness. A third type pf line cap is the projecting square cap. Here, we simply extend the line and add butt caps that are positioned one-half of the line width beyond the specified endpoints. A meter join is accomplished by extending the outer boundaries of each of the two lines until they meet. A round join is produced by capping the connection between the two segments with a circular boundary whose diameter is equal to the line width. A bevel join is generated by displaying the line segments with butt caps and filling in the triangular gap where the segments meet.
Pen and Brush Options With some packages, lines can be displayed with pen or brush selections. Operations in this category include shape, size, and pattern. Lines generated with pen (or brush) shapes can be displayed in various widths by changing the size of the mask.
Line Color When a system provides color (or intensity) options, a parameter giving the current color index is included in the list of system-attribute values. We set the line color value in PHIGS with the function
setPolylineColourIndex (lc)
Nonnegative integer values, corresponding to allowed color choices, are assigned to the line color parameter lc. A line drawn in the background color is invisible.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
139
7.3.2 Curve Attributes Parameters for curve attributes are the same as those for line segments. We can display curves with varying colors, widths, dot-dash patterns, and available pen or brush options. Pixel masks display dashes and interdash spaces that vary in length according to the slope of the curve. Raster curves of various widths can be displayed using the method of horizontal or vertical pixel spans. Where the magnitude of the curve slope is less than 1, we plot vertical spans; where the slope magnitude is greater than 1, we plot horizontal spans. Another method for displaying thick curves is to fill in the area between two parallel curve paths, whose separation distance is equal to the desired width.
7.3.3 Color and Grayscale Levels General-purpose raster-scan systems, for example, usually provide a wide range of colors. For CRT monitors, these color codes are then converted to intensity-level settings for the electron beams. In a color raster system, the number of color choices available depends on the amount of storage provided per pixel in the frame buffer. Also, color information can be stored in the frame buffer in two ways: We can store color codes directly in the frame buffer, or we can put the color codes in a separate table and use pixel values as an index into this table.
Color Tables A user can set color-table entries in a PHIGS applications program with the function
setColourRepresentation (ws, ci, colorptr)
Parameter ws identifies the workstation output device; parameter ci specifies the color index, which is the color-table position number (0 to 255 for the example); and parameter colorptr points to a trio of RGB color values (r, g, b) each specified in the range from 0 to 1. There are several advantages in storing color codes in a lookup table. Use of a color table can provide a â&#x20AC;&#x153;reasonableâ&#x20AC;? number of simultaneous colors without requiring large frame buffers.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
140
Grayscale With monitors that have no color capability, color functions can be used in an application program to set the shades of gray, or grayscale, for displayed primitives. Numeric values over the range from 0 to 1 can be used to specify grayscale levels, which are then converted to appropriate binary codes for storage in the raster. This allows the intensity settings to be easily adapted to systems with differing grayscale capabilities. An alternative scheme for storing the intensity information is to convert each intensity code directly to the voltage value that produces this gray-scale level on the output device in use. When multiple output devices are available at an installation, the same color-table interface may be used for all monitors.
7.3.4 Area Fill Attributes Options for filling a defined region include a choice between a solid color or a patterned fill and choices for the particular colors and patterns. These fill options can be applied to polygon regions or to areas defined with curved boundaries. Fill Styles Areas are displayed with three basic fill styles: hollow with a color border, filled with a solid color, or filled with a specified pattern or design. A basic fill style is selected in a PHIGS program with the function
setInteriorStyle (fs)
Values for the fill-style parameter fs include hollow, solid, and pattern. Another value for fill style is hatch, which is used to fill an area with selected hatching patternsâ&#x20AC;&#x201D;parallel lines or crossed lines. Other fill options include specifications for the edge type, edge width, and edge color of a region.
Pattern Fill We select fill patterns with
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
141
setInteriorStyleIndex (pi)
where pattern index parameter pi specifies a table position.
For fill style pattern, table entries can be created on individual output devices with
setPatternRepresentation (ws, pi, nx, ny, cp)
Parameter pi sets the pattern index number for workstation code ws, and cp is a two-dimensional array of color codes with nx columns and ny rows. A reference position for starting a pattern fill is assigned with the statement
setPatternReferencePoint (position)
Parameter position is a pointer to coordinates (xp, yp) that fix the lower left corner of the rectangular pattern. The process of filling an area with a rectangular pattern is called tiling and rectangular fill patterns are sometimes referred to as tiling patterns.
Soft Fill Modified boundary-fill and flood-fill procedures that are applied to repaint areas so that the fill color is combined with the background colors are referred to as soft-fill or tint-fill algorithms. As an example of this type of fill, the linear soft-fill algorithm repaints an area that was originally painted by merging a foreground color F with a single background color B, where F â&#x2030; B.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
142
7.3.5 Character Attributes The appearance of displayed characters is controlled by attributes such as font, size, color, and orientation.
Text Attributes There is the choice of font (or typeface), which is a set of character with a particular design style such as New York, Courier, Helvetica, London, Times Roman, and various special symbol groups. The characters in a selected font can also be displayed with assorted underlining styles (solid , dotted , double), in boldface, in italics, and in
or shadow styles.
Character height is defined as the distance between the baseline and the capline of characters. Text size can be adjusted without changing the width-to height ratio of characters with
setCharacterHeight (ch)
Parameters ch is assigned a real value greater than 0 to set the coordinate height of capital letters: the distance between baseline and capline in user coordinates. The width only of text can be set with the function setCharacterExpansionFactor (cw)
where the character-width parameter cw is set to a positive real value that scales the body width of characters. Spacing between characters is controlled separately with
setCharacterSpacing (cs)
where the character-spacing parameter cs can be assigned any real value.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
143
The orientation for a displayed character string is set according to the direction of the character up vector:
setCharacterUpVector (upvect)
Parameter upvect in this function is assigned two values that specify the x and y vector components. A precision specification for text display is given with
setTextPrecision (tpr)
where text precision parameter tpr is assigned one of the values: string, char, or stroke.
Marker Attributes A marker symbol is a single character that can be displayed in different colors and in different sizes. We select a particular character to be the marker symbol with
setMarkerType (mt)
where marker type parameter mt is set to an integer code. Typically codes for marker type are the integers 1 through 5, specifying, respectively, a dot (路), a vertical cross (+), an asterisk (*), a circle (o), and a diagonal cross (X).
7.3.6 Antialiasing
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
144
Displayed primitives generated by the raster algorithm have a jagged, or stairstep, appearance because the sampling process digitizes coordinate points on an object to discrete integer pixel positions. This distortion of information due to low-frequency sampling (under sampling) is called aliasing. We ca improve the appearance of displayed raster lines by applying antialiasing methods that compensate for the under sampling process.
2.4 SUMMARY
In this unit the various attributes that control the appearance of displayed primitives are discussed. The basic line attributes are line type, line color and line width. To reduce the size of the frame buffer, some raster systems use a separate color lookup table. Characters can be displayed in difference colors, sizes and orientations. Marker symbols can be displayed using selected characters of various sizes and colors. The appearance of raster primitives can be improved by applying antialiasing procedures that adjust pixel intensities.
2.5 SELF ASSESSMENT QUESTIONS
Answer the following questions
1. Define the term Output primitive. 2. ________________ is a faster method for calculating pixel position. 3. Give the types of fonts. 4. List the various character attributes. 5. What do you mean by antialiasing?
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
145
2.6 ANSWERS TO SELF ASSESSMENT QUESTIONS
1. Graphics programming packages provide functions to describe a scene in terms of the basic geometric structures referred to as output primitives. 2. DDA Algorithm. 3. Serif and Sans Serif are the types of fonts. 4. The various character attributes are font, size, color and orientation. 5. Displayed primitive generated by the raster algorithms have a jagged, appearance due to low frequency sampling is called aliasing. The appearance of displayed raster lines can be improved by using antialiasing.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
146
UNIT VIII TWO-DIMENSIONAL GEOMETRIC TRANSFORMATIONS
UNIT STRUCTURE 8.0 Introduction 8.1 Objectives 8.2 Basic Transformations 8.2.1 Translation 8.2.2 Rotation 8.2.3 Scaling 8.3Matrix Representations and Homogeneous Coordinates 8.4 Composite Transformations 8.4.1 Translations 8.4.2 Rotations 8.4.3 Scalings 8.4.4 General Pivot Point Rotation 8.4.5 General Fixed Point Scaling 8.5 Other Transformations 8.5.1 Reflection 8.5.2 Shear 8.6 The Viewing Pipeline 8.7 Viewing Coordinate Reference Frame 8.8 Window to Viewport Coordinate Transformation
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
147
8.9 Clipping Operations 8.9.1 Types of Clipping 8.10 Point Clipping 8.11 Line Clipping 8.11.1 Cohen-Sutherland Line Clipping 8.11.2 Liang-Barsky Line Clipping 8.12 Polygon Clipping 8.12.1 Sutherland-Hodgeman Polygon Clipping 8.12.2 Weiler-Atherton Polygon Clipping 8.11 Curve Clipping 8.14 Text Clipping 8.15 Exterior Clipping 8.16 Summary 8.17 Self Assessment questions 8.18 Answers to Self Assessment questions
8.0 INTRODUCTION Design applications and facility layouts are created by arranging the orientations and sizes of the component parts of the scene. Animations are produced by moving he objects in a scene along animation paths. Changes in orientation, size and shape are accomplished with geometric transformations that alter the coordinate descriptions of objects. The basic geometric transformations are translation, rotation and scaling. Other transformations include reflection and shear.
8.1 OBJECTIVES At the end of this unit, you should be able to
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
148
Understand the basic transformations namely translation, rotation and scaling
Know the other transformations namely reflection and shear
Familiar with the window and viewport transformations
Have a thorough study about line clipping and polygon clipping algorithms
Study the text clipping, curve clipping and exterior clipping.
8.2 BASIC TRANSFORMATIONS Changes in orientation, size and shape of an object are accomplished with geometric transformations that alter the coordinate descriptions of objects.
8.2.1 Translation
A translation is applied to an object by repositioning it along a straight path from one coordinate location to another.
We translate a two-dimensional point by adding translation distances,t x and ty to the original ’
’
coordinate position(x,y)to move the point to a new position(x ,y ).
’
X =x+tx
y=y+ty
The translation distance pair(tx,ty)is called a translation vector or shift vector.
x1
x1’
P=
P’=
x2 ,
x2’
tx T= ty
This allows us to write the two-dimensional translational equations in the matrix form:
P’=P+T
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Translation is a rigid-body transformation that
149
moves objects without
deformation. Every point on the object is translated by the same amount. The following figure shows the translation of an object.
Figure 7: Translation of an object
8.2.2 Rotation
A two-dimensional rotation is applied to an object by repositioning it along a circular path in the xy plane.
To generate a rotation, we specify a rotation angle θ and the position (xr,yr)of the rotation point(or pivot point) about which the object is to be rotated.
Positive values for the rotation angle define counterclockwise rotations about the pivot point.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
150
Negative values rotate objects in the clockwise direction. This transformation can also be described as a rotation about rotation axis that is perpendicular to the xy plane and passes through the pivot point. The rotation equation is expressed in the matrix form:
P’=R.P
Where the rotation matrix is
cosθ –sinθ R= sinθ cosθ
The following figure shows the rotation of an object. Figure 8: Rotation of an object 8.2.3 Scaling
A scaling transformation alters the size of an object.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
151
This operation can be carried out for polygons by multiplying the coordinate values(x,y)of each vertex by scaling factors sx and sy to produce the transformed coordinates(x’,y’):
X’=x.sx ,
y’=y.sy
Scaling factor sx scales objects in the x direction, while sy scales in the y direction. The transformation equation can also be written in the matrix form:
X’
sx 0 =
Y’
x .
0 sy
y
Or P’=S.P
When sx and sy are assigned the same value, a uniform scaling is produced that maintains relative object proportions.
Unequal values for sx and sy result in a differential scaling that is often used in design applications. The following figure shows the scaling operation where a square is converted to a rectangle.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
152
Figure 9: Scaling operation
8.3 MATRIX REPRESENTATIONS AND HOMOGENEOUS COORDINATES
Many graphics applications involve sequence of geometric transformations. An animation, for example, might require an object to be translated and rotated at each increment of the motion. Each of the basic transformations can be expressed in the general matrix form:
P’=M1.P + M2
With coordinate positions p and p’ represented as column vectors.
To produce a sequence of transformations such as scaling followed by rotation then translation, we must calculate the transformed coordinate’s one step at a time.
First coordinate positions are scaled, then these scaled coordinates are rotated, and finally the rotated coordinates are translated.
To express any two-dimensional transformation as a matrix multiplication, we represent each Cartesian coordinate position (x,y)with the homogeneous coordinate triple(xh,yh,h), where
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
X= xh
,
153
y= yh
h
h
A general homogeneous coordinate representation can also be written as (h.x,h.y,h).
The term homogeneous coordinates is used in mathematics to refer to the effect of this representation on Cartesian equations.
When a Cartesian point (x,y)is converted to a homogeneous representation (xh,yh,h),equations containing x and y , such as f(x,y)=0, become homogeneous equations in the three parameters xh,yh, and h. This just means that if each of the three parameters is replaced by any value v times that parameter; the value v can be factored out of the equations. For translation we have
P’= T(tx,ty).P
Rotation transformation equations about the coordinate origin are written as
P’=R(θ).P
A scaling transformation relative to the coordinate origin is
P’=S(sx,sy).P
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
154
8.4 COMPOSITE TRANSFORMATIONS
With the matrix representations, we can set up a matrix for any sequence of transformations as a composite
transformation
matrix
by
calculating
the
matrix
product
of
the
individual
transformations. Forming products of transformation matrices is often referred to as a concatenation, or composition, of matrices.
8.4.1 Translation If two successive translation vectors (t x1,ty1) and(tx2,ty2)are applied to a coordinate position P, the final transformed location P’ is calculated as
P’=T(tx2,ty2).{T(tx1,ty1).P} ={T(tx2,ty2).T(tx1,ty1)}.P
Where P and P’ are represented as homogeneous-coordinate column vectors.
T(tx2,ty2).T(tx1,ty1)=T(tx1+tx2,ty1+ty2)
8.4.2 Rotation
Two successive rotations applied to point to produce the transformed position
P’=R(θ2).{R(θ1).P} ={R(θ2).R(θ1)}.P
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
155
By multiplying the two rotation matrices, we can verify that two successive rotations are additive:
R(θ2).R(θ1)=R(θ1+θ2)
So that the final rotated coordinates can be calculated with the composite rotation matrix as
P’=R(θ1+θ2).P 8.4.3 Scaling Concatenating transformation matrices for two successive scaling operations produces the following composite scaling matrix:
Sx2 0 0
sx1 0 0
sx1.sx2 0
0 sy2 0 . 0 sy1 0 =
0 01
0 0 1
0
0 sy1.sy2 0
0
0
1
Or
S(sx2,sy2).S(sx1,sy1)=S(sx1.sx2,sy1.sy2) 8.4.4 General Pivot Point Rotation
We can generate rotations about any selected pivot point (x r,yr) by performing the following sequence of translate–rotate-translate operations:
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Translate the object so that the pivot-point position is moved to the coordination origin.
Rotate the object about the coordinate origin.
Translate the object so that the pivot point is returned to its original position.
156
T(xr,yr).R(θ).T(-xr,-yr)=R(xr,yr,θ)
The following figure shows a transformation sequence for rotating an object about a specified pivot point using the rotation matrix R of transformation.
Figure 10 : Transformation sequence for rotating an object about a specified pivot point using the rotation matrix R of transformation
8.4.5 General Fixed Point Scaling
A transformation sequence to produce scaling with respect to a selected fixed position (x f,yf)using a scaling function that can only scale relative to the coordinate origin.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
157
Translate object so that the fixed point coincides with the coordinate origin. Scale the object with respect to the coordinate origin. Use the inverse translation of step1 to return the object to its original position.
T(xf,yf).S(sx,sy).T(-xf,-yf)=S(xf,yf,sx,sy) The following figure shows a transformation sequence for scaling an object with respect to a specified fixed position using the scaling matrix.
Figure 11 : Transformation sequence for scaling an object with respect to a specified fixed position using the scaling matrix
The following figure shows how a square is converted to a parallelogram using the composite transformation matrix.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
158
Figure 12 : A square is converted to a parallelogram using the composite transformation matrix
8.5 OTHER TRANSFORMATION Basic transformations such as translation, rotation and scaling are included in most graphics packages. Some packages provide a few additional transformations that are useful in certain applications. Two such transformations are reflection and shear.
8.5.1 Reflection
A reflection is a transformation that produces a mirror image of an object. The mirror image for a 0
two-dimensional reflection is generated relative to an axis of reflection by rotating the object180 about the reflection axis.
Reflection about the line y=0, the axis, is a accomplished with the transformation matrix
1 0 0
0 -1 0
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
159
0 0 1
This transformation keeps x values the same, but “flips” the y values of coordinate positions.
A reflection about the y axis flips x coordinates while keeping y coordinates the same. The matrix for this transformation is
-1 0 0
0 1 0
0 0 1
We flip both the x and y coordinates of a point by reflecting relative to an axis that is perpendicular to the xy plane and that passes through the coordinate origin. This transformation, referred to as a reflection relative to the coordinate origin, has the matrix representation:
-1 0 0
0 -1 0
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
160
0 0 1
If we choose the reflection axis as the diagonal line y=x, the reflection matrix is
0 1 0
1 0 0
0 0 1
We can derive this matrix by concatenating a sequence of rotation and coordinate-axis reflection matrices.
To obtain a transformation matrix for reflection about the diagonal y=-x, we could concatenate matrices for the transformation sequence:
0
Clockwise rotation by 45 . Reflection about the y-axis. 0
Counterclockwise rotation by 45 .
The resulting transformation matrix is
0 -1 0
-1 0 0
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
161
0 0 1
Reflection about any line y=mx+b in the xy plane can be accomplished with a combination of translate-rotate-reflect transformations. The following figure shows the reflection transformation.
Figure 13: Reflection of an object about x axis
Figure 14: Reflection of an object about y axis 8.5.2 Shear A transformation that distorts the shape of an object such that the transformed shape appear as if the object were composed of internal layers that had been caused to slide over each other is called shear.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
162
Two common shearing transformations are those that shift coordinate x values and those that shift y values.
An x-direction shear relative to the x-axis is produced with the transformation matrix
1 shx 0
0 1
0
0 0
1
This transforms coordinate position as
X’=x+ shx, y’=y
We can generate x-direction shears relative to other reference lines with
1 shx -shx.yref
0 1
0
0 0
1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
163
With coordinate positions transformed as
X’=x+ shx(y- yref), y’=y
A y-direction shear relative to the line x=xref is generated with the transformation matrix
1
0
0
Shy 1 -Shy.xref
0
0
1
This generates transformed coordinate positions X’=x, y’= Shy(x-xref)+y This transformation shifts a coordinate position vertically by an amount proportional to its distance from the reference line x=xref. The following figure shows how a unit square is transformed to a shifted parallelogram using shearing.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
164
Figure 15: Unit square is transformed to a shifted parallelogram using shearing
8.6 THE VIEWING PIPELINE
A world-coordinate area selected for display is called a window. An area on a display device to which a window is mapped is called a viewport.
The window defines what is to be viewed; the viewport defines where it is to be displayed.
The mapping of a part of a world-coordinate scene to device-coordinates is referred to as a viewing transformation. Sometimes the two-dimensional viewing transformation is simply referred to as the window-to-viewport transformation or the windowing transformation.
The term window originally referred to an area of a picture that is selected for viewing. Window-manager systems to refer to any rectangular screen area that can be moved about, resized, and made active or inactive.
A two-dimensional viewing-coordinate system in the world-coordinate plane, and define a window in the viewing coordinate system.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
165
The viewing coordinate reference frame is used to provide a method for setting up arbitrary orientations for rectangular windows.
By changing the position of the viewport, we can view objects at different positions on the display area of an output device. Panning effects are produced by moving a fixed-size window across the various objects in a scene.
Viewports are typically defined within the unit square(normalized coordinates). This provides a means for separating the viewing and other transformations from specific output-device requirements, so that the graphics package is largely device-independent. The following figure shows the two dimensional viewing transformation pipeline.
Figure 16: Two dimensional viewing transformation pipeline
8.7 VIEWING COORDINATE REFERENCE FRAME
This coordinate system provides the reference frame for specifying the world-coordinate window. A viewing-coordinate origin is selected at some world position: P0= x0,y0
To specify a world vector V that defines the viewing yv direction. Vector V is called the view up vector. Given V, we can calculate the components of unit vectors v= vx,vy
And u= ux,uy for the viewing yv and xv axes respectively.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
166
These unit vectors are used to form the first and second rows of the rotation matrix R that aligns the viewing xvyv axes with the world xwyw axes.
The composite two-dimensional transformation to convert world coordinates to viewing coordinates is
MWC,VC=R.T
Where T is the translation matrix that takes the viewing origin point P0 to the world origin and R is the rotation matrix that aligns the axes of the two reference frames.
8.8 WINDOW-TO-VIEWPORT COORDINATE TRANSFORMATION
A point at position (xw,yw)in the window is mapped into position(xv,yv)in the associated viewport.
xv-xvmin
xw-xwmin
= xvmax-xvmin
yv-yvmin
xwmax-xwmin
yw-ywmin
= yvmax-yvmin
ywmax-ywmin
Solving these expressions for the viewport position (xv,yv),we have
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
167
xv=xvmin+(xw-xwmin)sx
yv=yvmin+(yw-ywmin)sy where the scaling factors are xvmax-xvmin sx = xwmax-xwmin
yvmax-yvmin sy = ywmax-ywmin
A set of transformations that converts the window area into the view port area.
Perform a scaling transformation using a fixed-point position of (xwmin,ywmin)that scales the window area to the size of the viewport.
Translate the scaled window area to the position of the viewport.
Any number of output devices can be open in a particular application, and another window-toviewport transformation can be performed for each open output device. This mapping, called the workstation transformation is accomplished by selecting a window area in normalized space and viewport area in the coordinates of the display device. 8.9 CLIPPING OPERATIONS
A picture that are either inside or outside of a specified region of space is referred to as a clipping algorithm or clipping.
The region against which an object is clipped is called a clip window.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
168
8.9.1 Types of Clipping
o
Point clipping
o
Line clipping(straight-line segments)
o
Area clipping(polygons)
o
Curve clipping
o
Text clipping
8.10 POINT CLIPPING The clip window is a rectangle in standard position,we save a point P=(x,y)for display if the following inequalities are satisfied:
Xwmin≤ x≤ xwmax
ywmin≤ y≤ ywmax
where the edges of the clip window(xwmin,xwmax,ywmin,ywmax)can be either the world-coordinate window boundaries or viewport boundaries.
Point clipping can be applied to scenes involving explosions or sea foam that are modeled with particles (points) distributed in some region of the scene. 8.11 LINE CLIPPING A line with both endpoints inside all clipping boundaries, such as the line from P1 to P2, is saved. A line with both endpoints outside any one of the clip boundaries is outside the window.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
169
All other lines cross one or more clipping boundaries, and may require calculation of multiple intersection points. For a line segment with endpoints(x 1,y1)and(x2,y2)and one or both endpoints outside the clipping rectangle, the parametric representation
X=x1+u(x2-x1)
y=y1+u(y2-y1), 0â&#x2030;¤ uâ&#x2030;¤ 1
If the value of u for an intersection with a rectangle boundary edge is outside the range 0 to 1 , the lines does not enter the interior of the window at that boundary.
If the value of u is with in the range from 0 to 1, the line segment does indeed cross into the clipping area.
8.11.1 Cohen-Sutherland Line Clipping
Every line endpoint in a picture is assigned a four-digit binary code, called region code that identifies the location of the point relative to the boundaries of the clipping rectangle. Each bit position in the region code is used to indicate one of the four relative coordinate positions of the point with respect to the clip window: to the left, right, top or bottom. Bit 1 : Left Bit 2 : Right Bit 3 : Below Bit 4 : Above A value of 1 in any bit position indicates that the point is in that relative position; otherwise, the bit position is set to 0. If a point is within the clipping rectangle, the region code is 0000.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
170
Region-code bit values can be determined with the following two steps: o
Calculate differences between endpoint coordinates and clipping boundaries.
o
Use the resultant sign bit of each difference calculation to set the corresponding value in the region code.
Bit 1 : sign bit of x-xwmin Bit 2 : sign bit of xwmax-x Bit 3 : sign bit of y-ywmin Bit 4 : sign bit of ywmax-y A method that can be used to test lines for total clipping is to perform the logical and operation with both region codes. If the result is not 0000, the line is completely outside the clipping region. A line with endpoint coordinates(x1,y1) and (x2,y2), the y coordinate of the intersection point with a vertical boundary can be obtained with the calculation. Y = y1 + m(x - x1) Where, m=(y2 - y1) / (x2 – x1) Similarly for the intersection with a horizontal boundary, the x coordinate can be calculated as, X = x1 + (y - y1) / m
8.11.2 Liang-Barsky Line Clipping
The parametric equation of a line segment is of the form, X = x1 + u∆ x Y = y1 + u∆ y,
0≤ u≤ 1
Where, ∆ x = x2 – x1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
171
∆ y = y2 – y1. The point clipping parametric equations in Liang-Barsky is of the form, Xwmin ≤ x1 + u∆x ≤ xwmax Ywmin ≤ y1 + u∆ y ≤ ywmax Each of these four inequalities can be expressed as
Upk ≤ qk ,
k=1,2,3,4
Where parameters p and q are defined as, P1 = -∆x,
q1 = x1 - xwmin
P2 = ∆x,
q2 = xwmax – x1
P3 = -∆y,
q3 = y1 - ywmin
P4 = ∆y,
q4 = ywmax – y1
The two conditions are qk < 0,
line lies completely outside the boundary
qk
line lies inside the boundary.
≥
0,
pk < 0, line proceeds from outside to inside boundary pk
≥
0, line proceeds from inside to outside boundary.
For a nonzero value of pk , we can calculate the value of u that corresponds to the point where the infinitely extended line intersects the extension of boundary k as,
U = qk / pk
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
ď&#x201A;¨
172
The following figure shows line clipping against a rectangular clip window.
Figure 17: line clipping against a rectangular clip window.
8.12 POLYGON CLIPPING
o
A polygon boundary processed with a line clipper may be displayed as a series of unconnected line segments, depending on the orientation of the polygon to the clipping window.
o
Polygon clipping requires an algorithm that will generate one or more closed areas that are then scan converted for the appropriate area fill. The output of a polygon clipper should be a sequence of vertices that defines the clipped polygon boundaries.
8.12.1 Sutherland-Hodgeman Polygon Clipping
We can correctly clip a polygon by processing the polygon boundary as a whole against each window edge. This could be accomplished by processing all polygon vertices against each clip rectangle boundary.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
173
The four possible cases when processing vertices in sequence around the perimeter of a polygon are: If the first vertex is outside the window boundary and the second vertex is inside, both the intersection point of the polygon edge and the second vertex are added to the output vertex list. If both input vertices are inside the window boundary, only the second vertex is added to the output vertex list. If the first vertex is inside and second vertex is outside only the intersection is added to output list. If both the input vertices are outside, nothing is added to the output list.
8.12.2 Weiler-Atherton Polygon Clipping
This clipping procedure was developed as a method for identifying visible surfaces, and so it can be applied with arbitrary polygon-clipping regions. The basic idea in this algorithm is that instead of always proceeding around the polygon edges as vertices are processed, we sometimes want to follow the window boundaries. For clockwise processing of polygon vertices, the following rules are applied: For an outside-to-inside pair of vertices, follow the polygon boundary. For an inside-to-outside pair of vertices, follow the window boundary in a clockwise direction. The following figure shows polygon clipping.
Figure 18: Polygon Clipping
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
174
8.13 CURVE CLIPPING
Curve clipping procedures will involve nonlinear equations and requires more processing than for objects with linear boundaries.
The bounding rectangle for a circle or other curved object can be used to test for overlap with a rectangular clip window.
If the bounding rectangle for the object is completely inside the window, we save the object. If the rectangle is determined to be completely outside the window, we discard the object. If either case fails for circle we test coordinate extends of individual coordinates.
8.14 TEXT CLIPPING
This clipping technique will involve characters. If all the string is inside a clip window we keep it otherwise we discard it. It is called all-or-none string-clipping.
An entire character string that overlaps a boundary is to use the all-or-none characterclipping.
A final method for text clipping is to clip the components of individual characters.
If an individual character overlaps a clip window boundary, clip off the parts of the character that are outside the window. The following figure shows the process of text clipping.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
175
Figure 19: Text Clipping
8.15 EXTERIOR CLIPPING
If we want to clip a picture to the exterior of a specified region, the picture parts to be saved are those that are outside the region. This is referred to as exterior clipping. A typical example of the application of exterior clipping is in multiple-window systems.
Exterior clipping is also used in other applications that require overlapping pictures.
This technique can also be used for combining graphs, maps or schematics.
Procedures for clipping objects to the interior of concave polygon windows can also make use of external clipping.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
176
8.16 SUMMARY
The basic geometric transformations are translation, rotation and scaling. Other transformations include reflection and shear. Transformations between Cartesian coordinate systems are accomplished with a sequence of translate-rotate transformations. The viewing transformation pipeline includes constructing the world coordinate scene using modeling transformations, transferring world coordinates to viewing coordinates, mapping the viewing coordinate descriptions of objects to normalized device coordinates and finally mapping to device coordinates. Line clipping, polygon clipping, curve clipping, exterior clipping and text clipping are also discussed.
3.17
SELF ASSESSMENT QUESTIONS
Answer the following questions
1. Define the term transformation. 2. ________________ alters the size of an object. 3. What is meant by concatenation of matrices? 4. ________________ produces a mirror image of an object. 5. Define window and a viewport.
3.18
ANSWERS TO SELF ASSESSMENT QUESTIONS
1. Changes in orientation, size and shape of an object are accomplished with geometric transformations that alter the coordinate descriptions of objects. 2. Scaling transformation.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
177
3. Forming product of transformation matrices is referred to as concatenation or composition of matrices. 4. Reflection. 5. A world coordinate area selected for display is called a window. An area on a display device to which a window is mapped is called a viewport.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
178
UNIT IX THREE-DIMENSIONAL CONCEPTS
9.0 Introduction 9.1 Objectives 9.2 Three Dimensional Display Methods 9.2.1 Parallel Projection 9.2.2 Perspective Projection 9.2.3 Depth Cueing 9.2.4 Visible Line and Surface Identification 9.2.5 Surface Rendering 9.2.6 Exploded and Cutaway Views 9.2.7 Three Dimensional and Stereoscopic Views 9.3 Three-Dimensional Geometric and Modeling Transformation 9.3.1 Translation 9.3.2 Rotation 9.3.3 Scaling 9.4 Other Transformations 9.4.1 Reflection 9.4.2 Shear 9.5 Composite Transformations
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
179
9.6 Viewing Pipeline 9.7 Viewing Coordinates 9.8 Projections 9.9 Clipping 9.10 Summary 9.11 Self Assessment questions 9.12 Answers to Self Assessment questions
9.0 INTRODUCTION Graphics packages often provide routines for displaying internal components or cross sectional views of solid objects. Some geometric transformations are more involved in three-dimensional space than in two dimensions. Two-dimensional rotations are always around an axis that is perpendicular to the xy plane. Viewing transformations in three dimensions are much more complicated because we have many more parameters to select when specifying how a three-dimensional scene is to be mapped to a display device. Methods for geometric transformations and object modeling in three dimensions are extended from two-dimensional methods by including the z coordinate.
9.1 OBJECTIVES At the end of this unit, you should be able to
Understand the three dimensional display methods
Know the three dimensional transformations namely translation, rotation, scaling, reflection and shear
Familiar with the viewing pipeline and viewing coordinates
Have a thorough study about clipping and projections
9.2 THREE DIMENSIONAL DISPLAY METHODS
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
180
To obtain a display of a three dimensional scene that has been modeled in world coordinates, we must first set up a coordinate reference for the camera.
This co-ordinate reference defines the position and orientation for the plane of the camera film.
Object descriptions are then transferred to the camera reference coordinates and projected onto the selected display plane.
9.2.1 Parallel projection
One method for generating a view of a solid object is to project points on the object surface along parallel lines onto the display plane.
In a parallel projection, parallel lines in the world-coordinate scene project into parallel projection on the two dimensional display plane.
This technique is used in engineering and architectural drawings to represent an object with a set of views.
9.2.2 Perspective projection
Another method for generating a view of a three-dimensional scene id to project points to the display plane along converting paths.
In a prospective projection, parallel lines in a scene that are not parallel to the display plane are projected into converging lines.
Scenes displayed using perspective projections appear more realistic.
Parallel lines appear to converge to a distant point in the background, and distant objects appear smaller than closer to the viewing position.
9.2.3 Depth Cueing
Depth information is important so that we can easily identify, for a particular viewing direction, which direction, which is the front and which is the back of displayed objects.
A simple method for generating depth with wire frame displays is to vary the intensity of objects according to their distance from the viewing position.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
181
The lines closest to the viewing position are displayed with the highest intensities, and lines farther away are displayed with decreasing intensities.
Another application of depth cueing is modeling the effect of the atmosphere on the perceived intensity of objects.
9.2.4 Visible Line and Surface Identification
Clarify depth relationships in a wire frame display.
The simplest method is to highlight the visible lines or to display them in a different color.
Another technique, commonly used for engineering drawings, is to display the no visible lines as dashed lines.
Another approach is to simply remove the no visible lines.
Some visible-surface algorithms establish visibility pixel by pixel across the viewing plane; other algorithms determine for object surfaces as a whole.
9.2.5 Surface Rendering
Surface properties of objects include degree of transparency and how rough or smooth the surfaces are to be.
Procedures can then be applied to generate the correct illumination and shadow regions for the scene.
Surface-rendering methods are combined with perspective and visible-surface identification to generate a degree of realism in a displayed scene.
9.2.6 Exploded and Cutaway Views
Exploded and cutaway views of such objects can then be used to show the internal structure and relationship of the object parts.
An alternative to exploding an object into its component parts is the cutaway view, which removes part of the visible surfaces to show internal structure.
9.2.7 Three Dimensional and Stereoscopic Views
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
182
Another method for adding a sense of realism to a computer-generated scene is to display objects using either three-dimensional or stereoscopic views.
Stereoscopic devices present two views of a scene.
One for the left eye.
Other for the right eye.
The two views are generated by selecting viewing positions that correspond to the two eye positions of a single viewer.
9.3 THREE-DIMENSIONAL GEOMETRIC AND MODELING TRANSFORMATION
Methods for geometric transformations and object modeling in three dimensions are extended from two-dimensional methods by including considerations for the z coordinate.
9.3.1 Translation
In a three-dimensional homogeneous coordinate representation, a point is translated from position P=(x,y,z) to position P’=(x’,y’,z’)with the matrix operation
x’
1 0 0 tx
x
y’ = 0 1 0 ty . y z’
0 0 1 tz
z
1
0001
1
P’=T+P
Parameters tx, ty, tz specifying translation distances for the coordinate directions x,y,z are assigned any real values.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
The matrix representation in Eq.1 is equivalent to the three equations
x’= x + tx;
183
y’= y + ty;
z’= z + tz;
An object is translated in three dimensions by transforming each of the defining points of the object.
9.3.2 Rotation
To generate a rotation transformation for an object we must designate an axis of rotation (about which the object is to be rotated) and the amount of angular rotation.
The easiest rotation axes to handle are those that are parallel to the coordinate axes.
Positive rotation angles produce counterclockwise rotations about a coordinate axis.
Coordinate-Axes Rotations
The two dimensional z-axis rotation equations are easily extended to three dimensions:
x’=xcos a - ysin a y’=xsin a + ycos a z’=z Parameter a specifies the rotation angle.
We get equations for an x-axis rotation:
y’=ycos a – zsin a z’=ysin a + zcos a
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
x’=x
x’
which can be written in the homogeneous coordinate form
1 0
0
0
x
y’ = 0 cos a –sin a 0 . y z’
0 sin a cos a 0
1
0 0
0
1
z 1
P’=Rx (a).P
The transformation equation for a y-axis rotation:
z’= zcos a – xsin a x’= zsin a + xcos a y’=y
x’
The matrix representation for y-axis rotation is
cos a 0 sin a 0
x
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
184
MACHINE DRAWING & COMPUTER GRAPHICS
y’ = z’
0
1
0
0 .y
-sin a 0 cos a 0
1
0
0
0
185
1
z
1
P’=Ry (a).P
General Three-Dimensional Rotations
In the special case where an object is to be rotated about an axis that is parallel to one of the coordinate axes, we can attain the desired rotation with the following transformation sequence.
1. Translate the object so that the rotation axis coincides with the parallel coordinate axis. 2. Perform the specified rotation about axis. 3. Translate the object so that the rotation axis is moved back to its original position.
When an object is to be rotated about an axis that is not parallel to one of the coordinate axis, we need to perform some additional transformations.
Given the specifications for the rotation axis and the rotation angle, we can accomplish the required rotation in five steps. 1. Translate the object so that rotation axis passes through the coordinate origin. 2. Rotate the object so that the axis of rotation coincides with one of the coordinate axis. 3. Perform the specified rotation about that coordinate axis. 4. Apply inverse rotation to bring the rotation axis back to its original orientation. 5. Apply the inverse translation to bring the rotation axis back to its original position.
9.3.3 Scaling
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
186
The matrix expression for the scaling transformation of a position P=(x,y,z)relative to the coordinate origin can be written as
x’
Sx 0 0 0
y’ =
x
0 Sy 0 0 . y
z’
0 0 Sz 0
z
1
0 0 0 1
1
(1)
P’=S.P
Where scaling parameters Sx,Sy and Sz are assigned any positive values.
Explicit expressions for the coordinate transformations for scaling relative to the origin are
x’=x.Sx y’=y.Sy
z’=z.Sz
Scaling an object with transformation (1) changes the size of the object and repositions the object relative to the coordinate origin.
We preserve the original shape of an object with a uniform scaling (Sx=Sy=Sz).
Scaling with respect to a selected fixed position (Xf,Yf,Zf) can be represented with the following transformation sequence:
1. Translate the fixed point to the origin. 2. Scale the object relative to the coordinate origin using Eq.(1). 3. Translate the fixed point back to its original position.
Sx 0 0 (1-Sx)Xf 0 Sy 0 (1-Sy)Yf T(Xf,Yf,Zf).S(Sx,Sy,Sz).T(-xf,-Yf,-Zf)=
0 0 Sy (1-Sz)Zf
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
0 0 0
187
1
(2)
We form the inverse scaling matrix for either Eq.(1) or Eq.(2) by placing the scaling parameters Sx,Sy and Sz with their reciprocals.
The inverse matrix generates an opposite scaling transformation, so the concatenation of any scaling matrix and its inverse produces the identity matrix. The following figure shows the process of scaling an object relative to a selected fixed point which is equivalent to the sequence of transformations.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
Figure 20: Scaling an object relative to a selected fixed point
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
188
MACHINE DRAWING & COMPUTER GRAPHICS
189
9.4 OTHER TRANSFORMATION In addition to translation, rotation and scaling, there are various additional transformations that are often useful in three dimensional graphics applications namely reflection and shear.
9.4.1 Reflection
A three dimensional reflection can be performed relative to a selected reflection axis or with respect to a selected reflection plane. Reflections relative to a given axis are equivalent to 180 degree rotations about that axis. Reflections with respect to a plane are equivalent to 180 degree rotations in four-dimensional space. This transformation changes the sign of the z coordinates, leaving the x and y-coordinate values unchanged. The matrix representation for this reflection of points relative to the xy plane is
1 0 0 0 RFz= 0 1 0 0 0 0 -1 0 0 0 0 1
9.4.2 Shear
Shearing transformations can be used to modify object shapes.
They are also useful in two dimensional viewing for obtaining general projection transformations.
In three dimensions, we can also generate shears relative to the z-axis.
An example of three-dimensional shearing ,the following transformation produces a z-axis shear:
1 0 a 0
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
190
SHz= 0 1 b 0 0 0 1 0 0 0 0 1
Parameters a and b can be assigned any real values.
The effect of this transformation matrix is to alter x-and y-coordinate values by an amount that is proportional to the z value, while leaving the z coordinate unchanged. The following figure shows how a unit cube is sheared by transformation matrix with a = 1 and b = 1.
Figure 21: unit cube is sheared by transformation matrix with a = 1 and b = 1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
191
9.5 COMPOSITE TRANSFORMATIONS We form a composite three-dimensional transformation by multiplying the matrix representations for the individual operations in the transformation sequence. This concatenation is carried out from right to left, where the rightmost matrix is the first transformation to be applied to an object and the leftmost matrix is the last transformation. A sequence of basic, three-dimensional geometric transformations is combined to produce a single composite transformation, which is then applied to the coordinate definition of an object.
9.6 VIEWING PIPELINE
The steps for computer generation of a view of a three-dimensional scene are analogous to the processes involved in taking a photograph. To take a snapshot, we first need to position the camera at a particular point in space. Then we need to decide on the camera orientation. When we snap the shutter, the scene is cropped to the size of the window of the camera and light from the visible surface s is projected onto the camera film. Once the scene has been modeled, world coordinate positions are converted to viewing coordinates. Next, projection operations are performed to convert the viewing coordinate description of the scene to coordinate positions on the projection plane, which will then be mapped to the output device. Objects outside the specified viewing limits are clipped from further consideration and the remaining objects are processed through visible surface identification and surface rendering procedures to produce the display within the device viewport. The following figure shows the general three dimensional transformation pipeline from modeling coordinates to final device coordinates.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
192
Figure 22: General three dimensional transformation pipeline from modeling coordinates to final device coordinates.
9.7 VIEWING COORDINATES
Generating a view of an object in three dimensions is similar to photographing the object. We can walk around and take its picture from any angle, at various distances and with varying camera orientations. The type and size of the camera lens determines which parts of the scene appear in the final picture.
Specifying the View Plane We choose a particular view for a scene by first establishing the viewing coordinate system also called the view reference coordinate system. A view plane or projection plane is then set up perpendicular to the viewing zv axis. World coordinate positions in the scene are transformed to viewing coordinates, and then viewing coordinates are projected onto the view plane. To establish the viewing coordinate reference frame, we first pick a world coordinate position called the view reference point. This point is the origin of the viewing coordinate system. The view reference point is often chosen to be close to or on the surface of some object in a scene. Next, we select the positive direction for the viewing zv axis, and the orientation of the view plane, by specifying the view plane normal vector N. N is simply specified as a world coordinate vector. We choose the up direction for the view by specifying a vector V, called the view up
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
193
vector. This vector is used to establish the positive direction for the yv axis. Vector V also be defined as a world coordinate vector or in some packages it is specified with a twist angle about the z v axis. Using vectors N and V, the graphics package can compute a third vector U, perpendicular to both N and V to define the direction for the xv axis. Then the direction of V can be adjusted so that it is perpendicular to both N and U to establish the viewing yv direction. The view plane is always parallel to the xvyv plane and the projections of objects to the view plane correspond to the view of the scene that will be displayed on the output device.
9.8 PROJECTION Once world coordinate descriptions of the objects in a scene are converted to viewing coordinates, we can project the three dimensional objects onto the two dimensional view plane. There are two basic projection methods. In a parallel projection, coordinate positions are transformed to the view plane along parallel lines. For a perspective projection object positions are transformed to the view plane along lines that converge to a point called the projection reference point or center of projection. The projected view of an object is determined by calculating the intersection of the projection lines with the view plane. A Parallel projection preserves relative proportions of objects and this is the method used in drafting to produce scale drawings of three-dimensional objects.
9.8.1 Parallel Projection We can specify a parallel projection with a projection vector that defines the direction for the projection lines. When the projection is perpendicular to the view plane, we have an orthographic parallel projection. Otherwise, we have an oblique parallel projection. Orthographic projections are most often used to produce the front, side and top views of an object. Front, side and rear orthographic projections of an object are called elevations and a top orthographic projection is called a plan view. Engineering and architectural drawings are commonly employing these orthographic projections.
We can also form
orthographic projections that display more than one face of an object. Such views are called axonometric orthographic projections. The most commonly use axonometric projection is the isometric projection. We generate an isometric projection by aligning the projection plane so that it intersects each coordinate axis in which the object is defined called the principal axes at the same distance from the origin. The following figure shows the parallel projection of an object to the view plane.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
194
Figure 23: Parallel projection of an object to the view plane. 9.8.2 Perspective Projection
To obtain a perspective projection of a three dimensional object, we transform points along projection lines that meet at the projection reference point. We can write equations describing coordinate positions along this perspective projection line in parametric form as X’ = x – xu Y’ = y – yu Z’ = z – (z – zprp)u
Parameter u takes values from 0 to 1, and coordinate position (x’,y’,z’) represents any point along the projection line. When a three-dimensional object is projected onto a view plane using perspective transformation equations, any set of parallel lines in the object that are not parallel to the plane are projected into converging lines. Parallel lines that are parallel to the view plane will be projected as parallel lines. The point at which a set of projected parallel lines appears to converge is called a vanishing point. The vanishing point for any set of lines that are parallel to one of the principal axes of an object is referred to as a principal vanishing point. The number of principal vanishing points in a projection is determined by the number of principal axes intersecting the view plane. The following figure shows the perspective projection of equal sized objects at different distances form the view plane.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
195
Figure 24: Parallel projection of an object to the view plane. The following figure shows the isometric projection of a cube. The isometric projection is obtained by aligning the projection vector with the cube diagonal.
Figure 25: Isometric projection of a cube.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
The following figure shows the orthographic projection of a point onto a viewing plane.
Figure 26: Orthographic Projection of a point onto a viewing plane.
Figure 27: Oblique Projection of coordinate position (x,y,z)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
196
MACHINE DRAWING & COMPUTER GRAPHICS
197
4.9 CLIPPING To clip a line segment against the view volume, we would need to test the relative position of the line using the view volumeâ&#x20AC;&#x2122;s boundary plane equations. By substituting the line endpoint coordinates into the plane equation of each boundary in turn, we could determine whether the endpoint is inside or outside that boundary. Lines with both endpoints outside boundary plane are discarded, and those with both endpoints inside all boundary planes are saved. To clip a polygon surface, we can clip the individual polygon edges First, we could test the coordinate extends against each boundary of the view volume to determine whether the object is completely inside or completely outside that boundary. If the coordinate extents of the object are inside all boundaries, we save it. If the coordinate extends are outside all boundaries, we discard it. Clipping in two dimensions is generally performed against an upright rectangle; that is, the clip window is aligned with the x and y axes.
Normalized View Volumes At the first step, a scene is constructed by transforming object descriptions from modeling coordinates to world coordinates. A view mapping converts the world descriptions to viewing coordinates. At the projection stage, the viewing coordinates are transformed to projection coordinated, which effectively converts the view volume into a rectangular parallelepiped. Then, the parallelepiped is mapped into the unit cube, a normalized view volume called the normalized projection coordinate system. The mapping to normalized projection coordinates is accomplished by transforming points within the rectangular parallelepiped into position within a specified three- dimensional view port, which occupies part or the entire unit cube. Normalized projection coordinates are converted to device coordinates for display. The normalized view volume is a region defined by the planes x = 0, x = 1, y = 0, y = 1, z = 0, z = 1
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
198
First, the normalized view volume provides a standard shape for representing any sized view volume. The unit cube then can be mapped to a workstation considerations of any size clipping procedures are simplified and standardized with unit clipping planes or the viewport planes, and additional clipping planes can be specified within the normalized space before transforming to device coordinates. Depth cueing and visible- surface determination are simplified, since the z axis always points toward the viewer. The following figure shows the expanded transformation pipeline.
Figure 28: Expanded Transformation Pipeline
Mapping positions within a rectangular view volume to a three – dimension rectangular viewport is accomplished with a combination of scaling and translation, similar to the operations needed for a twodimensional window – to –viewport mapping. We can express the three- dimensional transformation matrix for these operations in the form Dx
0
0
Kx
0
Dy
0
Ky
0
0
Dz
Kz
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
0
0
0
199
1
Factors Dx1 Dy1 and Dz are the ratios of the dimensions of the viewport and regular parallelepiped view volume in the x,y, and z directions.
Dx
Dx
xvmax xv min xwmax xwmin
yvmax yvmin ywmax ywmin
Dx
zvmax zvmin zwbackzw front
Where the view – volume boundaries are established by the window limits (xw
min,
xw
max,
ywmin,
ywmax) and the positions zfront and zback of the front back planes. Viewport bundaries are set with the coordinate values xvmin, xvmax, yvmin, yvmax, zvmin, zvmax. The additive translation factors Kx, Ky and Kz in the transformation are Kx = xvmin – xw min Dx Ky = yvmin – yw min Dy Kz = zvmin – z front Dz
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
200
Figure 29: Dimensions of the view volume and three dimensional viewport
View port clipping Lines and polygon surfaces in a scene can be clipped against the viewport boundaries. The twodimensional concept of region codes can be extended to three dimensions by considering positions in front and in back of the three –dimensional viewport, as well as positions that are left, right, below, or above the volume. For three – dimensional points, we need to expend the region code to six bits. Each point in the description of a scene is then assigned a six-bit region code that identifies the relative position of the point with respect to the viewport. For a line endpoint at position (x,y,z) we assign the bit positions in the region code from right to left as
bit 1 1, if x xvmin (left ) bit 2 1, if x xvmax (right )
bit 3 1, if y yvmin (below)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
201
bit 4 1, if y yvmax (above)
bit 5 1, if z zvmin ( front ) bit 6 1, if z zvmax (back ) A line segment can be immediately identified a completely within the viewport if both endpoints have a region code of 000000. If either endpoint of a line segment does not have a region code of 000000, we perform the logical and operation on the two endpoint codes. The result of this and operation will be nonzero for any line segment that has both endpoints in one of the six outside regions. A nonzero value will be generated if both endpoints are behind the viewport, or both endpoints are above the viewport. The two dimensional parametric clipping methods of Cyrus –Beck or Liang-Barsky can be extended to three-dimensional scenes. For a line segment with endpoints P1 = (x1, y1, z1) and P2 = (x2,y2,z2), we can write the parametric line equations as
x x1 ( x2 x1 )u,
0 u 1
y y1 ( y 2 y1 )u z z1 ( z 2 z1 )u Coordinates (x,y,z) represent any point on the line between the two endpoints. At u= 0, we have the point P1, and u = 1 puts us at P2.
9.10 SUMMARY Three dimensional transformations useful in computer graphics applications include geometric transformations within a single coordinate system and transformations between different coordinate systems. The basic geometric transformations are translation, rotation and scaling. Two additional object transformations are reflections and shears. Viewing procedures for three dimensional scenes follow the general approach used in two dimensional viewing. Three dimensional viewing requires projection routines to transform object descriptions to a viewing plane before the transformation to device coordinates. Parallel projections are either orthographic or oblique and can be specified with a projection vector. Objects in three dimensional scenes are clipped against a view volume. The top, bottom, and sides of the view volume are formed with planes that are parallel to the projection lines and that pass through the view plane window edges.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
202
9.11SELF ASSESSMENT QUESTIONS
Answer the following questions
1. Define the term three dimensional transformation. 2. ________________ can be used to modify object shapes. 3. What are the types of projection? 4. When the projection is perpendicular to the view plane we have an ________________. 5. Define principal vanishing point.
9.12 ANSWERS TO SELF ASSESSMENT QUESTIONS
1. Methods for geometric transformations and object modeling in three dimensions are extended from two dimensional methods by including considerations for the z coordinate is known as three dimensional transformations. 2. Shearing transformation. 3. The types of projection are parallel and perspective projection. 4. Orthographic parallel projection. 5. The vanishing point for any set of lines that are parallel to one of the principal axes of an object is referred to as a principal vanishing point.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
203
UNIT X GRAPHICAL USER INTERFACES AND INTERACTIVE INPUT METHODS
10.0 Introduction 10.1 Objectives 10.2 The User Dialogue 10.2.1 Windows and Icons 10.2.2 Accommodating Multiple Skill Levels 10.2.3 Consistency 10.2.4 Minimizing Memorization 10.2.5 Backup and Error Handling 10.2.6 Feedback 10.3 Input of Graphical Data 10.3.1 Logical Classification of Input Devices 10.3.2 Locator Devices 10.3.3 Stroke Devices 10.3.4 String Devices 10.3.5 Valuator Devices 10.3.6 Choice Devices 10.3.7 Pick Devices 10.4 Input Functions 10.4.1 Input Modes
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
10.4.2 Request Mode 10.4.3 Locator and Stroke Input in Request Mode 10.4.4 String Input in Request Mode 10.4.5 Valuator Input in Request Mode 10.4.6 Choice Input in Request Mode 10.4.7 Pick Input in Request Mode 10.4.8 Sample Mode 10.4.9 Event Mode 10.5 Interactive Picture Construction Techniques 10.5.1 Basic Positioning Methods 10.5.2 Constraints 10.5.3 Grids 10.5.4 Gravity Field 10.5.5 Rubber Band Methods 10.5.6 Dragging 10.5.7 Painting and Drawing 10.6 Visible Surface Detection Methods 10.6.1 Back Face Detection 10.6.2 Depth-Buffer Method 10.7 Basic Illumination Models 10.7.1 Ambient Light 10.7.2 Diffuse Reflection 10.7.3 Specular Reflection and the Phong Model
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
204
MACHINE DRAWING & COMPUTER GRAPHICS
205
10.7.4 Combined Diffuse and Specular Reflections with Multiple Light Sources 10.7.5 Warn Model 10.7.6 Intensity Attenuation 10.7.7 Color Considerations 10.7.8 Transparency 10.7.9 Shadows 10.8 Color Models and Color Applications 10.8.1 Properties of Light 10.8.2 Standard Primaries and the Chromaticity Diagram 10.8.3 Intuitive Color Concepts 10.8.4 RGB Color Model 10.8.5 YIQ Color Model 10.8.6 CMY Color Model 10.8.7 HSV Color Model 10.9 Summary 10.10 Self Assessment questions 10.11 Answers to Self Assessment questions
10.0 INTRODUCTION
The human computer interface for most systems involves extensive graphics, regardless of the application. In this unit we take a look at the basic elements of graphical user interfaces. A variety of
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
206
input devices exists and general graphics packages can be designed to interface with various devices and to provide extensive dialogue capabilities. A major consideration in the generation of realistic graphics displays is identifying those parts of a scene that are visible from a chosen viewing position. Numerous algorithms are devised for efficient identification of visible objects for different types of applications. These algorithms are referred to as visible surface detection methods. Realistic displays of a scene are obtained by generating perspective projections of objects and by applying natural lighting effects to the visible surfaces. An illumination model or a lighting model or a shading model is used to calculate the intensity of light that we could see at a given point on the surface of an object.
10.1 OBJECTIVES At the end of this unit, you should be able to
Know the graphical user interfaces and the interactive input methods
Familiar with the various visible surface detection methods
Have a thorough study about the basic illumination models
Study the various color models and color applications.
10.2 THE USER DIALOGUE
The user’s model serves as the basis for the design of the dialogue.
The user’s model describes what the system is designed to accomplish and what graphics operations are available.
It states the type of objects that can be displayed and how the objects can be manipulated.
All information in the user dialogue is then presented in the language of the application.
10.2.1 Windows and icons
Visual representations are used both for objects to be manipulated in an application and for the actions to be performed on the application objects.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
207
A window system provides a window-manager interface for the user and functions for handling the display and manipulation of the windows.
Common functions for the window system are opening and closing windows, repositioning windows, resizing windows and display routines that provide interior and exterior clipping and other graphics functions.
Normally windows are displayed with sliders, buttons, and menu icons fro selecting various window options.
Icons representing actions such as rotate, magnify, scale, clip and paste are called control icons or command icons.
10.2.2 Accommodating Multiple Skill Levels
Usually interactive graphical interfaces provide several methods for selecting actions.
For example options could be selected by pointing at an icon and clicking different mouse buttons or by accessing pull-down or pop-up menus or by typing keyboard commands.
This allows a package to accommodate users that have different skill levels.
For a less experienced user, an interface with a few easily understood operations and detailed prompting is more effective than one with a large, comprehensive operation set.
A simplified set of menus and options is easy to learn and remember and the user can concentrate on the application instead on the details of the interface. Experienced users typically want speed. This means fewer prompts and more input from the keyboard or with multiple mouse button clicks.
Help facilities can be designed on several levels so that beginners can carry on a detailed dialogue, while more experienced users can reduce or eliminate prompts and messages.
10.2.3 Consistency
An important design consideration in an interface is consistency.
A complicated, inconsistent model is difficult for a user to understand and to work with in an effective way.
The objects and operations provided should be designed to form a minimum and consistent set so that the system is easy to learn, but not oversimplified to the point where it is difficult to apply.
Other examples of consistency are always placing menus in the same relative positions so that a user does not have to hunt for a particular option, always using a particular combination of keyboard keys for the same action.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
208
10.2.4 Minimizing Memorization
Operations in an interface should also be structured so that they are easy to understand and to remember.
Complicated, inconsistent and abbreviated common formats lead to confusion and reduction in the effectiveness of the use of the package.
Icons are used to reduce memorizing by displaying easily recognizable shapes for various objects and actions.
10.2.5 Backup and Error Handling
A mechanism for backing up or aborting, during a sequence of operations is another common feature of an interface.
Backup can be provided in many forms. A standard undo key or command is used to cancel a single operation. A system can be backed up through several operations, allowing us to reset the system to some specified point.
Error messages are designed to help determine the cause of error. Interfaces attempt to minimize error possibilities by anticipating certain actions that could lead to an error.
10.2.6 Feedback
As each input is received, the system normally provides some type of response.
An object is highlighted, an icon appears, or a message is displayed.
If processing cannot be completed within a few seconds, several feedback messages might be displayed to keep us informed of the progress of the system.
With function keys, feedback can be given as an audible click or by lighting up the key that has been pressed. Other feedback methods include highlighting, blinking and color changes.
Audio feedback has the advantage that it does not use up screen space and we do not need to take attention from the work area to receive the message.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
209
10.3 INPUT OF GRAPHICAL DATA 10.3.1 Logical Classification of Input Devices
LOCATOR is a device for specifying a coordinate position(x,y). STROKE is a device for specifying a series of coordinate positions. STRING is a device for specifying text input. VALUATOR is a device for specifying scalar values. CHOICE is a device for selecting menu options. PICK is a device for selecting picture components.
10.3.2 Locator Devices
A standard method for interactive selection of a coordinate point is by positioning the screen cursor.
When the screen cursor is at the desired location, a button is activated to store the coordinates of that screen point.
Keyboards can be used for locator input in several ways. Keyboard has four control-cursor keys that move the screen cursor up, down, left and right.
10.3.3 Stroke Devices
Stroke-device input is equivalent to multiple calls to a locator device.
The set of input points is often used to display line sections.
The graphics tablet is one of the more common stroke devices.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
210
10.3.4 String Devices
The primary physical device used for string input is the keyboard.
Input character strings are typically used for picture or graph labels.
Other physical devices can be used for generating character patterns in a text writing mode.
A pattern recognition program then interprets the characters using a stored dictionary of predefined patterns.
10.3.5 Valuator Devices
This logical class of devices is employed in graphics systems to input scalar values.
It is used for setting graphics parameters, such as rotation, angle and scale factors setting physical parameters associated with a particular application.
Any keyboard with a set of numeric keys can be used as a valuator device.
10.3.6 Choice Devices
A choice device is defined as one that enters a selection from a list of alternatives.
Choice devices are a set of buttons; a cursor positioning device, such as a mouse, trackball, or keyboard cursor keys; and a touch panel.
Alternate methods for choice input include keyboard and voice entry.
A standard keyboard can be used to type in commands or menu options.
10.3.7 Pick Devices
Pick devices are used to select parts of a scene that are to be transformed or edited in some way.
With a mouse or joystick, we can position the cursor over the primitives in a displayed structure and press the selection button.
The position of the cursor is then recorded, and several levels of search may be necessary to locate the particular object that is to be selected.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
211
10.4 INPUT FUNCTIONS
Graphics input functions can set up to allow users to specify the following options.
(i)Which physical devices are to provide input within a particular logical classification? (ii)How the graphics program and devices are to interact? (iii)When the data are to be input and which device is to be used at that time to deliver a particular input type to the specified data variables?
10.4.1 Input Modes
Input modes specify how the program and input devices interact. There are three types of modes.
Request mode
Sample mode
Event mode
In request mode, the application program initiates data entry. In sample mode, the application program and input devices operate independently. In event mode, the input devices initiate data input to the application program.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
212
The general form is, SetMode (ws, deviceCode, inputMode, echoFlag) Where devicecode is a positive integer; inputMode is assigned one of the values request, sample, event and parameter echoFlag is assigned either the value echo or noecho.
10.4.2 Request Mode When an input in request mode, other processing is suspended until the input is received. The general form is, request (ws, deviceCode, status) Returned values are assigned to parameter status and to the data parameters corresponding to the requested logical class. 10.4.3 Locator and Stroke Input in Request Mode
The general form is, Requestlocator (ws,devCode,status,viewindex,pt) requeststroke(ws,devCode,nmax,status,viewindex,n,pts) 10.4.4 String Input in Request Mode
The general form is, requeststring (ws,devCode,status,nChars,str) Parameter str in this function is assigned an input string.
10.4.5 Valuator Input in Request Mode
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
213
The general form is, requestvaluator(ws, devCode, status, value)
10.4.6 Choice Input in Request Mode
We make menu selection with the following request function: RequestChoice(ws,devCode, status, itemNum)
10.4.7 Pick Input in Request Mode
For this mode, we obtain a structure identifier number with the function RequestPick(ws, devCode, maxPathDepth, status, pathDepth, pickPath)
10.4.8 Sample Mode Once sample mode has been set for one or more physical devices, data input begins without waiting for program direction. The general form is, Sample(ws, deviceCode)
10.4.9 Event Mode When an input device is placed in event mode, the program and device operate simultaneously. The general form is, awaitEvent (time, ws, deviceClass, deviceCode)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
214
10.5 INTERACTIVE PICTURE CONSTRUCTION TECHNIQUES
10.5.1 Basic positioning Methods
Coordinate values supplied by locator input are often used with positioning methods to specify a location for displaying an object or a character string.
10.5.2 Constraints
A constraint is a rule for altering input-coordinate values to produce a specified orientation or alignment of the displayed coordinates. The common constraint is horizontal or vertical alignment of straight lines.
10.5.3 Grids Another kind of constraint is a grid of rectangular lines displayed in some part of the screen area. When a grid is used, any input coordinate position is rounded to the nearest intersection of two grid lines.
10.5.4 Gravity Field
Any selected position within the gravity field of a line is moved to the nearest position on the line. Areas around the endpoints are enlarged to make it easier for us to connect lines at their endpoints.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
215
10.5.5 Rubber-Band Methods Straight line can be constructed and positioned using rubber-band methods, which stretch a line from a starting position as the screen cursor is moved. Rubber band methods are used to construct and position other objects besides straight lines.
10.5.6 Dragging This technique is often used in interactive picture construction to move objects into position by dragging them with the screen cursor. Dragging objects to various positions in a scene is useful in applications where we might want to explore different possibilities before selecting a final location.
10.5.7 Painting and Drawing Curve-drawing options can be provided using standard curve shapes such as circular arcs and splines or with freehand sketching procedures. In free hand drawing, curves are generated by following the path of a stylus on a graphics tablet or the path of the screen cursor on a video monitor. Once a curve is displayed, the designer can alter the curve shape by adjusting the positions of selected points along the curve path. 10.6 VISIBLE SURFACE DETECTION METHODS
A major consideration in the generation of realistic graphics displays is identifying those parts of a scene that are visible from a chosen viewing position.
Deciding upon a method for a particular application can depend on such factors as the complexity of the scene, type of objects to be displayed, available equipment, and whether static or animated displays are to be generated.
The various algorithms are referred to as visible surface detection methods. Sometimes these methods are also referred to as hidden surface elimination methods.
10.6.1 Classification of Visible-Surface Detection Algorithms
Visible-surface detection algorithms are broadly classified according to whether they deal with object definitions directly or with their projected images.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
216
The two approaches are called Object-Space methods and image-space methods respectively.
An object-space method compares objects and parts of objects to each other within the scene definition to determine which surfaces, as a whole, we should label as visible.
In an image-space algorithm, visibility is decided point by point at each pixel position on the projection plane.
There are major differences in the basic approach taken by the various visible-surface detection algorithms, most use sorting and coherence methods to improve performance.
Sorting is used to facilitate depth comparisons by ordering the individual surfaces in a scene according to their distance from the view plane.
Coherence methods are used to take advantage of regularities in a scene.
Visible surface detection methods are classified as follows o
Back Face Detection
o
Depth-Buffer Method
o
A-Buffer Method
o
Scan Line Method
o
Depth Sorting Method
o
BSP Tree Method
o
Area Subdivision Method
o
Octree Mthods
o
Ray Casting Method
Among the above mentioned visible surface detection methods, Back Face detection method and Depth Buffer method are included in the syllabus. 10.6.2 Back Face Detection
A fast and simple object-space method for identifying the back faces of a polyhedron is based on the “inside-outside” tests.
A point(x,y,z) is “inside” a polygon surface with plane parameters A,B,C, and D if
Ax+By+Cz+d<0
When an inside point is along the line of sight to the surface, the polygon must be a back face.
In general, if V is a vector in the viewing direction position then this polygon is a back face if o
V.N>0
If object descriptions have been converted to projection coordinates and our viewing direction is parallel to the viewing zv axis, then V=(0,0,Vz) and
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
217
V.N=VzC
So that we only need to consider the sign of C, the z component of the vector N.
In a right-handed viewing system with viewing direction along the negative zv axis, the polygon is a back face if C<0.
Thus , in general we can label any polygon as a back face if its normal vector has a component value: o
C<=0
Similar methods can be used in packages that employ a left-handed viewing system.
In these packages, plane parameters A,B,C, and D can be calculated from polygon vertex coordinates specified in a clockwise direction.
Also, back faces have normal vectors that point away from the viewing position and are identified by C>=0 when the viewing direction is along the positive zv axis.
10.6.3 Depth Buffer Method
A commonly used image-space approach to detecting visible surfaces is the depth-buffer method, which compares surface depths at each pixel position on the projection plane.
This procedure is also referred to as the z-buffer method, since object depth is usually measured from the view plane along the z-axis of the viewing system.
The depth-buffer algorithm as follows:
1. Initialize the depth buffer and refresh buffer so that for all buffer possible directions(x,y), Depth(x,y)=0,refresh(x,y)=Ibackgnd 2. For each position on each polygon surface,compare depth values to previously stored values in the depth buffer to determine visibility.
Calculate the depth z for each(x,y)position on the polygon.
If z>depth(x,y),then set Depth(x,y)=z, refresh(x,y)=Isurf(x,y)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
218
Where Ibackgnd is the value for the background intensity, and Isurf(x,y) is the projected intensity value for the surface at pixel position(x,y).After all surfaces have been processed, the depth buffer contains depth values for the visible surfaces and the refresh buffer contains the corresponding intensity values for those surfaces.
Depth values for a surface position (x,y) are calculated from the plane equation for each surface: Z=(-Ax-By-D)/C
If the depth z’ of the of the next position(x+1,y) along the scan line is Z’=-(A(x+1)-By-D)/C Or Z’=z-A/C;
Depth values down the edge are obtained recursively as Z’=z+(A/m+B)/C
If we are processing down a vertical edge, the slope is infinite and the recursive calculations reduce to Z’=z+B/C
10.7 BASIC ILLUMINATION MODELS
Lighting calculations are based on the optical properties of surfaces, the background lighting conditions, and the light-source specifications. Optical parameters are used to set surface properties, such as glossy, matte, opaque, and transparent. This controls the amount of reflection and absorption of incident light. All light sources are considered to be point sources, specified with a coordinate position and an intensity value (color)
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
219
10.7.1 Ambient Light A surface that is not exposed directly to a light source still will be visible if nearby objects are illuminated. In our basic illumination model, we can set a general level of brightness for a scene. This is a simple way to model the combination of light reflection from various surfaces to produce a uniform illumination called the ambient light, or background light. Ambient light has no spatial or directional characteristics. The amount of ambient light incident on each object is a constant for all surfaces and over all directions. We can set the level for the ambient light in a scene with parameter I a, and each surface is then illuminated with this constant value. The resulting reflected light is a constant for each surface, independent of the viewing direction and the spatial orientation of the surface.
Figure 30: An illuminated area projected perpendicular to the path of the incoming light rays
10.7.2 Diffuse Reflection Ambient –light reflection is an approximation of global diffuse lighting effects. Diffuse reflections are constant over each surface in a scene, independent of the viewing direction. The fractional amount of the incident light that is diffusely reflected can be set for each surface with parameter K d, the diffuse – reflection coefficient, or diffuse reflectivity. Parameter Kd is assigned a constant value in the interval 0 to 1, according to the reflecting properties we want the surface to have. If we want a highly reflective surface, we set the value of Kd near that of the incident light. If a surface is exposed only to ambient light, we can express the intensity of the diffuse reflection at any point on the surface as
I ambdiff
Kd I a
10.7.3 Specular reflection and the phong model
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
220
When we look at an illuminated shiny surface, such as polished metal, an apple, or a person’s forehead, we see a highlight, or bright spot, at certain viewing directions. This phenomenon, called specular reflection, is the result of total, or near total, reflection of the incident light in a concentrated region around the specular-reflection angle. An empirical model for calculating the specular reflection range, developed by phong BuiTuong, sets the intensity of specular reflection proportional to cos range 0º to 90º, so that cos
ns
.
Angle
can be assigned values in the
various from 0 to 1. The value assigned to specular reflection parameter
ns is determined by the type of surface ns (say, 100 or more), and smaller values (down to 1) are used for duller surfaces. For a perfect reflector,
ns is infinite. For a rough surface, such as chalk or cinderblock,
ns would be assigned a value near 1. We can approximately model monochromatic specular intensity variations using a specular reflection coefficient, W( ) for each surface.
10.7.4 Combined Diffuse and Specular Reflections with Multiple Light Sources
For a single point light source, we can model the combined diffuse and specular reflections from a point on an illuminated surface as I = I diff + I spec = KaIa + KdIl (N.L) + KsIl(N.H)
ns
If we place more than one point source in a scene, we obtain the light reflection at any surface point by summing the contributions from the individual sources: n
I K a I a I li [ N .Li ) K s ( N .H i ) ns ] i 1
To ensure that any pixel intensity does not exceed the maximum allowable value, we can apply some type of normalization procedure. A simple approach is to set a maximum magnitude for each term in the intensity equation. If any calculated term exceeds the maximum, we simply set it to the maximum
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
221
value. Another way to compensate for intensity overflow is to normalize the individual terms by dividing each by the magnitude of the largest term.
10.7.5 Warn Model
The warn model provides a method for simulating studio lighting effects by controlling light intensity in different directions. In addition, light controls, such as “barn doors” and spotlighting, used by studio photographers can be simulated in the Warn model. Flaps are used to control the amount of light emitted by a source in various directions. Two flaps are provided for each of the x,y and z directions. Spotlights are used to controls the amount of light emitted within a cone with apex at a point source position.
10.7.6 Intensity Attenuation As radiant energy from a point light source travels through space, its amplitude is attenuated by the factor 1/d2, where d is the distance that the light has traveled. This means that a surface close to the light source (small d) receives higher incident intensity from the source than a distant from the source than a distant surface (large d). If two parallel surfaces with the same optical parameters overlap, they would be indistinguishable from each other. A general inverse quadratic attenuation can be set up as
F(d) =
1 a0 a1d a2 d 2
A user can then fiddle with the coefficients a 0, a1 and a2 to obtain a variety of lighting effects for a scene. The value of the constant term a0 can be adjusted to prevent f(d) from becoming too large when d is very small. 10.7.7 Color Considerations For an RGB description, each color in a scene is expressed in terms of red, green, and blue components. We then specify the RGB components of light source intensities and surface colors, and the illumination model calculates the RGB components of the reflected light. One way to set surface colors is by specifying the reflectivity coefficients as three element vectors. The diffuse reflection coefficient vector, for
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
222
example, would then have RGB components (KdR, KdG, KdB). If we want an object to have a blue surface, we select a nonzero value in the range from 0 to 1 for the blue reflectivity component, KdB, while the red and green reflectivity components are set to zero (KdR = KdG = 0). Any nonzero red or green components in the incident light are absorbed, and only the blue component is reflected. The intensity calculation for this example to the single expression
I B K aB I aB fi (d ) I lbi [ K db ( N .Li) K sB ( N .H i ) ns ] 10.7.8 Transparency
A transparent surface, in general, produces both reflected and transmitted light. The relative contribution of the transmitted light depends on the degree of transparency of the surface and whether any light sources or illuminated surfaces are behind the transparent surface. When a transparent surface is to be modeled, the intensity equations must be modified to include contributions from light passing through the surface Realistic transparency effects are modeled by considering light refraction. When light is incident upon a transparent surface, part of it is reflected and part is refracted. The direction of the refracted light, specified by the angle of refraction, is a function of the index of refraction of each material and the direction of the incident light. Index of refraction for a material is defined as the ratio of the speed of light in a vacuum to the speed of light in the material. Angle of refraction incidence i , the index of refraction
r
is calculated from the angle of
i of the “incident” material (usually air), and the index of refraction
r of the refracting material according to Snell’s law: Sin r
i sin i r
10.7.9 Shadows Hidden –surface methods can be used to locate areas where light sources produce shadows. By applying a hidden-surface method section cannot be “seen” from the light source. These are the shadow areas. Once we have determined the shadow areas for all light sources, the shadows could be treated as surface patterns and stored in pattern arrays.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
223
Surface that are visible from the view position are shaded according to the lighting model, which can be combined with texture patterns. We can display shadow areas with ambient light intensity only or we can combine the ambient light with specified surface textures.
10.8 COLOR MODELS AND COLOR APPLICATIONS
A Color model is a method for explaining the properties or behavior of color within some particular context.
No single color model can explain all aspects of color, so we make use of different models to help describe the different perceived characteristics of color.
There are two types of color models namely additive and subtractive color models.
Additive color models use light to display color.
Subtractive color models use printing inks.
Colors perceived in additive models are the result of transmitted light.
Colors perceived in subtractive models are the result of reflected light.
Colors in additive systems are created by adding colors to black to create new colors.
Additive color environments are self-luminous.
Color on monitors is additive.
Primary colors are subtracted from white create new colors.
Any color image reproduced on paper is an example of the use of a subtractive color system.
Color management is a term that describes a technology that translates the colors of an object from their current color space to the color space of the output devices like monitors, printers etc.
Color space is a more specific term for a certain combination of a color model plus a color mapping function.
There are several color models used in computer graphics but the two most common are the RGB for computer display and the CMYK for printing.
10.8.1 Properties of Light What we perceive as “light’, or different colors, is a narrow frequency band within the electromagnetic spectrum. A few of the other frequency bands within this spectrum are called radio waves, micro waves, infrared waves, and X-rays.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
224
Each frequency value within the visible band corresponds to a distinct color. At the low-frequency end is a red color and the highest frequency is violet color. The wavelength and frequency of the monochromatic wave are inversely proportional to each other, with the proportionality constant as the speed of light c: C=/\ .f
If low frequencies are predominant in the reflected light, the object is described as red. In this case, we say the perceived light has a dominant frequency (or dominant wavelength) at the red end of the spectrum. The dominant frequency is also called the hue, or simply the color, of the light.
Brightness is the perceived intensity of the light. Intensity is the radiant energy emitted per unit time, per unit solid angle, and per unit projected area of the source. Radiant energy is related to the luminance of the source.
Purity or saturation describes how washed out or how â&#x20AC;&#x153;Pureâ&#x20AC;? the color of the light appears.
These three characteristics dominant frequency, brightness and purity are commonly used to describe the different properties we perceive in a source of light.
The term Chromaticity is used to refer collectively to two properties describing color characteristics: Purity and dominant frequency
If the two color sources combine to produce white light, they are referred to as Complementary colors.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
225
Examples of complementary colors are red and cyan, green and magenta and blue and yellow.
Typically, color models that are used to describe combinations of light in terms of dominant frequency (hue) use three colors to obtain a reasonably wide range of colors, called the Color gamut for that model.
Two different color light sources with suitably chosen intensities can be used to produce a range of other colors.
The two or three colors used to produce other colors in such a color model are referred to as Primary colors.
10.8.2 Standard Primaries and the Chromaticity Diagram
Since no finite set of color light sources can be combined to display all possible colors, three primaries were defined in 1931 by the international Commission on illumination, referred to as the CIE (Commission International delâ&#x20AC;&#x2122;Eclairage).
The three standard colors are imaginary colors. They are defined mathematically with positive color matching functions that specify the amount of each primary needed to describe any spectral color.
XYZ Color Model The set of CIE primaries is generally referred to as the XYZ,or(X,Y,Z),color model, where X,Y,Z represent vectors in a three dimensional, additive color space. Any color C /\ is then expressed as C/\ =XX+YY+ZZ Where X, Y, Z designate the amounts of the standard primaries needed to match c/\.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
226
Normalised amounts are thus calculated as
x=X/X+Y+Z, y=Y/X+Y+Z, z=Z/X+Y+Z with x+y+z=1. Thus any color can be represented with just the x and y amounts. Since we have normalized against luminance, parameters x and y are called the chromaticity values because they depend only on hue and purity.
CIE Chromaticity Diagram When we plot the normalized amounts x and y for colors in the visible spectrum, we obtain the tongue-shaped curve. This curve is called the CIE Chromaticity Diagram. The chromaticity diagram is useful for the following:
Comparing colors gamuts for different sets of primitives.
Identifying complementary colors.
Determining dominant wavelength and purity of a given color.
Color gamuts are represented on the chromaticity diagram as straight line segments or as polygons.
Since the color gamut for two points is a straight line, complementary colors must be represented on the chromaticity diagram as two points situated on opposite sides of C and connected with a straight line. 10.8.3 Intuitive Color Concepts Starting with the pigment for a “pure color”, the artist adds a black pigment to produce different shades of that color. Different tints of the color are obtained by adding a white pigment to the original color, making it lighter as more white is added.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
227
Tones of the color are produced by adding both black and white pigments.
10.8.4 RGB Color Model
Based on the tristimulus theory of vision, our eyes perceive color through the stimulation of three visual pigments in the cones of the retina. These visual pigments have peak sensitivity at wavelength of about 630 nm (red), 530 nm (green), and 450 nm (blue). This theory of vision is the basis for displaying color output on a video monitor using the three color primaries red, green and blue referred as the RGB Color model. The origin represents black and the vertex with Coordinates (1, 1, 1) is white. Each color point within the bounds of the cube can be represented as a triple (R, G, B), where values for R,G,B are assigned in the range from 0 to 1. Thus, a color C/\ is expressed in RGB components as C/\ =RR+GG+BB
The magenta vertex is obtained by adding red and blue to produce the triple (1, 0, 1) and white at (1, 1, 1) is the sum of the red, green and blue vertices. Some important features of the RGB color model are 1. It is an additive color model 2. Used for computer displays 3. Uses light to display color 4. Colors result from transmitted light 5. Red + Green + Blue = White RGB(X,Y) CHROMATICITY COORDINATES:
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
NTSC Standard
228
CIE Model Approx.Color Monitor values
R) (0.670,0.330) (0.735,0.265)
(0.628,0.346)
G) (0.210,0.710) (0.274,0.717)
(0.268.0.588)
B) (0.410,0.080) (0.167,0.009)
(0.150,0.070)
10.8.5 YIQ Color Model
In the YIQ model, parameter y is the same as in the XYZ model. Luminance information is contained in the y parameter, while chromaticity information is incorporated into the I and Q parameters. A combination of red, green and blue intensities are chosen for the y parameter to yield the standard luminosity curve. An NTSC encoder, which converts RGB values to YIQ values, then modulates and superimposes the I and Q information on the signal. An RGB signal can be converted to a television signal using an NTSC encoder which converts RGB values to YIQ values, then modulates and superimposes the I and Q information on the Y signal. The conversion from RGB values to YIQ values is accomplished with the transformation.
Y
0.299 0.587 0.144
R
I
0.596 -0.275 -0.321
G
Q
0.212 -0.528 0.311
B
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
229
10.8.6 CMY Color Model
A color model defined with the primary colors cyan, magenta and yellow is useful for describing color output to hard-copy devices. A CMY color model forms its gamut from the primary subtractive colors of cyan, magenta and yellow. When cyan, magenta and yellow inks are combined, it forms black.
In CMY model point (1, 1, 1) represents black, because all components of the incident light are subtracted.
The matrix transformation for the conversion from an RGB representation to a CMY representation is , C M Y
1 =
1 1
R -
G B
Here the white is represented in the RGB system as the unit column vector.
Some of the important features of the CMY color model are 1. It is a subtractive color model 2. Used for printed material 3. Uses ink to display color 4. Colors result from reflected light
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
230
5. Cyan + Magenta + Yellow = Black
10.8.7 HSV Color Model
The HSV Model uses color descriptions that have a more intuitive appeal to a user. Color parameters in this model are hue (H), saturation(S), and value (V). Hue deals with the purity of the color. Saturation determines the amount of white light mixed with the original color. Value gives the intensity of the color.
The three dimensional representation of the HSV model is derived from the RGB cube. Hue is represented as an angle about the vertical axis, ranging from 0◦ at red through 360◦. Vertices of the hexagon are separated by 60◦ intervals. Yellow is at 60◦, green at 120◦ and cyan opposite red at H = 180◦. Saturation s varies from 0 to 1. Value v varies from 0 at the apex of the hex cone to 1 at the top.
10.9 SUMMARY In this unit we have discussed the basic properties of light and the concept of a color model. Light sources are described in terms of hue, brightness and saturation. One method of defining a color model is to specify a set of two or more primary colors that are combined to produce various other colors. Common color models defined with three primary colors are the RGB and CMY models. Other color models based on specification of luminance and purity include YIQ, HSV and HLS color models. A dialogue for an application package can be designed from the user’s model, which describes the functions of the applications package.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
231
SELF ASSESSMENT QUESTIONS
Answer the following questions
1. The primary physical device used for string input is _____________. 2. In _________ mode, the input devices initiate data input to the application program. 3. What are the types of visible surface detection methods? 4. A commonly used image space approach to detect visible surfaces is the _____________. 5. Give the various color models.
10.11 ANSWERS TO SELF ASSESSMENT QUESTIONS
1. Keyboard. 2. Event mode. 3. The types of visible surface detection methods are object space methods and image space methods. 4. Depth Buffer method. 5. The various color models are RGB, CMY, YIQ, HSV, HLS and XYZ.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT QUESTIONS UNIT 1 QUESTIONS 1.Enumerate the various manufacturing methods of machine parts which a designer should know. 2,Explain briefly the different casting processes. 3,Write a brief note on the design of castings? 4,State and illustrate two principal design rules for casting design. 5.List the main advantages of forged components. 6.What are the salient features used in the design of forgings? Explain. 7.What do you understand by ‘hot working’ and ‘cold working’ processes? Explain with examples. 8.State the advantages and disadvantages of hot working of metals. Discuss any two hot working processes. 9.What do you understand by cold working of metals? Describe briefly the various cold working processes. 10.What are fits and tolerances? How are they designated? 11.What do you understand by the nominal size and basic size? 12.What is the difference in the type of assembly generally used in running fits and interference fits? 13.State briefly unilateral system of tolerances covering the points of definition, application and advantages over the bilateral system. 14.What is meant by ‘hole basis system’ and ‘shaft basis system’? Which one is preferred and why? 15.Discuss the Indian standard system of limits and fits.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
232
MACHINE DRAWING & COMPUTER GRAPHICS
16.What are the commonly used fits according to Indian standards? 17.What do you understand by preferred numbers? Explain fully.
UNIT-II QUESTIONS SELF â&#x20AC;&#x201C;ASSESMENT QUESTIONS:I
1. 2. 3. 4.
What are the different types of half section? What is the spacing between hatching lines? What is the need for sectioning? The another name of revolved section is -----------------
UNIT QUESTIONS 1. Explain the hatching of larger areas. 2. Define hatching. 3. What is offset section?
ANSWER OF SELF ASSESSMENT QUESTIONS 1. Front view with right half in section Front view with top half in section top view with section Top view with front half in section Left view with front half in section 2. A spacing of 2mm between the hatching lines will be appropriate for the general work. 3. NEED FOR SECTIONING o
To show the internal features more clearly.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
233
MACHINE DRAWING & COMPUTER GRAPHICS
o
To remove hidden lines.
o
To avoid complication and ambiguity.
o
For ease of understanding.
4. Superimposed sectioning
UNIT-III QUESTIONS SELF â&#x20AC;&#x201C;ASSESSMENT QUESTIONS:I Answer the following 1. What are the different types of fits? 2. Define limits 3. Sketch the symbols for the following charesteristics used for form tolerances. (a)
Straightness
(b)
Flatness
(c)
Circularity
(d)
cylindricity
UNIT QUESTIONS 1. Define fits and tolerances 2. What is transition fit? 3. Define shaft basis system. 4. Sketch the symbols of the following and classify them into : (1) Form of single feature (2) Orientation of related features and (3) Position of related features (i) Concentricity (ii) Straightness (iii) Circularity (iv) Perpendicularity
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
234
MACHINE DRAWING & COMPUTER GRAPHICS
(v) Cylindricity (vi) Angularity
ANSWERS OF SELF â&#x20AC;&#x201C;ASSESSMENT QUESTIONS
I 1. (a) Clearance fit (b) Transition fit (c) Interference fit 2. The maximum and minimum permissible sizes within which the actual machined size lies are called limits. 3. (a)
Straightness
(b)
Flatness
(c )
(c)
Circularity
Cylindricity
UNIT-IV QUESTIONS
SELF-ASSESSMENT QUESTIONS:I
1. What is the use of key? 2. Define lay. 3. What are the proportions of pin key?
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
235
MACHINE DRAWING & COMPUTER GRAPHICS
236
UNIT QUESTIONS: 1. Define waviness. 2. Classify the keys. 3. What is the method to indicate the surface roughness for various machining operations?
ANSWER OF SELF-ASSESSMENT QUESTIONS: 1.
Keys are extensively used to hold pulleys, gears, couplings, clutches, sprockets, etc., and the shafts rigidly so that they rotate together. They are also used to mount the milling cutters, riding wheels, etc., on their spindles
2. Lay is the predominant direction of tool marks that make a characteristic pattern on a machined Surface 3. The proportions of the pin key are as follows. If D = diameter of the shaft, d = diameter of the pin, Diameter of pin = 0.2 D Taper 1:50
UNIT-V QUESTIONS SELF â&#x20AC;&#x201C;ASSESMENT QUESTIONS:I
1. 2. 3. 4.
What is left hand thread? What is the difference between bolt and rivet? Draw the neat sketch of rivet head which is used for boiler . Draw a neat sketch to differentiate the internal thread and external thread.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
237
UNIT QUESTIONS 1. 2. 3. 4.
How will you designate the threads. Explain the square thread with neat sketch. Define bolt and nut with neat sketch What is the use of rivets.
ANSWER OF SELF ASSESSMENT QUESTIONS 1. A left hand thread is one which advances into the nut, when turned in a counter clockwise direction, and the slope of the lines representing the thread will be downward from left to right. An abbreviation LH is used to indicate the left hand thread. 2. Rivet is used as a Permanent fastener to withstand shear forces acting perpendicular to its axis, whereas a bolt is used as a temporary fastener to Withstand axial tensile forces. 3. The flat counter sunk riveted head is used for boiler works. The proportion of the flat counter sunk rivet is shown in fig
4. In the diagram the part (A) refers the external thread, and part (B) refers the internal thread
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
UNIT 窶天I UNIT QUESTIONS
1. Define computer graphics. Give a survey of the various graphics system. 2. Explain briefly the video display devices. 3. Explain the process involved in the raster scan system 4. Explain the tasks involved in random scan system 5. Describe the various input devices in detail. 6. Write a note on the hard copy devices.
UNIT-VII UNIT QUESTIONS
1. Define the output primitive. Explain briefly the DDA algorithm in detail. 2. Explain briefly the Ellipse generating algorithm. 3. Explain the circle generating algorithm. 4. Explain the tasks involved in antialiasing. 5. Describe the various line attributes. 6. Write a note on the area fill attributes.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
238
MACHINE DRAWING & COMPUTER GRAPHICS
239
7. Explain the various character attributes.
UNIT-VIII UNIT QUESTIONS
1. Define the term transformation. Explain briefly the various transformations with a neat diagram. 2. Explain briefly the Reflection and Shear. 3. Explain the line clipping algorithms. 4. Explain the tasks involved in polygon clipping. 5. Describe the process of text clipping. 6. Write a note on curve clipping.
UNIT-IX UNIT QUESTIONS
1. Define the term three dimensional transformation. Explain briefly the various 3D transformations with a neat diagram. 2. Explain briefly the 3D Reflection and Shear. 3. Explain the process of projection with a neat diagram. 4. Explain the tasks involved in 3D clipping. 5. Describe the process of viewing pipeline.
UNIT-X UNIT QUESTIONS
1. Explain briefly the various interactive input methods. 2. Explain briefly the various input functions. 3. Explain the basic illumination models. 4. Explain the tasks involved in RGB color model. 5. Describe the various color models in detail.
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINE DRAWING & COMPUTER GRAPHICS
240
6. What do you mean by hue, saturation and intensity? How are they related to dominant color, purity and luminance respectively?
-------------------------------------------------------THE END---------------------------------------------
FOR MORE DETAILS VISIT US ON WWW.IMTSINSTITUTE.COM OR CALL ON +91-9999554621
MACHINEDRAWING & COMPUTER GRAPHI CS
I
Publ i s he dby
I ns t i t ut eofManage me nt& Te c hni c alSt udi e s Addr e s s:E4 1 , Se c t o r 3 , No i da( U. P) www. i mt s i ns t i t ut e . c o m| Co nt a c t :+9 1 9 2 1 0 9 8 9 8 9 8