News Banner

Sunday, 29 January 2012

Digital Graphics Article

The Final Piece, Digital Graphics


Here it is! The final article to my outstanding collection, and hereon in we will be discussing Digital Graphics.
Let's skip the funny banter and all that and get straight down to brass tacks of Digital Graphics.

Pixels, Resolution & Stuff


Pixels! What are pixels? Well, look at your screen now, the image you are seeing is made up of pixels, the single point in a raster image (more on raster's later). It is the smallest unit that a picture can be represented by. Otherwise known as an illumination of your screen, one of many which comprise the actual image.

Now, this is directly linked to resolution, because resolution is how many pixels are on your screen at one time! Simple isn't it? NO.
Let's start with a basic chart of commonly used screen, video and graphic resolutions.

Resolution
Horizontal Pixels
Vertical Lines
Total Pixels
HD
1920
1080
2073600
HD
1280
720
921600
SD
720
480
345600
VGA
640
480
307200
CIF
352
258
90816
QVGA
320
240
76800
QCIF
176
144
25344


 If you can decipher this chart, well done, if you can't, read on. 
The Resolution column is the name of the chosen resolution, with the top two being 1080 HD and 720 HD respectively.
Generally, the more pixels you have in an image, the greater the quality, depth and colour.
A comparison between a SD and 1080 HD image is above, as you can see, greater depth, more colour, detail and vivid imagery.

Now, quickly lets go over bit rate, or, compression rate.
If you snip back to my video article you can learn the different types of compression, and once you've done that come back here and we will carry on.

Done it?

Ok, "The objective of image compression is to reduce irrelevance and redundancy of the image data in order to be able to store or transmit data in an efficient form." So what this means in Laymans terms, the objective of image compression is to reduce parts of the images data in order to be able to store or send the image in a smaller, quicker size.

If you head on down to this image here you can find a really helpful image on this, but unfortunately it is too large to post here without loosing quality, and there fore being coming irrelevant. (see what I did there?)


I'll use this one for now though, see how along the edge of the compressed image there is a loss in quality? You can also see the pixelation of different aspects of the image within it.






Raster & Bitmap

To start off, a raster graphics image, or bitmap, is an image representing a generally rectangular grid of pixels, or points of colour, viewable via a monitor or other display medium. Raster images are stored in image files with varying formats of compression. A bitmap corresponds bit-for-bit with an image displayed on a screen, generally in the same format used for storage in the display's video memory, or maybe as a device-independent bitmap.
Raster graphics are resolution dependent. They cannot scale up to a specific resolution without loss of apparent quality. This property contrasts with the capabilities of vector graphics, which easily scale up to the quality of the resolution wanting to be rendered by them. Raster graphics deal more practically than vector graphics with photographs and photo-realistic images, while vector graphics often serve better for typesetting or for graphic design.

Anyone used this joke yet? 
Raster-based image editors, such as PainterPhotoshopMS Paint, and GIMP, revolve around editing pixels, unlike vector-based image editors, such as Adobe Illustrator or Inkscape, which revolve around editing lines and shapes (vectors). When an image is rendered in a raster-based image editor, the image is composed of millions of pixels. At its core, a raster image editor works by manipulating each individual pixel. Most pixel-based image editors work using the RGB color model, but some also allow the use of other color models such as the CMYK color model.

Side note!

I'm frequently talking about RGB and CMYK, but what are these?
RGB and CMYK are colour models, which is mathematical algorithm for how much colour can be used via multiples.

No, not you.
The CMYK colour model is a subtractive colour model used in colour printing and can also be used to describe printing itself, the CMYK is used to break down the 4 colours used in printing, Cyan, Magneta, Yellow & Key (black, or if you're french, noire). The CMYK model works by partially and sometimes entirely masking colors on a white background. The ink reduces the light that would otherwise be reflective, this model is called subtractive because it's inks subtract brightness from white.

We've all seen this creating a custom colour in MSPaint
Now, RGB colour model or, red green blue, is an additive colour model in which RGB colours are mixed together to create a vast array of different colours. The RGB model name comes from the initals of the three additive primary colours, red, green and blue! Geddit? The main purpose of the RGB colour model is for representation of images on electronic displays, like televisions and computers, but it has also been used in photography, sometimes. Typical inputs for RGB in cameras and scanners!

Stop, vector time


Right, so the opposite of Raster is Vector, the kind of imagery you find in Adobe Flash and Illustrator, is a very much mathematical algorithm based mechanic of graphics.
The video above might help.

Ok, no it didn't help but it's still taking your mind of this mind numbing stuff right? Anyhow, I have digressed rather largely. Vector graphics is made up of vectors, or paths/strokes, which lead through locations called control points. Each of these points has a definite position on the x and y axis work plan. So since vector images are composed of strokes and not pixels, you can change the colour of individual objects without worrying about individual pixels. Colouring vector objects is like colouring with crayons. A drawing program with allow a user to click inside an object and define its colour. Colouring these is much easier than raster. So where can we use this? Well Vector art is ideal for printing since the art is made from a series of mathematical curves it will print very smoothly even when resized, for example, you can print a vector logo onto a business card, then change it to billboard size without a loss in quality. A low res raster graphic would look absolutely destroyed if you attempted this.
Vector art by Petra Stefankova












Bit Depth


Bit deep this, so, let's talk bit depth. Bit depth refers to the colour information stored in an image. The higher the bit depth, the more colors it can store, the simplest image, 1 bit, can only show two colours, B&W. This is because the 1 bit can only store one of two values, 0 white and 1 black. An 8 bit image can store 256 colours while a 24 bit image can display about 16 million (roughly, i'm not counting exactly). Along with an images resolution, the bit depth determines the size of the image, as the bit depth goes up, the size of the image will also go up due to the color information having to be stored for each pixel.
1 Bit


24 Bit or, Truecolor
This bad boy is true 8 bit, yes sir.
8 Bit





Don't you just hate blogger formatting? Anyway, colour space.

Colour space

In the world of graphics, colour is reproduced one of two ways as I already said, CMYK and RGB, to keep things simple i'm going to stick with RGB for colour space.
No device, camera or monitor can accurately reproduce all of the colours that the human eye can see and use. Therefore in order to ensure that colour is accurately and consistently rendered across all the devices, a system of standardized colour spaces was developed for use within the industry (much like PAL and NTSC, not SECAM though, no one likes SECAM). Each colour space, also referred to as a colour profile or model, represents a specific range of colour within the spectrum of visible light that a device is calibrated to reproduce (Spectrums, this reminds me of GCSE science ): )
So what colour spaces are there? sRGB, developed by the big lads at Microsoft and HP, sRGB is the standardized color space for photographers and the internet. It was used to and designed to standardize colours on monitors and printers for typical home and office viewing conditions.
sRGB has the smallest gamut (the complete set of colours), although its range is still huge compared to usual photo papers. If you use sRGB for emailing photos or using consumer printers, you will get consistent results.

