1(a) what are the advantages and disadvantages of command line and graphical user interface? Ans. Command Line Argument Graphical User Interface 1. The advantages of Command Line interface 1. It is very easy to use for beginners and lay are the processing will be faster, needs less man. There is no complicated command to memory and less CPU time for processing. learn and it is also useful for data transfer in client server application. 2. The disadvantages of CLI are it is confusing 2. The disadvantages are it is taking much and will not work with slight mistake in memory space and much CPU time for command and a large no of commands need processing. to be learn. (b) Differentiate the half-toning and dithering. Ans: Halftoning: Halftoning is a process that simulates shades of gray by varying the size of tiny black dots arranged in a regular pattern. This technique is used in printers, as well as the publishing industry. It provides more colors considering different no of pixels. Another technique used for generating digital halftoning images is dithering. Unlike patterning, dithering creates an output image with the same number of dots as the number of pixels in the source image. Dithering can be thought of as thresholding the source image with a dither matrix. The matrix is laid repeatedly over the source image. Wherever the pixel value of the image is greater than the value in the matrix, a dot on the output image is filled. (c) Illustrate the set of equations for relational transformations. Ans. A spatial transformation defines a geometric relationship between each point in the input and output images. An input image consists entirely of reference points whose coordinate values are known precisely. The output image is comprised of the observed (warped) data. The general mapping function can be given in two forms: either relating the output coordinate system to that of the input, or vice versa. Respectively, they can be expressed as where [u,v] refers to the input image coordinates corresponding to output pixel [x,y], and X, Y, U, and V are arbitrary mapping functions that uniquely specify the spatial transformation. Since X and Y map the input onto the output, they are referred to as the forward mapping. Similarly, the U and V functions are known as the inverse mapping since they map the output onto the input.
(d) Give two difference between Flood fill and Boundary Fill algoritm. Ans. Flood fill colors an entire area in an enclosed figure through interconnected pixels using a single color. It is an easy way to fill color in the graphics. One just takes the shape and starts flood fill. The algorithm works in a manner so as to give all the pixels inside the boundary the same color leaving the boundary and the pixels outside. Flood Fill is also sometimes referred to as Seed Fill as you plant a seed and more and more seeds are planted by the algorithm Boundary Fill is another algorithm used for the purpose of coloring figures in computer graphics. It is so similar to Flood Fill. Boundary fill fills the chosen area with a color until the given colored boundary is found. This algorithm is also recursive in nature as the function returns when the pixel to be colored is the boundary color or is already the fill color. Flood Fill is one in which all connected pixels of a selected color get replaced by a fill color. Boundary Fill is very similar with the difference being the program stopping when a given color boundary is found. (e) What is match band effect in shading ? Ans: .Match band effect is the limitation of constant intensity shading. In the constant intensity shading each surface is of the polygon is fill by single intensity values.sot that it provides match band effect on the border line of each surface. So it does not provides smooth surface of the polygon (f) Write the limitations of line draw algorithm. Ans: DDA line draw algorithm is a simplest algorithm which does not required special skill for implementation. It is a faster method for calculating pixel using direct formula y= mx + c. Drawbacks are : It draft away from the actual line path due to rounding of the float value to integer. The algorithm is orientation dependent. Hence end point accuracy is poor. Due to floating point calculation it needs much more time for processing. Round operation is more expensive. Successive addition of the floating point increments is used to find the pixel position but it take lot of time to compute the pixel position (g) What are the advantages of representing a point in the homogeneous coordinate systems? Ans. Homogeneous coordinate systems are very useful for composite transformation. It is difficult to multiply more than one matrix using Cartesian coordinate system.To operate more than one transformation in a matrix representation it is not possible to express all the operation with in Cartesian coordinates it need to include a dummy coordinate to make 2x1 position vector matrix to 3x1 vector matrix.So it needs one dummy coordinate called homogeneous coordinate systems. i,e (h) What are key frame systems ? Ans. key frame in animation and filmmaking is a drawing that defines the starting and ending points of any smooth transition. They are called "frames" because their position in time is measured in frames on a strip of film. A sequence of key frames defines which movement the spectator will see, whereas the position of the key frames on the film, video or animation defines the timing of the movement. Key frames are:1)morphing and simulation 2)Motion using key frames 3)Shape transformations without shape hints 4)Shape transformations using shape hints 5)Color transformations using key frames etc.
(i) Define Spline curve. Ans. Splines are smooth curve passing through given set of points.It can be eighter closed or opened depends upon types of polynomials and characterazied matrix.It is of two types.i) Interpolated ii)Approximated (j) Differentiate Gouraud and Phong Shading. Ans. Gouraud shading Constant intensity is apply over flag surface area.It is not applicable for cylindercal surface This approach develop by Scientist Gouraud approach is intensity interpolation over the cycle This object is an polygon and determine the average normal vector at each polygon vector Navg=(N1+N2+N3+………..+Nn)/n Navg= S1------------Navg*I1 S2--------------NavgI2 .. Sn -------------------Navg*In Apply illumination model to each vertex calculate vortex and linearly interpolate /distribute the vertex intensity over the surface of the polygon. 4 .repeat 4 and 3 for each polygon Phong shading:It is shading apply for more blending function. The object is assumed as polyhedron and having no of curve surface. Determine the average of unit vector of each unit vector and calculate the intensity of the respecting surface. S1------------Navg1*I1 S2--------------Navg2*I2 .. Sn -------------------Navgn*In Surface illumination model to calculate the each intensity 2.(a) Explain how device independence can be achieved by using display file. The device independent file format (DVI) is the output file format of the TeX typesetting program, designed by David R. Fuchs and implemented by Donald E. Knuth in 1979. Unlike the TeX markup files used to generate them, DVI files are not intended to be human-readable; they consist of binary data describing the visual layout of a document in a manner not reliant on any specific image format, display hardware or printer. DVI files are typically used as input to a second program (called a DVI driver) which translates DVI files to graphical data. For example, most TeX software packages include a program for previewing DVI files on a user's computer display; this program is a driver. Drivers are also used to convert from DVI to popular page description languages (e.g. Postscript, PDF) and for printing. DVI is not a document encryption format, and TeX markup may be at least partially reverseengineered from DVI files, although this process is unlikely to produce high-level constructs identical to those present in the original markup, especially if the original markup used high-level TeX extensions (e.g. LaTeX). DVI differs from PostScript and PDF in that it does not support any form of font embedding. (Both PostScript and PDF formats can either embed their fonts inside the documents, or reference external ones.) For a DVI file to be printed or even properly previewed, the fonts it references must be already installed.
Also, unlike PostScript (but like PDF), DVI is not a full, complete programming language, though it does use a limited sort of machine language. 2. (b) Explain back face removal algorithm for hidden surface elimination. These back faces contribute to approximately half of the total number of surfaces. Since we cannot see these surfaces anyway, to save processing time, we can remove them before the clipping process with a simple test. Each surface has a normal vector. If this vector is pointing in the direction of the center of projection, it is a front face and can be seen by the viewer. If it is pointing away from the center of projection, it is a back face and cannot be seen by the viewer. Depth-Buffer Method (Z-Buffer Method): Algorithm: 1. Initially each pixel of the z-buffer is set to the maximum depth value (the depth of the back clipping plane). 2. The image buffer is set to the background color. 3. Surfaces are rendered one at a time. 4. For the first surface, the depth value of each pixel is calculated. 5. If this depth value is smaller than the corresponding depth value in the z-buffer (ie. it is closer to the view point), both the depth value in the z-buffer and the color value in the image buffer are replaced by the depth value and the color value of this surface calculated at the pixel position. 6. Repeat step 4 and 5 for the remaining surfaces. 7. After all the surfaces have been processed, each pixel of the image buffer represents the color of a visible surface at that pixel. 3. (a) Explain the components of MIDI interface. Ans: - MIDI is the acronym for Musical Instrument Digital Interface .Components of a MIDI interface are given below. Synthesizer: It is a sound generator (various pitch, loudness, tone color).A good (musician's) synthesizer often has a microprocessor, keyboard, control panels, memory, etc. Sequencer: It can be a stand-alone unit or a software program for a personal computer. (It used to be a storage server for MIDI data. Nowadays it is more a software music editor on the computer. It has one or more MIDI INs and MIDI OUTs. Track: Track in sequencer is used to organize the recordings. Tracks can be turned on or off on recording or playing back. Channel: MIDI channels are used to separate information in a MIDI system. There are 16 MIDI channels in one cable. Channel numbers are coded into each MIDI message. Timbre: The quality of the sound, e.g., flute sound, cello sound, etc.Multitimbral - capable of playing many different sounds at the same time (e.g., piano, brass, drums, etc.) Pitch: Musical note that the instrument plays. Voice: Voice is the portion of the synthesizer that produces sound. Synthesizers can have many (12, 20, 24, 36, etc.) voices. Each voice works independently and simultaneously to produce sounds of different timbre and pitch. Patch: The control settings that define a particular timbre. (b) Distinguish parallel and Prospective Projection. Ans) In case of parallel projection the the center of the projection is at infinite distance. Example sun light fall on a particular object. It preserves relative proportion of object. Accurate view of various sides of an object is obtained. It doesn’t give us realistic representation of appearance of 3D object.