Howdy, Stranger!

We are about to switch to a new forum software. Until then we have removed the registration on this forum.

  • How to save a PDF on key press from a 3D scene in this example?

    Thank you for guiding me through this, so helpful.

    How did you extend the scene and found 'public class PGraphicsPDF extends PGraphicsJava2D'? I tried to open the PDF in Sublime Text and in the Chrome browser but didn’t find this line of code. I see the extra triangles on a saved .svg though.

    And how did you figure out that those 2 lines (nofill and rows) should be changed to fix it?

  • Making HYPE library work

    If you want to get it working for the PDE, follow this instructions: https://github.com/processing/processing/wiki/How-to-Install-a-Contributed-Library

    I will do this before I get it going in sublime. Notice doing this might not be sufficient to get it going in Sublime so you will need to look into sublime docs.

    Kf

  • Making HYPE library work

    Hi, I'm trying to install HYPE library. I:

    1) Downloaded zip from https://github.com/hype/HYPE_Processing/tree/lib_staging and unzipped it

    2) Created libraries subfolder in my processing-3.3.7 folder and moved unzipped hype folder into it

    3) Restarted Sublime and tried to run build.xml in the Resources folder (does "run" mean just opening this file?)

    When I try to launch any of HYPE example classes, I'm getting No library found for hype error.

    How do I make HYPE work? Processing 3.3.7, Sublime 3, Ubuntu 16.04.4 LTS.

  • some (hopefully basic) questions

    hi! i'm new to p5 and coding in general and i'm having some trouble completing a project because i still lack the knowledge to fill in the gaps. what i want to do seems kind of simple but i don't really know if it is, i've tried looking for tutorials/examples but they either don't work in the online p5 processor (i have sublime, too, but it's not running a lot of the files i'm trying to work on for some reason?) or i don't know exactly how to look it up.

    ok, so.

    1) i have some text that follows the mouse around on the canvas, but i'd like it to leave a trail (preferably a fixed one but doesn't matter if it fades tbh, just whatever is simplest to do). i figured the code would be something along the lines of "if mouseX and mouseY increase, the quantity of the text increases". i tried it by doing the following:

    if (mouseX++,mouseY++){i++}
    for(i=1;i<10;i++)
      textFont("courier new")
    text("text",mouseX,mouseY)
    

    but the mouseX and mouseY variables start moving on their own rather than increase the number of lines when i move the cursor. (i kinda realize some mistakes here but it's the best i could come up with. i only started w js like a week ago so pls be patient w me)

    2) how can i make an object rotate on its axis as an animtion rather than a fixed transform of its position?

    and finally (and probably the most complicated. or maybe not and im just really inexperienced lol)

    3) the project i'm working on is a sort of interactive story. i've made a bunch of separate files with different code each. is there a way to link them, whether it is to put them all on the same file or through the use of html? i have a little experience with hypertext narratives so thats sorta what i'm going for, but it could be just pushing the spacebar or something to get to the next part if turning an actual object into a link is too difficult.

    i'm super confused about everything and i'd really really really appreciate some help even if it's with just one of these things. thanks a lot in advance!!

  • Monokai theme for the PDE

    I have always loved Sublime Text's Monokai theme, as it was easy on your eyes and it looked nice, so I decided to re-create it for the PDE.

    Here's a screenshot:

    Monokai for PDE

    There's a few issues with the theme that I can't fix at the moment:

    • The original theme had more syntax highlighting for tokens like = or numbers, but the PDE syntax highlighter doesn't support these
    • The PDE can't display italic text, so I used bold text

    But despite that, I still tried to make it look as faithful to the original as possible.

    Here's the GitHub repo: processing-monokai-theme

    Update 2018-04-16: Fixed the selection color to be gray (original) instead of orange. This was a thing that I overlooked, fixed locally, but forgot to add it to the repo! Hopefully the orange didn't cause too much eye strain for you.

  • How to get real time syntax error updates for p5.js in sublime text 3

    Look for suitable plugins.

    For JS, eslint is probably a better choice than jshint these days. I doubt you'll find anything p5 specific. In theory TypeScript can give you compile-time errors on your code (if you can find and use up-to-date p5 typings); but I wouldn't bother with the frustration that will most likely cause: just set up something like live-reload and you get run-time errors in pretty much real-time...

  • How to get real time syntax error updates for p5.js in sublime text 3

    Hi,I'm new to programming. I want to do what the title says...Also for HTML and CSS, but I don't know how... You guys seem nice so i thought i'd ask here :) plz help!

  • Beginner Array Question

    Sorry, I was using Sublime as my text editor and it was not building properly. Yes it works. Thanks very much for those tips, Chrisir (and koogs) . Much obliged :)

  • How to create a map using a String[] as input?

    You got an error? Great! Then you know what's wrong with it.


    Oh, it would be sublime,

    If you took the time,

    To read this silly rhyme,

    And then to store a mine,

    As the number nine!

    That would be just fine!

  • Processing and Sublime: installing processing-java

    but it says file exists

    If file exist in the destination folder, then I am guessing there is no need to create the symbolic link. You can confirm the file is there by typing ls /usr/local/bin/processing-java

    You can check if this cmd runs properly by using it directly on a sample sketch, invoking this command manually in your console. If you want to test this, follow the instructions below: Test processing-java command manually.

    What instructions are you following to install sublime beside the atom link? I found this one from https://forum.processing.org/two/discussion/23905/building-processing-sketches-in-sublime-3-in-arch-linux/p1. You can search prev posts and see if if you find relevant posts: https://forum.processing.org/two/search?Search=sublime

    Kf


    Test processing-java command manually

    The next to work, you need to have your path to the processing-java executable in your PATH (ask below if you don't know about this). Go to a folder that contains a pde folder which it contains your pde file. For instance:

    cd /home/kf/Processing/mySketches

    If you run processing-java by itself, it provides instructions how to run the command. Next, I assume you have a demo.pde in a folder demo in the current directory. Then you can test processing-java runs by typing:

    processing-java --force --sketch=/home/kf/Processing/mySketches/demo --output=/home/kf/Processing/mySketches/demo/tmp --run

    This is exactly describe in the instructions above when executing processing-java by itself. This should compile and run your sketch. I don't have a linux machine to test this atm, but you might need to add sudo to the above command if you are having permission issues.

  • Processing and Sublime: installing processing-java

    Hi, I'm trying to install processing-java to start using Processing in Sublime. (Processing 3.3.6, Sublime 3 unregistered, Ubuntu 16.04.3 LTS). The tutorial that I use says: after installing Package Control and Processing package (which I did) open Processing and do Tools > Install "processing-java". However, under Tools I don’t have this option. I found Atom instruction saying to add PATH https://atom.io/packages/processing and tried it, but it says file exists:

    xxx:~/Develop/Java/skillshare1$ sudo ln -s /Home/Scripts/processing-3.3.6/processing-java /usr/local/bin/ ln: failed to create symbolic link '/usr/local/bin/processing-java': File exists

    Message in Sublime console when I try to run my sketch:

    [Errno 2] No such file or directory: 'processing-java' [cmd: ['processing-java', '--force', '--sketch=/home/tge/Develop/Java', '--output=/home/tge/Develop/Java/build-tmp', '--present']] [dir: /home/tge/Develop/Java] [path: /home/tge/bin:/home/tge/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin] [Finished]

    What am I doing wrong and how to fix this to be able to launch Processing programs from Sublime?

    Sorry if this is a wrong thread to post this question, I was not sure where to publish it.

    Thank you!

  • Using Windows : Uncaught TypeError / ReferenceError. But works great on Unix

    I'm trying to (in a very rudimentary way) port a project from Unix to Windows and receiving errors. (Both using the same ide, Sublime) The app runs fine on my Unix environment but not Windows with the same code.

    :(( TypeError "cannot read property 'prototype' of undefined"
    at setup (sketch.js:8) at p5. (p5.js:44882) at p5. (p5.js:44810) at new p5 (p5.js:45103) at _globalInit (p5.js:46862)

    :(( ReferenceError "createSlider is not defined" at p5.dom.js:71 at p5.dom.js:34 at p5.dom.js:35

    I'm using the exact code from Shiffman's YouTube walkthrough: Coding Challenge #14: Fractal Trees - Recursive.
    Is there a caveat to working on Windows ?

    Updates :
    I tried using my XAMPP server too. It still doesn't work.
    I might have to try the WAMP server.
    Also, I uploaded the page to my BlueHost site to no avail. I received the exact same errors. I've used both CDN and downloaded files for p5.dom.js and p5.js

  • How can one access the combined .java file created by the IDE from multiple .pde's in a sketch

    I've tweaked the Terminal command line above to automagically start up the Sublime Text 3 editor on the Java file so that I can proceed directly to the line causing a Null Pointer exception (or whatever misfortune leads you to need to see the concatenated .java file! :) ). The command line is:

    sudo find /private/var/folders -name '*.java' -print0 | xargs -0 ls -1t | head -1 | xargs /Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl

    This code:

    1. Executes the find command to locate the concatenated .java file.

    2. Uses the print0 option on the find command to put it a format for xargs.

    3. Xargs then feeds it into the ls command to output the possible .java files as a series of file paths and names, sorting the newest one to be first.

    4. That output is then fed into the head command to take only the first line.

    5. That first line (the newest .java file) is then fed into the command line invocation of the Sublime text editor which then opens up the concatenated .java file.

    As before Jeremy's comments remain valid so that's why the find command searches /private/vars/folders.

    Hope this helps (and apologies it's Mac only -- I've tested it on Mac OS Sierra). A modified version might work on Linux, though.

    Cheers Andy

  • Building Processing sketches in Sublime 3 in Arch Linux?

    (Sorry if this question is in the wrong category)

    I followed the steps to install and use processing-sublime in Linux, but so far I haven't been able to build a sketch from Sublime, I get the following output:

    Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=gasp
    Could not create the output folder.
    [Finished in 0.2s with exit code 1]
    [cmd: ['processing-java', '--force', '--sketch=/usr/share/processing/modes/java/examples/Basics/Color/Hue', '--output=/usr/share/processing/modes/java/examples/Basics/Color/Hue/build-tmp', '--run']]
    [dir: /usr/share/processing/modes/java/examples/Basics/Color/Hue]
    [path: /usr/sbin:/sbin:/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/usr/share/processing/processing-java]
    

    I installed the latest Processing from AUR and added processing-java into the PATH in my ~/.profile file.

    Sketches run fine otherwise in Processing.

    Thank in advance

  • Object Array and loading images and txt from two arrays

    Haha, true dat - i just use Sublime Text 3 (it has also ctrl-t for autoformat)

  • How to exit from the live preview

    Hi , I'm a newbie in this so this may be easy for you but nor for me xD. So I used the Ctrl + Alt + P shortcut for setting the code language (for sublime text) in Brackets and it entered in live preview mode and now I can't reset it. Can you help me?

  • Error: 2091 (Clipper / dbf)

    It is very hard to repair a file.

    When you made a copy, try looking at it with a editor like notepad or wordpad or sublime

  • Importing a library when using a 3rd party IDE (atom.io, sublime text, etc)

    Hi everyone

    I'm having some trouble figuring out how to import a library when using atom.io as my IDE

    I'm trying to use peasycam, with this at the top of my sketch:

    import /lib/peasycam/library/peasycam.jar.*;

    and a folder structure like:

    projectFolder/ sketch.pde lib/ peasycam/ library/ peasycam.jar

    Is the .jar even the correct file to be importing? Can anyone explain how to do this?

    Thanks

  • GSoC 2017: OpenGL Deffered Shading Tutorial

    @prince_polka I usually use sublime text for writing everything. I just really like its interface. As far as IDEs similar to the Processing IDE, I know that the Arduino IDE is actually based on the Processing IDE, so it of course is quite similar. As far as the ability to instantly run a sketch, the default Python editor IDLE is pretty similar, with instant run and debug abilities.