.NET news » Graphics Graphics Rss Feed

download

Realtime Chart and Graph in One

I worked on a project in which I needed a graph control. Later on, I was also required to use a chart control. So I thought, hey, let's just combine them both into one nice and simple control..
16 May 2007, 15:33:00   Source: Realtime Chart and Graph in One   Tags: Graphics Components

Star Wars style text scroller

You can find text scrollers in many programs, especially in their "About" dialogs. In most cases, it's a simple colored text which moves up. In this article, I attempted to create something unusual. I decided to write an "outgoing" text component, which looks like a 3D effect (like in the intro to the Star Wars movies).

GDI+ provides many "easy to use" objects and functions. Using these functions, you can do something special without much trouble. Before writing this component with the help of GDI+, I tried to create it with GDI. This required much more time and resulted in ten times more code. It seems to be a hard task, but later I recreated this same component in GDI+. That was easy. After that, I decided to write this article to demonstrate some features of GDI+..

16 May 2007, 13:49:00   Source: Star Wars style text scroller   Tags: Graphics Components

A simple thermometer chart for ASP.NET

jThermometer is a class for creating thermometer charts of the type used generally to show progress toward a fund raising goal. The chart uses GDI+ to compose an image and stream it out to the browser.
15 May 2007, 15:43:00   Source: A simple thermometer chart for ASP.NET   Tags: ASP.NET Graphics

Create a Custom Color Shading in C#

In some graphics applications, you may want to directly map the color of a surface object according to a given set of color data. In this article, I will show you how to create such a custom color shading.
15 May 2007, 14:09:00   Source: Create a Custom Color Shading in C#   Tags: Graphics

Use Transformations to Draw Your Own Great Graphs

Visual Studio comes with a huge number of pre-built components and controls, including controls for entering and displaying text, letting the user pick options and make choices, displaying values graphically, interacting with databases, displaying dialogs, and containing and arranging other controls. But it comes with surprisingly few controls for displaying graphical data. If you don't want to shell out big bucks for a third-party graphing control, you're pretty much stuck drawing your own pictures on a PictureBox.

Fortunately, drawing graphs isn't all that hard. Mostly it's a matter of drawing lines or boxes to connect some data points. The only really tricky details involve translating data values to and from the pixel coordinate system used to draw on the control..

11 May 2007, 15:07:35   Source: Use Transformations to Draw Your Own Great Graphs   Tags: Graphics

Simon: memory game from the eighties

Simple memory game that uses shaped buttons.
11 May 2007, 10:13:00   Source: Simon: memory game from the eighties   Tags: Examples Graphics

A C# image enhancement filters library

This project started from a need. A need to have a simple image/photo .NET filters functionality to style and enhance pictures to be displayed on the web (or any other place for that matter). True, there are some filter libraries scattered around the web for doing stuff like a WaterMark or a GrayScale or even a collection of those (ImageMagick). In most cases they are very basic or unhelpful for styling images. Furthermore, the .NET System.Drawing.* namespace doesn't provide any basic or sophisticated capabilities. For example, there isn't a proper rotate or resize functionality. So the goal was to collect all of the nice .NET filters that are out there into a single package and to extend it by providing more useful and styled filters..
11 May 2007, 09:12:00   Source: A C# image enhancement filters library   Tags: Graphics

Terrific Transformations

Learn how to use .NET transformations to make rotating, stretching, and moving objects simple--even for complex objects such as paths and text.
1 May 2007, 16:16:16   Source: Terrific Transformations   Tags: Graphics

QuickGraph: A 100% C# graph library with Graphviz Support.

This article presents a Generic Graph Library, 100% C#. This library is an attempt to port the Boost Graph Library (BGL) from C++ to C#.

Graph problems arise in a number of situations (more often that you would think): file compilation order, network band-with, shortest path, etc. The library provides the basic data structure to represent vertices, edges and graphs, and also provides generic implementation of various graph algorithms such as the depth-first-search, the Dijkstra shortest path, etc.

As the library comes with a full NDoc reference manual, this article will not enter into deep coding details.

23 Apr 2007, 12:45:00   Source: QuickGraph: A 100% C# graph library with Graphviz Support.   Tags: Graphics

ImageTraverser

Microsoft's System.Drawing.Bitmap class is deceptively simple - just create a Bitmap from a file, then use the GetPixel() and SetPixel() methods to manipulate the image, right? Unfortunately, these two methods are terribly slow, so a lower-level traversal via pointers is necessary for decent performance.

However, there is a reason that the .NET language designers are steadily moving away from pointers - code that utilizes them is usually brittle and error-prone, even when run under the CLR. Therefore, to minimize and isolate the use of unsafe code in my projects, I have encapsulated the necessary unsafe pointer code in this class, plus I have added several handy methods for dealing with image pixels.

The end result is a robust class for traversing images (ie, retrieving and setting individual pixels) - hence the moniker ImageTraverser.

19 Apr 2007, 14:48:00   Source: ImageTraverser   Tags: Graphics Performance