Page 11 of 22 FirstFirst ... 78910111213141521 ... LastLast
Results 101 to 110 of 217

Thread: TreeThing

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default

    Really gracious of you, Ramah, to share so many of your tools and techniques.
    I can only save the resulting forest as a single flat .png and not "all layers" like the pdf manual says. Ideas?
    I'm on a Mac.

  2. #2
    Guild Expert Ramah's Avatar
    Join Date
    Mar 2009
    Location
    Nottinghamshire
    Posts
    1,414
    Blog Entries
    4

    Default

    Hmm, off the top of my head I cannot think of a reason why it shouldn't be working for you. I'm on a PC but as far as I am aware the JVM should translate it faithfully. I might be wrong but I thought that as long as I stay away from referencing specific windows commands or keys then it should be ok cross-platform. Can anyone else verify this?

    Unfortunately I don't tend to get a lot of feedback here. It's been downloaded 22 times so far and only a few people have commented so I am never sure what problems, if any, people are having. I'll take a look into it and see if I can find a problem with the saving, although why it would save the image and not the layers I don't know. :S

    Anyone else had this problem? If so are you on a mac?

    Just out of interest though, on the mac does the program appear graphically similar to how it was in the last screenshot that I posted? I have often wondered if the LookAndFeel would translate correctly across platforms.
    Royal: I'm very sorry for your loss, your mother was a terribly attractive woman.


    My Cartographer's Guild maps: Finished Maps


    More maps viewable at my DeviantArt page: Ramah-Palmer DeviantArt

  3. #3

  4. #4
    Guild Expert Ramah's Avatar
    Join Date
    Mar 2009
    Location
    Nottinghamshire
    Posts
    1,414
    Blog Entries
    4

    Default

    Hmm... well that doesn't sound good if you don't know that eaither, Ravs.

    The "Save Image" command just saves out exactly what it sees in the viewport, minus the green background. So if shades, shadows etc. are all turned on then it spits it out as one image. Limited use really.
    The "Save All Layers" command spits out up to four images, one each for: _brushes.png, _shades.png, _shadows.png and _masks.png. This way they are kept separate and can be manipulated individually in PS or whatever. Are you not getting them either, Ravs?
    Last edited by Ramah; 11-18-2011 at 06:46 AM.
    Royal: I'm very sorry for your loss, your mother was a terribly attractive woman.


    My Cartographer's Guild maps: Finished Maps


    More maps viewable at my DeviantArt page: Ramah-Palmer DeviantArt

  5. #5

    Default

    Quote Originally Posted by Ramah View Post
    Hmm... well that doesn't sound good if you don't know that eaither, Ravs.

    The "Save Image" command just saves out exactly what it sees in the viewport, minus the green background. So if shades, shadows etc. are all turned on then it spits it out as one image. Limited use really.
    The "Save All Layers" command spits out up to four images, one each for: _brushes.png, _shades.png, _shadows.png and _masks.png. This way they are kept separate and can be manipulated individually in PS or whatever. Are you not getting them either, Ravs?
    Ah thanks for telling what we should expect.
    It doesn't do that.
    It pulls up a Save dialog asking for a filename,
    and then spits out this Java error:

    Code:
    Exception in thread "AWT-EventQueue-0" java.lang.StringIndexOutOfBoundsException: String index out of range: -1
    	at java.lang.String.substring(String.java:1768)
    	at mapmaking.Main.saveAll(Main.java:5173)
    	at mapmaking.Main.saveAll(Main.java:5165)
    	at mapmaking.Main$11.actionPerformed(Main.java:1433)
    	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1882)
    	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2202)
    	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
    	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
    	at javax.swing.AbstractButton.doClick(AbstractButton.java:334)
    	at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1050)
    	at apple.laf.CUIAquaMenuItem.doClick(CUIAquaMenuItem.java:119)
    	at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:1091)
    	at java.awt.Component.processMouseEvent(Component.java:5617)
    	at javax.swing.JComponent.processMouseEvent(JComponent.java:3129)
    	at java.awt.Component.processEvent(Component.java:5382)
    	at java.awt.Container.processEvent(Container.java:2010)
    	at java.awt.Component.dispatchEventImpl(Component.java:4083)
    	at java.awt.Container.dispatchEventImpl(Container.java:2068)
    	at java.awt.Component.dispatchEvent(Component.java:3918)
    	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4256)
    	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3936)
    	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3866)
    	at java.awt.Container.dispatchEventImpl(Container.java:2054)
    	at java.awt.Window.dispatchEventImpl(Window.java:1801)
    	at java.awt.Component.dispatchEvent(Component.java:3918)
    	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:501)
    	at java.awt.EventQueue.access$000(EventQueue.java:80)
    	at java.awt.EventQueue$1.run(EventQueue.java:462)
    	at java.awt.EventQueue$1.run(EventQueue.java:461)
    	at java.security.AccessController.doPrivileged(Native Method)
    	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:84)
    	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:95)
    	at java.awt.EventQueue$2.run(EventQueue.java:476)
    	at java.awt.EventQueue$2.run(EventQueue.java:475)
    	at java.security.AccessController.doPrivileged(Native Method)
    	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:84)
    	at java.awt.EventQueue.dispatchEvent(EventQueue.java:473)
    	at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
    	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
    	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
    	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
    	at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

  6. #6

    Default

    lol, I just tried it and it worked! I never appreciated that TT could do this! Fantastic! It makes editing in Drawplus even easier!

    You are just a genius, Ramah!

  7. #7
    Guild Expert Ramah's Avatar
    Join Date
    Mar 2009
    Location
    Nottinghamshire
    Posts
    1,414
    Blog Entries
    4

    Default

    Thanks for that Paul, that was very helpful to me. I did some digging and found that the Mac version of Java is bugged in certain ways, one of which is the way it responds to ShowSaveDialog, returning an incorrect path which in turn is giving me the substring error. I'll have a play around and try and get a fixed version up soon. It may be that the program will lose the ability to create a new folder for saved files as this is the easiest fix.

    Ravs: Heh. The ability to separate the layers was the reason why I took up the programming of this in the first place and has been there since the very first version that I implemented. I'm impressed that you got such good results in your last map with just the single layer and also realise now that you probably had no idea what I was talking about when I said you should have used the mask layer to underpaint your trees to stop coasts and rivers showing through.
    Royal: I'm very sorry for your loss, your mother was a terribly attractive woman.


    My Cartographer's Guild maps: Finished Maps


    More maps viewable at my DeviantArt page: Ramah-Palmer DeviantArt

  8. #8

    Default

    Awesome. Glad to help.
    Perhaps the user could select the destination folder for the layer images? This would mean the user would have to make the folder first (which is fine) and then that takes it out of the the program's "hands" entirely.

    There's always: JFileChooser (Swing)

    Thanks for continuing to work on the program.
    Last edited by paulbhartzog; 11-19-2011 at 12:21 PM.

  9. #9
    Guild Expert Ramah's Avatar
    Join Date
    Mar 2009
    Location
    Nottinghamshire
    Posts
    1,414
    Blog Entries
    4

    Default

    Quote Originally Posted by paulbhartzog View Post
    Awesome. Glad to help.
    Perhaps the user could select the destination folder for the layer images? This would mean the user would have to make the folder first (which is fine) and then that takes it out of the the program's "hands" entirely.

    There's always: JFileChooser (Swing)
    The user can already select the destination folder and can also create a new folder for said images if they want.
    It also already uses a JFileChooser and it is the dialog box for this that apparently casuses the problem on mac OS.

    Anyway, I've changed the program to what I hope will now work correctly on a mac. Having no way to test this myself all I can rely on is troubleshooting forums on the web for answers so if you could let me know if it works now Paul then that would be cool.

    I'll upload this new version here and if it works then I'll update the original post.

    This is version 0.96.

    I've disabled most of my WIP elements on it. I've enabled the faux perspective option this time although it still isn't integrated properly and is of limited use right now.

    I guess the only main additions to this version are:

    1) the ability to load a background jpg image (depending on size this may take a short while to load and it can also have a negative effect on how large a forest can be created)

    2) the ability to remove trees from a generated forest. This is still in its early stages and I plan to do a lot more with this but for now you can press Alt to bring up the tree origins and then click on an origin to toggle it. Then once you have selected all that you want to press Refresh at the top and it should remove/replace all toggled trees.

    EDIT: Removed bugged version. Fixed version a few posts below.
    Last edited by Ramah; 11-21-2011 at 06:09 AM.
    Royal: I'm very sorry for your loss, your mother was a terribly attractive woman.


    My Cartographer's Guild maps: Finished Maps


    More maps viewable at my DeviantArt page: Ramah-Palmer DeviantArt

  10. #10
    Community Leader jfrazierjr's Avatar
    Join Date
    Oct 2007
    Location
    Apex, NC USA
    Posts
    3,057

    Default

    Ramah, if you want to share that section of the java code, I could eyeball it to see if I see any obvious issues...here or offline, either way is fine if your up for it.
    My Finished Maps
    Works in Progress(or abandoned tests)
    My Tutorials:
    Explanation of Layer Masks in GIMP
    How to create ISO Mountains in GIMP/PS using the Smudge tool
    ----------------------------------------------------------
    Unless otherwise stated by me in the post, all work is licensed under a Creative Commons Attribution-Noncommercial 3.0 United States License.

Page 11 of 22 FirstFirst ... 78910111213141521 ... LastLast

Posting Permissions

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