Adobe RGB developed by, Adobe, is a colour space in which attempts to duplicate the spectrum that is reproduced by the professional printing CMYK process. It was designed for professional graphic arts users and has become the standard for more advanced photographers, as it is more of a working model than a device model, it's adjustments after are made in aRGB. Use this colour space if printing onto a professional printer, inkjet or if just using your photos for a more professional context.


Conclusion

Right, lets conclude on something a bit more cheery...like, how scanners work?
Here is a little guide from the website HowStuffWorks on how scanners work, don't worry, i'll be adding to this with how this relates to how cameras work, and how this is used within Digital Graphics.

Here are the steps that a scanner goes through when it scans a document:
  • The document is placed on the glass plate and the cover is closed. The inside of the cover in most scanners is flat white, although a few are black. The cover provides a uniform background that the scanner software can use as a reference point for determining the size of the document being scanned. Most flatbed scanners allow the cover to be removed for scanning a bulky object, such as a page in a thick book.
  • lamp is used to illuminate the document. The lamp in newer scanners is either a cold cathode fluorescent lamp (CCFL) or a xenon lamp, while older scanners may have a standard fluorescent lamp.
  • The entire mechanism (mirrors, lens, filter and CCD array) make up the scan head. The scan head is moved slowly across the document by a belt that is attached to a stepper motor. The scan head is attached to a stabilizer bar to ensure that there is no wobble or deviation in the pass. Pass means that the scan head has completed a single complete scan of the document.
  • The image of the document is reflected by an angled mirror to another mirror. In some scanners, there are only two mirrors while others use a three mirror approach. Each mirror is slightly curved to focus the image it reflects onto a smaller surface.
  • The last mirror reflects the image onto a lens. The lens focuses the image through a filter on the CCD array.



So how do digital cameras work too? Well, a digital camera is a camera which takes still images (and videos sometimes) by digitally recording images via an electronic image sensor, or CCD chip.
An image sensor is a device that converts a physical image into an electrionic signal. Early analog sensors were video camera tubes, but are more currently used as Charge Coupled Devices or Complementary Metal Oxide Semiconductors (mouthfull) active pixel sensors.

