Photoshop Tutorials

Adobe photoshop logoI found three excellent Adobe Photoshop tutorials that every digital photographer should read.  All three were written by Jay Kinghorn, who is a Photoshop expert.

Tutorial 1: Intro To Layer Masks (http://photo.net/learn/digital-photography-workflow/advanced-photoshop-tutorials/layer-masks/)

 

Tutorial 2: Using Photoshop`s Smart Objects (http://photo.net/learn/digital-photography-workflow/advanced-photoshop-tutorials/smart-objects/)

 

Tutorial 3: Advanced Masking (http://photo.net/learn/digital-photography-workflow/advanced-photoshop-tutorials/advanced-masking/)


Adobe finally updates Flash CS4

This is kind of old news since this happened in mid-May, but I just finally got around to it. 

Adobe released an update for Flash CS4 that fixed a number of annoying issues; one of them is relatively slow performance when dragging objects on stage.  I haven`t had a chance to check out the full list of fixes released in this update, but the list can be found at http://blogs.adobe.com/rgalvan/2009/05/flash_cs4_update_now_available.html.

 


Using online resources to drive your business

A few days ago PDN (Photo District News) magazine published an article titled "The Five Biggest Photographers on the Internet".  In this article, they interviewed 5 iconic photographers about how they use online resources such as Facebook, Twitter and Flickr to drive their business. 

One of the photographers, Christopher Becker (http://www.beckersblog.com) is my personal icon when it comes to wedding photography and self-promotion.  He is an incredibly talented photographer who managed to build an amazingly profitable wedding photography business and is generally considered one of the highest-paid wedding photographers in the world.

I decided to learn from TheBecker and from the others and expanded my online presence to Facebook and Flickr.  From now on, I`ll be posting my photographs not only on this side and on WideOpenLens.com like I`ve been doing so far - my photographs will also appear in my Facebook album and in my Flickr photostream.


Flooded house + lack of sleep + too much work

After two weeks of silence I finally managed to find time to make a post.  This time I actually have a good excuse (better than my usual "I was feeling lazy").  Last Wednesday Pittsburgh got hit with a really bad thunderstorm.  Many houses in my neighborhood were flooded, including mine.  We lost power around 8PM and once my sump pump stopped running, within minutes my basement had 6 inches of water.  My basement server room was completely flooded - I lost one of my desktops and my 2TB RAID backup.  Luckily, I did not lose any data, since I keep a full set of backups at my office at the University of Pittsburgh.

My flooded basement, 3 AM

 

My flooded basement, 3 AM

The worst part is that the water damaged our water heater and we had no hot water for almost a week.  Four different plumbers came in, replaced one part after another, until the only original part was the tank itself before the heater started working again.  For days I was forced to take cold showers and we had to heat up water on the stove to bathe my 2-month-old daughter. 

I spent the entire last week (when I wasn`t at work or shooting weddings) ripping out the floor from my server room, throwing away damaged items from the basement and washing every nook and cranny with bleach.  Let me tell you, it had been a week from hell.


Flash TextField Embedded Fonts Bug

I’ve been working on a zooming logic for a Flash-based application when I ran into a serious issue - if the stage was zoomed out below approximately 70%, when nodes were dragged around the stage, coordinates were saved to the database incorrectly. Essentially, something changed the coordinates of the nodes relative to their position on the stage during zooming.


 
For weeks I wrecked my brain trying to solve the issue.  Finally, my boss OK’d brining in a Flash expert. 
Last Thursday I met with Ben Pritchard, of www.pixelfumes.com.  Ben is also the co-founder of Pittsburgh Flash Users’ Group (http://pittmfug.blogspot.com/). 
Right away, he noticed that when the stage was zoomed out, text fields (labels) inside nodes did not resize at the same rate as the nodes themselves, thus making nodes larger and changing their relative x- and y- coordinates.

Node map zoomed out below 70 percent


We solved this issue by anti-aliasing and embedding the fonts of the labels:
textField.antiAliasType = AntiAliasType.ADVANCED;
textField.embedFonts = true;


However, Flash CS3 and Flash CS4 have a known bug where programmatically-generated embedded fonts will not be displayed on stage unless there is a manually-added text object that already exists within the application. The way to solve it is to manually add a text field to the side of the stage and set its properties as specified below:

  1. Properties of the manually-created hidden text field should exactly match the properties of the programmatically-generated embedded text field (i.e. fonts, font sizes, font family, etc…).
  2. Text field should be set to “Dynamic Text”
  3. Embed properties should be set to the following:
  4. Uppercase [A…Z] (27 glyphs)
  5. Lowercase [a…z] (27 glyphs)
  6. Numerals [0…9] (11 glyphs)
  7. Punctuation [!@#%...] (52 glyphs)
  8. Anti-alias property should be set to “Anti-alias for readability”

 

 

Flash CS3 and CS4 font embedding bug


jsBin

jsBin screenshot

Last week, while attending the Spring <br /> Web developers` conference in Athens, OH, I discovered jsBin (http://jsbin.com/), an online virtual HTML and JavaScript editing environment.  Check it out at http://jsbin.com/


Just because you can, it does not mean that you should (or something like that)

High Dynamic Range (or HDR) photography has been around for a while and has been slowly gaining popularity over the last few years.  When we ditched our film cameras for shiny new digital ones, our images lost one important quality – dynamic range.   Dynamic range in imaging refers to the number of colors that can fit on an image between the darkest and the brightest point.  Therefore, when you are taking an image with your digital camera in a high-contrast situation (for example, in bright sunlight), when you meter for shadows, you will lose details in your highlights, and vice versa.

HDR photography is one solution that people use to cope with dynamic range clipping issues.  Basically, the way it works is that you take at least 3 images of the same scene – one metered for shadows, one with normal exposure and one metered for highlights.  Many SLRS will allow automatic bracketed bursts, where the first shot will be exposed normally, the second will adjust exposure compensation to -1 and the third to +1.  Then you would use Adobe Photoshop’s PhotoMerge or Photmatix (http://www.hdrsoft.com/) to merge the three images and recover details from problem areas.

That’s HDR in a nutshell.  If you want to find out more, the article on High Dynamic Range Imaging on Wikipedia is very helpful.

Many people (such as myself), play with HDR, make a few cool-looking images and abandon the concept.  While HDR produces really amazing images, in most cases those images stop looking like photographs and look more like over-processed illustrations.  Sometimes it works, sometimes it doesn’t.

Unfortunately, there are some people who take HDR to a completely ridicules level. I usually try to follow the axiom of “if you cannot say anything nice about someone, don’t say anything at all”, but in this case I am going to make an exception.  A few days ago, one of my coworkers (who is also a photographer) forwarded me the following website:

http://www.danielsdiaz.com/adrian.html

Daniel Diaz, the gentleman who runs this website, is obviously a good photographer, at least from the technical point of view.  His exposure and compositions are excellent in most cases.  Alas, his post-processing has long left the field of photo editing and ventured into the grey area of photo manipulation.

I am not claiming to be a great photographer.  I have been learning the craft since I was eight years old, and more often then not I am humbled by the photographic talent that exists in the world (just look at Vincent Laforet’s website – I’d kill to be as talented as he is).  But I always drew a very strict line between photo editing and photo manipulation.  When I am editing photographs from a wedding, I spend hours cleaning up errant exit signs, smudges on bride’s dress, color-correcting, sharpening, etc.  However, I would never do anything to change the nature of the image.

Using HDR for portrait photography has always been a big no-no to me.  There are some people who can make it work (see Daniel Hellerman’s “Taking A Good Portrait In HDR” article at http://photographyminded.com).  I will happily admit that I cannot pull it off.  And neither can the aforementioned Daniel.

Just because you can, it does not mean that you should (or something like that)…


I hate Microsoft and their stupid .NET framework so much!

I usually try to not to utter statements such as “I hate Microsoft and their stupid .NET framework so much!” for two reasons:

  1. Generalizations like this are silly and ignorant
  2. My mailbox overflows with angry emails from people who think differently

Today, however, I was getting ready to throw my computer against the wall and jump up and down on its remains.  For the last week I’ve been working on implementing a series of new features into a web application that my lab is currently developing/improving.  Most of these features address various usability issues. 
The feature that was driving me up the wall today (and yesterday and the day before) was an accordion menu control.  Such control allows users to expand and collapse sections of a menu, saves screen real estate and has cool fade in/out effect. 
Initially, I spent a few days writing my own version of this control when a friend of mine suggested that I should use an accordion control from the ASP.NET AJAX Toolkit (http://www.asp.net/ajax/AjaxControlToolkit/Samples/).  I downloaded and installed the toolkit, set up CSS, and was really excited about how easy everything was until I opened the website in FireFox.

 

Internet Explorer Screenshot - .NET AJAX Accordion Control

Internet Explorer 7 Screenshot

Mozilla Firefox Screenshot - .NET AJAX Accordion Control

Mozilla Firefox 3 Screenshot

For some reason, in Firefox the control displayed spaces between the panels and headers were aligned to the top instead of the middle.  I spent hours messing with CSS but could not get consistent results throughout Internet Explorer, FireFox, Safari and Google Chrome.

Finally, I gave up and rewrote everything using a jQueryUI accordion control – it took me about an hour and worked correctly in all browsers right away.

Many people would say that having a problem with one control is no reason to lash out against Microsoft.  Alas, this is not the first time when I experienced similar issues.  Microsoft designed its .NET controls as “black boxes” – as a developer you have little to no control as to what goes on inside and how it renders in a browser.  I am forced to use ASP.NET as my development environment ;  if it were up to me, I’d rather use PHP or Ruby.  Even with ASP.NET I try to stay away from using non-HTML controls such as DataGrid or CheckBoxList.  Even though in the end they render HTML to the browser, the results are almost always unpredictable and require hours of tinkering with CSS to get some sort of consistency.

Designing and developing RIA for different browsers is difficult enough as it is – Microsoft is not winning any popularity contests by being inconsiderate.


Spring
2009 Conference

Yesterday myself and four of my co-workers met in front of my house at 5AM (that’s five in the morning) and drove to Athens, OH for a web developers’ conference creatively titled “Spring <br /> 2009” (2009.sbconference.com)

Spring break 2009 Web developers conference Athens OH

 

 

Spring break 2009 Web developers conference Athens OH

The conference was well worth the visit – I ended up attending two lectures and a hands-on workshop. 

The first lecture covered the topic of non-linear usability for the web and was presented by Brian Stone, a design professor from Ohio State University.  He showed us some very neat things that were developed by him and his students and I got a couple of interesting ideas for my own projects just from looking at Dr. Stone’s software.  However, I would have found the presentation more useful if Dr. Stone actually spent some time going either doing a high-level overview of the code or of some of the trickier algorithms.

The second lecture was really excellent.  The presenter, Kevin Hoyt, spoke about 10 most common mistakes that developers and designers make when creating RIAs (Rich Internet Applications).  As an RIA developer, I realized that at least two of the issues that were discussed in the presentation (data synchronization with the server and implicit/virtual pagination) almost always make appearances in my own software.
During the break, we hang around the Ohio University campus (which by the way is really beautiful).  We came across a rather interesting flier on the message board – I could not resist taking a photograph.  Make sure you read the line in the top left corner:).

Weird flier on a messageboard University of Ohio Baker Hall

 

Photograph of me goofing off

 

The final workshop of the day covered jQuery (http://jquery.com/) and jQueryUI (http://jqueryui.com/).  jQuery has become increasingly popular and for quite some time I’ve been meaning to learn it.  The workshop was excellent – it was taught by Richard Worth, who is actually a part of the team that develops jQueryUI.  I never realized that so many things that I have spent weeks, if not months developing for my own application have already been implemented as part of jQueryUI.  I even implemented one of the controls in one of my current projects the very moment I came in to work today!

The drive from Pittsburgh to Athens deserves a few words as well.  We passed through a multitude of tiny towns, some picturesque, but most half-abandoned.  Driving through rural America’s Main streets and looking at closed businesses, pothole-ridden streets and boarded-up windows makes me incredibly sad.  While I understand that the time of small-town America is over, I still wander if anybody actually cares about what happens to people from coal and farming towns as we move towards a completely globalized economy.

 


Choosing Your Wedding Photographer

As a professional wedding/event photographer I meet with quite a few brides. While many of my potential clients come armed with a list of questions, some seem to be at a loss as to what they should look for in a wedding photographer. Last night I found an article written by Grant Perry, a wedding photographer from Virginia Beach that every bride should read.

Choosing Your Wedding Photographer by Grant Perry


Usefulness of Mathematics

Up until a few months ago I hated math.  All throughout my school and college years I took the path of least resistance when it came to math courses.  I more or less skipped algebra, slept through geometry and struggled with calculus, firmly believing that math was a totally useless subject and that anything I might learn would never apply to real life.


Surprisingly, I was almost right.  For 11 years I worked as a software developer and web designer, and I never had to use anything more complicated than 2 + 2. 
A few months ago my lab began developing an interactive application for medical education (I cannot go into too many details about the actual software).  A large part of the application consists of a web-based Visio-like Flash UI designed for drawing diagrams.  As we were testing this software for a potential demo/beta release, we found a small but annoying issue.  When a user draws more than one connecting line between nodes, the software automatically offsets the lines so that they do not overlap.  However, if a user drags Node 2 so that it is at a 45-degree angle in relation to Node 1, all the lines will overlap.

Node map calculating angle between two nodes

When I began going through the code to solve this issue, I realized that that was happening because I was offsetting coordinates on both x- and y-axis by the same amount.  However, if I were to offset only on the x-axis, this problem will reoccur when both nodes have the same x-coordinate.  If I were to offset only on the y-axis, the problem will creep up when one node is directly below the other.
The only way to solve this problem was to vary the offset based on the position of the two nodes relative to each other.  That’s where math suddenly became very important.  After sitting down with a pen and a notepad and forcing my brain to remember 7th-grade geometry, I came up with two possible solutions.

  1. Calculate the slope of the connecting line and adjust the offset based on the slope
  2. Calculate the angle of the connecting line by drawing an imaginary right-angle triangle and adjust the offset based on that angle.

Solution one was discarded pretty quickly.  On a normal coordinate plane coordinates start at the bottom left corner, but in Flash, point (0, 0) is at the top left corner of the stage.  So, I decided to go with the imaginary triangle/angle idea.
A quick Google search gave me the necessary formulas:

The rest was easy (the notation is not quite right): 

 

Calculations for angle between two nodes - notepad scan

To clarify:


If you have a right angle triangle ABC where the connecting line between two nodes is the hypotenuse, ABC is the right angle (i.e. ABC = 90 degrees) and you need to calculate the BAC angle, the following steps should take care of your calculations:

  1. Line AB (adjacent side) = |y1  - y2| (absolute value of the change in the y-coordinate)
  2. Line BC (opposite side) = |x1 – x2| (absolute value of the change in the x-coordinate)
  3. AC (hypotenuse) = SQRT(AB2 + BC2) (Pythagorean theorem – AC = Square root of AB-squared plus BC squared)
  4. sin(BAC) = BC/AC
  5. Angle BAC = sin-1(BC/AC) – result is in Radians
  6. Angle BAC = BAC * 180 / PI

This is what the code looks like in ActionScript:

 

public static function calculateAngle(x1:int, y1:int, x2:int, y2:int):Number{
            var opp:Number = Math.abs(y2 - y1);
            var adj:Number = Math.abs(x2 - x1);
            var hyp:Number = Math.sqrt(Math.pow(opp, 2) + Math.pow(adj, 2));
            var angle:Number;
            /* calculate angle
                1. SIN(A) = opposite side / hypothenuse
                2. SIN-1(A) - returns result in radians
                3. angle in radians * 180 / Pi - returns result in degrees
            */

            angle = opp / hyp;
            angle = Math.asin(angle);
            angle = angle * 180 / Math.PI
            return angle;
}

 


Russian Prison Slang

For the last six or seven years I have been working on two projects in parallel – researching my grandfather’s life and compiling an extensive dictionary of Russian prison/criminal slang.  The two projects are actually related.  My grandfather spent 11 years in Soviet GULAG as a political prisoner.  But that’s a whole separate story.  When I began researching his life, I came across a number of prisoner testimonials and biographies that included some rather colorful slang.
One of my obsessions in life is languages and linguistics.  Many of the documents that I encountered contained words and expressions that I did not know and could not find much information on their meanings and etymologies.  So, being the geek that I am, I built a quick and dirty database application and began collecting Russian prison slang.

Unfortunately, at the time when I began this project, my idea of quick and dirty software development involved using Microsoft Access as my database.  Since switching to Mac three years ago, many of my projects kind of fell off my radar because I hate booting into Windows just to add an entry to a database.

For the past few years I’ve been keeping my dictionary in a Word document, but recently I began rewriting the dictionary application in PHP and MySQL and will be publishing it in the next few months.

The reason I actually started this blog entry is because while researching a “new” word, I came across and interesting fact that I have never heard before.

Apparently, a large portion of criminal/prison slang came into Russian language from Hebrew and Yiddish.  As it turns out, in certain places of Russian Empire where Jewish populations were extremely concentrated because of the Pale of Settlement Jewish criminal organization spoke exclusively in either Yiddish or Hebrew to prevent the police from understanding what was being said.  Since Russian Jews were prohibited from serving in the police, so it was a great way of keeping secrets.  As some of these Jewish criminals were arrested and sent to prisons or into exile, non-Jewish criminals saw the advantages of adapting their slang.  With time, Jewish criminal jargon became a part of mainstream Russian prison slang.

Pretty damn cool!


Migrating my blog

Today was an incredibly productive day - I finally moved this blog onto it`s own website.  For the past year, this blog has resided under the umbrella of my photography site (www.wideopenlens.com) and evillens.com simply redirected to a subsite of wideopenlens.  Another problem with that setup was that my website was not being picked up by search engines.

Finally, I broke down and bought another hosting package from GoDaddy.com and migrated my blog.  Part of the migration involved rewriting the original blog in PHP since I`ve been trying to move away from .NET for a while.  I am still having a few issues that need to be resolved - when the content was moved from Microsoft SQL Server to MySQL, some data got corrupted.  Unfortunately, those things would have to be fixed manually, so over the next few days I`ll be going through my old entries by hand and fixing weird characters and vanished line breaks.  I`ll also be adding two new sections that deal with a few projects that I have been obsessing about over the last few years.

I will also be improving blog search functionality by adding a "category" filter and search term highlighting.


My Timbuk2 Bag

For someone who`s job involves a lot of travel or carrying a lot of gear, finding the right bag is extremely important.  My wife had always made fun of me for having a closet full of camera and messenger bags.  Luckily, I`m not the only one in the world who is obsessed with finding that holy grail of a perfect bag.  Just look at all the articles that Lifehacker has published on what`s in their geeks` bags (http://lifehacker.com/5265235/lifehacker-laptop-bags-gina-trapani-edition).

I`ve had a Timbuk2 custom medium size messenger bag for about 3 years and firmly believe that it is the best thing since the invention of penicillin.  That`s why when I found out about Timbuk2 20th anniversary "Bag Biographies Contest" I felt obligated to put in my two cents.

Here it goes...

I play many roles in my life – a professional photographer, a graphics designer, a web developer, an avid hiker, and, as of 3 weeks ago, a father.  My Timbuk2 bag has managed to fit every role of my life.

I bought my Timbuk2 custom medium messenger bag about 3 years ago, and we’ve been inseparable ever since.  My Timbuk2 bag has acted as my camera bag, laptop bag, and even as a diaper bag. 

My Timbuk2 bag also managed to save my butt on two separate occasions.  About a year and a half ago, I was photographing an engagement session in downtown Pittsburgh.  At the time, my bag contained a MacBook Pro laptop, a Canon 5D digital SLR, two lenses and a flash.  I finished the gig pretty late because the coupe wanted some photographs with the city lights in the background.  As I was walking to the parking garage where I left my car, a large man brandishing a knife blocked my path and demanded my wallet and my valuables.  I handed over my wallet and my watch, but because I looked like a student with my Timbuk2 messenger bag, he did not even bother to check what was actually inside my bag.  Had I carried my gear in a LowePro or a Tamrac bag, I would have lost about $7000.00 worth of equipment.

The second time my Timbuk2 saved me earlier this year.  I was hiking at the McConnell’s Mills about 40 minutes from Pittsburgh when I slipped on some frozen mud.  I started rolling down a steep hill, and if my messenger bag strap had not caught a tree root, I would have ended up in a frozen river.  Even though I am a pretty strong swimmer and most likely would have been able to get out of the water, hiking back to my car wet when the temperature outside was -5F would have surely landed me in the hospital with hypothermia.

Thank you Timbuk2 for making such a wonderful product.


My daughter takes after me:)


I just could not resist


I am a dad now

I haven`t posted in a while, but I have a good excuse.  The "photography" season has began once again, and I`ve been swamped with weddings, barmitzvahs and commercial photoshoots. 

However, most importantly, on May 3rd, 2009 my wife and I had a beautiful baby girl.  We named her Daniella.  I absolutely love being a dad.  It`s the greatest thing in the world.  Daniella is 3 weeks old now, and she changes and grows every day.  I try to document every tiny change, so I think at this point she is beginning to believe that her dad has a camera attached to his face.




Flash/Actionscript Bug

Yesterday I wrote about a bug I discovered in Flash/Actionscript 3 (see my previous post below).  I posted questions on five different forums and logged a bug on Adobe`s website.  For a few hours, this problem had everyone baffled.  Finally, somebody realized that the Number variable in ActionScript can only hold 32bits, and the numbers I was pulling from a database were longer than that.  However, I still believe that Adobe needs to address this problem.  In other programming languages (and I tested this with ASP.NET and Java), when you assign a too-large value to a numeric variable (value that is larger than that variable`s data type can handle), the compiler or the run-time environment return an overflow error.  Flash, on the other hand, simply changes the value of the variable without letting the developer or the user know that an error had occured.

Because of this idyosynchrocy, I spent about 6 hours going through thousands of lines of ASP.NET, T-SQL, XML, and ActionScript 3 code trying to figure out what was breaking my application.  Not to mention that I spent another 4 hours yesterday rewriting the ActionScript code so that all IDs (the long numbers are actually object IDs) were handled as String instead of Number in Flash and then converted to Long data type in ASP.NET.


WTF!!!

This past Saturday I photographed a bar mitzvah at the Ohav Sholom synagogue in Allison Park.  There is a little scenic garden with a Holocaust memorial behind the synagogue.  I took the bar mitzvah boy`s family into the garden for some formal family photographs when we noticed a large black swastika spray-painted on one of the synagogue`s walls.

The family was pretty upset, and I was really shaken and angry as well.  It seems that people will never learn from the horrible mistakes or the past and there will always be some miserable assholes out there who are looking to channel their hate and blame someone else for their perceived misfortunes.

I emailed this image to a friend who works in a major newspaper and he promised to pass it on to his editor.  I know that there are some much more "newsworthy" things out there (like what trouble Britney Spears or Lindsey Lohan would get into next, the world is holding its collective breath), but hopefully at least a few people will read about this.  Stuff like this should not be ignored - even if this was a stupid prank pulled by a stoned teenager on a dare from his idiot friends, whoever did this should be punished, and punished severely at that.


Error converting string to number in ActionScript 3 (Flash CS3 & CS4)

Yesterday one of our testers noticed some weird behavior from an application that I`ve been working on for the past 6 months.  This application is written in ActionScript 3 and interfaces with a MSSQL database via XML and JavaScript.  After spending 6 hours debugging the application, I finally figured out what was breaking it.  Object IDs retrieved from the database were stored as strings in an XML files.  When Flash would read those IDs from XML, it would convert them to numbers, but do so incorrectly.

For example:

Original string: 90330135147081210
Number("90330135147081210") returns 90330135147081220

Original string: 90330135320035930
Number("90330135320035930") returns 90330135320035940

I cannot figure out why it does it. I posted on four different forums and even logged a bug on Adobe`s website (bugs.adobe.com).

 

If you have any idea or ever ran accross a similar problem, please email me at dbabichenko (at) yahoo.com.  I am at my wit`s end and would appreciate any help.


Page 1
next »