StudentShare
Contact Us
Sign In / Sign Up for FREE
Search
Go to advanced search...

Computer Science - Lab Report Example

Cite this document
Summary
Bresenham’s algorithm calculates the locations of the pixels in the first 45 degrees. The assumption is that the circle is centered at the point (0,0). This means that for every pixel (x,…
Download full paper File format: .doc, available for editing
GRAB THE BEST PAPER94.3% of users find it useful
Computer Science
Read Text Preview

Extract of sample "Computer Science"

Download file to see previous pages

The multiplications however are by 4, and we can accomplish this by shifting left twice. This is the simplest approach to solving the resolution problem. It is majorly used for drawing curves with slopes between −1 and 1. Each pixel both below and above are drawn thus resulting in a curve that has a thickness of 2n+1 pixel in the y axis (Drawing Lines and Curves (Introduction to Computer Graphics Using Java 2D and 3D). It works better for thinner lines. In this algorithm the pixels are duplicated in columns for the lines with – 1 < slope < 1 and in rows for all other lines .

This results in lines that are vertical or horizontal towards the end thus displeasing for thicker lines as illustrated below. Straight lines also have different thickness to the lines at an angle in which the thickness of the line is defined as the distance between the primitives boundaries perpendicular to the tangent. For a thickness parameter t, the horizontal/vertical line has the thickness t, while the one drawn at 450 has the average thickness of The lines are almost similar but this line is thicker at the endpoints.

The width of the straight lines are thickest for parts with slopes of ±1 whereas the thickness of circular objects varies with the point it is in. In moving pen algorithm the bits are masked off outside the circular region which is a complex task. The brute force writes pixels motre than once because the pens footprints extend beyond the adjacent pixels. The best strategy is to make snaps of the footprints to calculate spans of the following footprints at the bordering pixels as the diagram shows.

The pixel duplication is a faster algorithm of drawing lines. it is however not the best algorithm for drawing thick lines because it uses a crude mode to draw the lines. It is thus suited to primitives that are not too thick. In java lines are drawn by the drawLine() method. The method has the following arguments void drawLine(int startX, int

...Download file to see next pages Read More
Cite this document
  • APA
  • MLA
  • CHICAGO
(“Computer Science Lab Report Example | Topics and Well Written Essays - 1000 words”, n.d.)
Computer Science Lab Report Example | Topics and Well Written Essays - 1000 words. Retrieved from https://studentshare.org/information-technology/1653252-computer-science
(Computer Science Lab Report Example | Topics and Well Written Essays - 1000 Words)
Computer Science Lab Report Example | Topics and Well Written Essays - 1000 Words. https://studentshare.org/information-technology/1653252-computer-science.
“Computer Science Lab Report Example | Topics and Well Written Essays - 1000 Words”, n.d. https://studentshare.org/information-technology/1653252-computer-science.
  • Cited: 1 times

CHECK THESE SAMPLES OF Computer Science

Computer Science Information System

This system will be used by both members and fitness consultants to track participation in various fitness activities, such as free weights, volleyball, swimming, stair climbers, and yoga and aerobic classes. The DSS system will be implemented in the form of a client server model with an interface, possibly a computer visual display unit, at all the five centers and will act as a platform to the prospective and current members and consultants....
3 Pages (750 words) Essay

Major Knowledge Advancements in Wireless Information

We have seen computer been totally wireless from mouse to CPU everything is in our pocket.... Advancement in technology had enabled us to see what might be one of the miracles for our ancestors.... Advancement in wireless technology is one of these miracles.... But have you ever thought of a reason behind this wireless technology Inventions took place as a result of need....
3 Pages (750 words) Essay

Logics in Computer Science

Aspirin aggravates peptic ulcer, so that tree is not possible.... The next option is alcohol for pain and that is possible.... Second, he also complains of diarrhoea and does not have impaired liver function, so… Recommended(peter, alcohol+lomotil).... Similarly, for Mary: recommended(mary, aspirin) – no medicine for diarrhoea....
4 Pages (1000 words) Essay

Posts Related to Computer Science

The increased developments in the technology sector have attracted increased attention to this branch of science making different authors to write articles that highlight different aspects of Computer Science.... This essay will give a summary of ten different posts that relate to Computer Science.... g… Computer Science is defined as a branch of science that specializes with studies that relate to computation theories and design of computers....
2 Pages (500 words) Essay

Computer Science Questions

They should be… Therefore, a committee should be formed that is comprised of members from all the relevant stakeholders, including the senior management personnel Computer Science Questions al Affiliation) Question One Prencipe asserts that senior management cooperation is very important for the success of any project in a company.... uestion TwoWilson argues that in order to determine the threat scale during computer forensic tactics preparation, one identifies the rate of spread of the malicious program (worm, virus)....
1 Pages (250 words) Essay

Graph Theory in Computer Science

The paper 'Graph Theory in Computer Science' presents graph theory which is an essential part of Computer Science.... Graph theory and Computer Science are complementary to each other.... The significance of graph theory in Computer Science is remarked by Dr.... Thinking about the applications of graph theory in Computer Science, the first point that comes to mind is that "the World Wide Web can be modeled as a directed graph where each node is a Web page and each hyperlink is an edge or line....
8 Pages (2000 words) Assignment

Computer Science: Xbox 360

This article "Computer Science: Xbox 360" presents a computer game console, the Xbox 360, which can help in finding defects in the heart and prevent heart attack, it is the beginning of a revolution.... At last, it's the wonder of Computer Science!... It seems that in the near future, Computer Science is going to help doctors in a myriad of ways.... Scarle, the computer scientist at the University of Warwick in England who has devised the new way of using the Xbox 360, is sure of its potential use by students and early-career scientists in fast and cheap computing of the related data....
1 Pages (250 words) Article

Privacy in Computer Science

… The paper "Privacy in Computer Science" is an outstanding example of an essay on technology.... The paper "Privacy in Computer Science" is an outstanding example of an essay on technology.... In Computer Science, privacy refers to the availing of data only to those deemed as authorized through security features afforded through various means like passwords, applications, and so on....
8 Pages (2000 words) Essay
sponsored ads
We use cookies to create the best experience for you. Keep on browsing if you are OK with that, or find out how to manage cookies.
Contact Us