With a CCD chip an image is projected through a lens onto a capacitor array (or the region of which the photo is there), causing each capacitor to garner an electric charge in ratio with the light intensity of the location. A 1d array, used in in line scan cameras, captures a single slice of the image, which a 2d aray, used in video and still cameras, captures a two dimensional picture corresponding to the image projected onto the lens of the sensor.

Once the array has been exposed to the image, a circuit causes each capacitor to transfer its contents to another chip. The last capacitor in the array dumps its charge into a charge amplifier, which then converts the charge into a volt.
In a digital camera, these volts are sampled, digitized and stored in memory (such as an inbuilt memory or an external SD card).

Well thank you for reading all my articles! I hope you enjoy what else I have to put on here, and for this, you win the winning screen image from the second worst game ever made (as voted by PC World) Big Rigs Over The Road Racing.

Thank you, and goodnight.




Web Animation in Interactive Media


Web Animation Article
Welcome back to another enthralling, thrilling, and just generally amazing blog post.
Now, unlike the other 2 blogs, this one wont be wrote during the NFL playoffs, so hopefully, it will have a much more positive demeanor, I digress.

Within this article I will be explaining the key characteristics of web animation technology through ‘detailed’ illustrative, relevant examples and clearly explaining the differences between, for example, banner ads and animated interfaces.

I will also be doing a bit of jargon busting, or explaining some field specific lexis, if you did one year of English Language.

Uses of Web Animation


This isn't actually an advert, just a joke
Now this is a pretty simple question “Where can I find web animation?”, at one point in your life, you must have seen a pop up ad or a banner ad which claims that if you ‘shoot 5 iPod, you win an iPad. Like, right now, go to a questionable website and sit there for 5 seconds and prepare to be bombarded.
Another obvious use of web animation and where to find it, other than advertising (sometimes the advertising is legitimate, honestly), is on flash portals or flash game sites such as Newgrounds or Armor Games.
Here you can find flash games & movies, some of these games are also Java Applets (embedded Java), as Java can be more powerful than Flash.
So we have covered entertainment and advertisement, but there must be more, right?

Well yes, general user interaction, such a the GUI (General User Interface) which allows to navigate a website more smoothly and flow better is a very popular feature of websites these days. For example, the navigation buttons (how you get between pages) could be animated, IE; When you hover over the page name “home” it could change shape into a house. It’s basic stuff like this that can make it a better experience for the user.


What is animation and how do you create animation?

Here is a timeline complied by Animation History Expert Joshua Mosley, this covers the major pinnacles and turning points of Animation.
1824:Peter Roget presented his paper 'The persistence of vision with regard to moving objects' to the British Royal Society.
1831:Dr. Joseph Antoine Plateau (a Belgian scientist) and Dr. Simon Rittrer constructed a machine called a phenakitstoscope. This machine produced an illusion of movement by allowing a viewer to gaze at a rotating disk containing small windows; behind the windows was another disk containing a sequence of images. When the disks were rotated at the correct speed, the synchronization of the windows with the images created an animated effect.
1872:Eadweard Muybridge started his photographic gathering of animals in motion.
1889:Thomas Edison announced his creation of the kinetoscope which projected a 50ft length of film in approximately 13 seconds.
1892:Emile Renynaud, combining his earlier invention of the praxinoscope with a projector, opens the Theatre Optique in the Musee Grevin. It displays an animation of images painted on long strips of celluloid.
1910:Emile Cohl makes En Route the first paper cutout animation. This technique saves time by not having to redraw each new cell, only reposition the paper.

1919:             Pat Sullivan created an American cartoon "Felix the Cat."

1926:The first feature-length animated film called "El Apostol" is created in Argentina.
1923:Walt and Roy Disney found Disney Brothers Cartoon Studio.

1923:Walt Disney extended Max Fleischer's technique of combining live action with cartoon characters in the film "Alice's Wonderland".
1928:Walt Disney created the first cartoon with synchronized sound called "Steam Boat Willy".
1982:Tron, MAGI, movie with CG premise
1988:Willow uses morphing in live action film
1993:Jurassic Park use of CG for realistic living creatures
1995:Toy Story first full-length 3D CG feature film


Platforms of Digital Animation

