Welcome to TalkGraphics.com
Results 1 to 10 of 16

Hybrid View

  1. #1

    Default Re: Cropping an image to a layer.

    Quote Originally Posted by pauland View Post
    ...Imagine I have
    1. a PSD with a document size of 500x500 pixels.
    2. It has one layer, upon which sits a green square 50 pixels on each size and sitting at (250, 300).
    3. What I want from this document is a PNG, a 50 pixel green square.

    I know this is simplistic -it's just an example.
    Yeah, the problem with "simplistic" is that (almost) any example I can think of won't likely fit what it is you are really needing.

    Screen shot should be self-explanatory. But, just in case, all I did (other than try to recreate your example) was to use the magic wand, inverse the selection, copy to the clipboard and then hit ctrl+n to create a new document. Depending upon the preferences setting, you can see in the screen shot the new document is being made at the clipboard content size, which is your 50 px X 50 px. Then paste it into the new document.

    See? A too simple answer for a simplistic question!
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	Untitled-2.jpg 
Views:	538 
Size:	108.8 KB 
ID:	99304  
    IP

  2. #2
    Join Date
    Sep 2000
    Location
    Bracknell, UK
    Posts
    8,659

    Default Re: Cropping an image to a layer.

    OK, Mike and Gary, thanks for your patience with me and this dumb question.

    The thing that particularly caused me to stumble was that when selecting a layer, the content is shown as selected by photoshop, but the actual size of the selection was not, so I was left wondering how big that selection was. My Doh! moment in particular was not using the selection tool specifically to select what was there and then have the actual size revealed.

    It seems counter-intuitive to me that selecting a layer never reveals the size of the content on the layer ( unless I'm missing another trick ).

    I did discover ( on my photoshop journey ), that selecting a layer, then duplicating it allows the layer to be duplicated into a completely new document or another open document, as-is so that's a great feature.

    Generally as a new user I find photoshop quite clunky, but that's because I only use it for fairly simple things as part of a pipeline, rather than as an asset/art creator in it's own right.

    Thanks Guys. Job done.
    IP

  3. #3
    Join Date
    Sep 2000
    Location
    Bracknell, UK
    Posts
    8,659

    Default Re: Cropping an image to a layer.

    Whilst we're on this subject - here's my real example - a UI element.

    How can I tell it's exact XY position? Photoshop tells me how big the selection is, but not the position. That seems bizarre to me.

    I can move the cursor to the corner of the selection - the cursor XY is always shown.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	Screen Shot 2013-11-01 at 12.36.49.png 
Views:	544 
Size:	26.8 KB 
ID:	99307  
    IP

  4. #4

    Default Re: Cropping an image to a layer.

    You can show the rulers, making sure it is displaying in pixels (right-click on the ruler for the units). You can then make sure the 0,0 is in the upper left (double-click where they join).

    You can always check a layer's dims by right-clicking on the image's title bar or tab, choose the appropriate action in the context menu. The X/Y will show only the current position. So if you want to display say something's X/Y at the top left, drag rulers into place.

    Personally, I have never understood using PS for UI development. But it is heavily used, that's for certain. I cannot remember if Fireworks shows X/Y positions, but I used it for UIs back in the early 2000s. Before that couple year stint, I used CorelDraw for UI development, as well as afterwards. If you are subscribed, FW CS6 might be downloadable. I would check it out if so.

    Mike
    IP

  5. #5
    Join Date
    Sep 2000
    Location
    Bracknell, UK
    Posts
    8,659

    Default Re: Cropping an image to a layer.

    Thanks Mike.

    My clients supply me their designs in PSD or AI format generally. It would be nice to know precisely, without any eyeballing, where a particular element has been positioned.

    I think the easiest way I have found is to do an extreme zoom in to a corner and position the mouse. At high zoom I can get the position reliably. It seems a kludge though.
    IP

  6. #6

    Default Re: Cropping an image to a layer.

    Fireworks ought to open and write those PSD files just fine. From (a faulty) memory, I think the FW interface shows the coordinates.

    So are these sprites where the coordinates are important?
    IP

  7. #7
    Join Date
    Sep 2000
    Location
    Bracknell, UK
    Posts
    8,659

    Default Re: Cropping an image to a layer.

    So are these sprites where the coordinates are important?

    Most clients aren't too picky. Occasionally a client gets huffy if a PSD design isn't reproduced pixel-perfect.

    In this case, you are only seeing the background of a panel, not anything else - there's a ton of other stuff that sits over that. This is a Flash project and unlike the static PSD, these panels are sometimes hidden then revealed, so it's often better to handle them as separate entities in Flash, so I want to position that panel in the same place as on the PSD and of the same size.

    It sounds trivial, and mostly it is, but sometimes it's not!

    In this case the flash panel sits over HTML elements that are also visible through flash and as a result this panel needs to sit as closely over the panel it obscures in the underlying HTML.

    It will never be perfect on all browsers or any browser at all times. It wasn't my idea..
    IP

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •