Fixed non-centering issue.
More flexible layer definition.