Flash me.
Ahar there, use me to get flash Confucius say.
No, seriously, Adobe Flash (Or Macromedia Flash 8 as i'm still running) is probably the most popular, and accessible (not cheapest, accessible) means of making flash, due to it's rather simplistic nature, and it's ability to be the complete opposite and allowing you to code a physics engine, or something like that! 
All it takes is a creative mind, ability to use frames, a bit of tweening and generally, the ability to draw something.


A frame is simply a still image, frankly, if you think of it as a flip book, a frame is the single piece of paper.
As you can see from this picture, layer 1 (no need to explain here, a layer is literally a collection of frames) contains 20 keyframes, containing a person, probably moving, running at 20 frames per seconds.


But what does all this mean?
So let's break it down.
Every one of these frames contains the image of the person, but every frame the image will be changing, possibly moving the leg or the arm, and if this carried on for 20 frames running at 20 frames per second, you would have a one second loop of a person running, simple.


This couples with the idea of 'Persistence of Vision', in which the brains interpretation of physical motion makes an image being replayed at a high enough speed, creates fluid and smooth movement between an image.


Jargon Busting
Here is a little glossary of Animation terms you make come across in your travels;
Frame Rate ;- Frame Rate or FPS is the rate (speed) of which frames are progressing along a timeline, television you watch is at 25 FPS, the defacto frame rate for animation is 24
Frames ;- A frame (singular) is a still image, and frames are a series of still images, played at a certain FPS to create the illusion of motion
Tweening ;- Tweening, or inbetweening, is the process of the computer generating intermediate frames between two set images, again creating the illusion of motion.
Flash ;- Flash is the program used for creating .swf animations, you can find examples of these everywhere as previously mentioned. Flash is ALSO a plugin for your computer allowing you to watch .swf files on the internet.
Bender Bending Rodriguez, a popular cell shaded character (my favorite robot, ever)
Cell ;- Cel-shaded animation (also known as Cel shading or Toon shading) is a type of rendering designed to make computer graphics appear to be hand-drawn.
Stop Motion ;- Stop motion is pretty much taking a picture, as a frame, then another picture with slight adjustments, and so on and so forth.
Claymation ;- Exactly the same as stop motion, but the 'actors' are all made of clay.
Conclusion


To conclude! As we can see, we use flash in our daily internet lives, whether it's in the form of a .gif you find on a questionable website, or just watching your favorite music video on YouTube, we need flash.
You don't have to be a great drawer, and you don't have to be smart to create something that millions of people can watch (whether they like it or not is a completely different story).

Sunday, 22 January 2012

Video in Interactive Media



Now the first question you could be asking yourself is, ‘how is video used in interactive media?’ well, this time round I intend to answer that.

What is the definition of Video in Interactive Media?

A method of communication in which the program's outputs depend on the user's inputs, and the user's 
inputs in turn affect the program's outputs. Interactive media engage the user and interact with him or her in a 
way that non-interactive media do not. Websites and video games are two common types of interactive media. Movies and most TV shows are generally not considered interactive media; however, shows that require audience participation could be considered interactive media.
(Investopedia.org)
A feature of media interactivity is that the machine and the person controlling it, both have a mutual role in the interactivity, they are both active. In fact, any form of interface between the end user and audience should be considered interactive media.


Where can I find it?

You can find Video in Interactive Media, everywhere! You can find it in the World Wide Web, e-mails, DVD’s, CD’s, Mobile Phones/Devices and even in your local supermarket.

Think about it, when you are using the self checkout at Tesco’s (or IKEA as shown here) the little woman on the screen showing you how to use it, is a video, and it’s interactive, therefore, it’s a Video in Interactive Media!

When you get a CD single (you don’t anymore, but you know what I mean), you generally get a bonus track hidden on your CD for use on a computer, usually a music video; this is another example, of Video in Interactive Media.

Video Games are another form of this, simply because it’s a Video, Game. A video, controlled by you, this, along with Websites makes for the 2 most commonly used Videos in Interactive Media. TV shows and Movies aren’t generally considered interactive media, unless there is a form of audience participation.
Platforms
Platforms, or simply put, what you view/use the media with. A very immediate example is this blog right here, this is a piece of interactive media, because you can comment on it. As previously mentioned, Websites are ranked 2# in the grand scheme of most commonly used interactive media. A popular platform these days are next gen phones, my current phone, Google Nexus, allows me to watch HD YouTube videos, stream from any Java/Flash video streaming site, watch Sky Sports, Sky 1 etc, and play games such as Fifa 12 and Madden 12. A drawback of using mobile phones for Interactive Media such as Internet TV and Video Games is it is hugely consuming on the battery. Currently, if I play a game such as Fifa on my phone, it will drain 10% of my battery after around 5 minutes of game play, this is where a similar platform comes into play. The iPod touch was developed for just this type of stuff, with a more equipped battery, you can watch movies and play games on long journeys (going on holiday) and still have enough battery for your wait for the bags.
But with the introduction of the new Duracell Mobile Charger, you can charge your phone out and about using 4 AA batterys.
There are also other mobile devices offering this kind of service, Tablets such as the iPad and Tablet PC’s allowing for full windows experience can vary in quality, as some screens can barely seen under light, and batteries can be very temperamental with these. Another drawback with Tablets is their size, although this could be considered an advantage (bigger screen for movies and games).

Lossy Vs Lossless
This is when stuff starts getting considerably more difficult and somewhat a bit more boring (for most of you). So let’s start with their contexts, compression.
What is compression? Compression is a way of making a file smaller whilst minimizing quality that is being lost; here is an example of an uncompressed image, against a compressed image.
So what is lossy compression? Lossy compression is a form of data enconding, or compressing, of which some of the image is ‘lost’. The procedure aims to minimize the amount of data that need to be held, handled, and/or transmitted by a computer.
The advantage of lossy methods over lossless methods is that in some cases a lossy method can produce a much smaller compressed file than any lossless method, while still meeting the requirements of the application.
The different versions of the photo of the dog demonstrate how much data can be dispensed with, and how the images become progressively coarser as the data that made up the original one is discarded (lost). Typically, a substantial amount of data can be discarded before the result is sufficiently degraded to be noticed by the user, repeatedly compressing and decompressing the file will cause it to progressively lose quality. This is in contrast with lossless data compression, where data will not be lost via the use of such a procedure.
You can lossy compress 3 types of media, not just images, you can also compress music and video, popular formats such as MPEG-4, H.264, JPEG, AAC, MP3, AMR and OGG can be lossy compressed.
Lossless
Lossless compression is another type of data compression which allows the exact data to be reconstructed from the compressed data. The term ‘lossless’ is in juxtaposition to lossy data compression, which only allows an approximation of the original data to be reconstructed, in exchange for better compression rates. Lossless data compression is used in many applications. For example, it is used in the ZIP file format, winRAR and the MP3 encoder, LAMEMp3.
Lossless compression is used in cases where it is important that the original and the decompressed data be identical, or where deviations from the original data could be detrimental.
Some image file formats, like PNG or GIF, use only lossless compression, while others like TIFF and MNG may use either lossless or lossy methods. Lossless audio formats are most often used for archiving or production purposes, with smaller lossy audio files being typically used on portable players and in other cases where storage space is limited and/or exact replication of the audio is unnecessary.

Formats which use Lossless compression include, but are not limited too; FLAC, REAL, WMA, PNG, TIFF, Quicktime, MPEG.
The compression rate is 5 to 6 % in lossy compression while in lossless compression it is about 50 to 60 % of the actual file.
Video File Formats
Let’s talk video file formats, below is a small list I composed myself of the most common and frequently used video formats.

·         .3gp – Previously, the most common video format for mobile phones, lossy compression is used, for the file has to be very small sized to send in MMS messages which generally have a very, very small cap on what you can send, size wise.
3gp - The Best Quality, ever.
·         .AVI – Audio Video Interleave, introduced by Microsoft in 1992, this format has become synonymous with PC’s around the world, AVI was not intended to contain video using any compression technique which requires access to future video frame data beyond the current frame. AVI is currently a lossless compression format.
·         .MPEG-4 – Introduced by Apple, is the premier HD codec for video files, as it allows a huge data rate at a lossless compression.
·         .WMV – Windows Media Video, once again, introduced by Microsoft, it was released for use in internet streaming appilications (more on this later) and as a competitor for RealPlayer, through standardization, WMV has become the go to choice for encoding HD DVD and Blu Ray.

To Conclude

A few last notes to consider, internet streaming.
Internet streaming really has come to the forefront of how media is displayed to a mass audience, with innovations such as BBC I-Player and 4OD, internet streaming really is big business. However, what people need to consider when creating a stream is, resolution and bit rate.
Generally, the greater the resolution, the greater the quality, as long as your codec and file can be stretched to this size with lossless compression, and if the file is native to a resolution of the size, for example, the quality lost with a video of a native 800x480, and you want to display in 1920x1080, you will have a hell of a problem stretching it to that size without loosing any quality.


Bit-ratebit-rate is a rate of how much information can be transferred at any one time, for example, Blu Ray transfers at 40Mbit/S, that's a whole forty megabytes a second, the size of 13 average length mp3's, where as SDTV (freeview, standard non HD channels) transfer at a meer 3.5Mbit/s. So what do you do? Stream at 720p quality but sacrifice a whole 19Mbit/s bandwith? When the U.K average is 8.2 MB/s internet speed on Virgin Media?
You will have to wait for the programme to buffer, for a long while.


I hope this has been helpful, entertaining or just simply something to take your mind of doing this bit of work yourself.


Cheers.