FAQ
Cover
This is the archive Discourse for the Processing (ALPHA) software.
Please visit the new Processing forum for current information.

   Processing 1.0 _ALPHA_
   Programming Questions & Help
   Integration
(Moderators: fry, REAS)
   P5 vs Eclipse
« Previous topic | Next topic »

Pages: 1 2 3 4 5 
   Author  Topic: P5 vs Eclipse  (Read 30324 times)
mKoser

WWW Email
Re: P5 vs Eclipse
« Reply #30 on: May 19th, 2004, 9:36pm »

Mario, Karsten, Ariel. Thanks for helping.
 
I've tried adding the address for javac.exe to both the CLASSPATH var and the PATH var of my system, but no love i still get the same error when trying to use the Ant-export.
 
I REALLY need to get some work done tonight, so I'll have to wait for tomorrow to go down your route Ariel.
 
Karsten, I might just take you up on that offer - a shame you aren't coming to TomC's gathering this coming friday at UCL.
 
+ mikkel
 

mikkel crone koser | www.beyondthree.com | http://processing.beyondthree.com
toxi_
Guest
Email
Re: P5 vs Eclipse
« Reply #31 on: May 19th, 2004, 10:17pm »

if this hasn't got to be 1.1 compatible also try to remove the "fork" and "" parameters (one by one!) from the <javac> tag in the build.xml file.
 
Code:
<javac fork="true" target="1.1" srcdir="${src}" destdir="${build}"/>

 
i remember i had problems (slightly different) with this initially myself, but this version of the call seemed to work stable.
 
fjen

WWW
Re: P5 vs Eclipse
« Reply #32 on: Jul 24th, 2004, 12:01pm »

something about the build.xml (as explained in Reply#2):
 
i wanted to have it automaticly open the index.html in a browser (safari) and added the following to build.xml (on os-x) after "makeHTML":
 
Code:
</html>
]]></echo>
          <antcall target="runApplet"/>
    </target>
   <!-- makeHTML end here -->
 
<!-- what i added starts here -->
    <!-- launch applet in Safari on Mac OS-X -->
    <target name="runApplet" description="run applet ..." if="applet.execwith">
                <echo>running applet in ${applet.execwith}</echo>
                <exec dir="/" executable="/usr/bin/open" os="Mac OS X">
                  <arg line="-a ${applet.execwith} ${dist}/index.html"/>
            </exec>
    </target>
    <!-- what i added, end -->

 
the property "applet.execwith" is set to "Safari" as described in step 5 in Reply#2.
 
toxi, maybe you want to add something like that (win/lin/mac) to the original build.xml?
« Last Edit: Jul 24th, 2004, 12:03pm by fjen »  
adm


Re: P5 vs Eclipse
« Reply #33 on: Oct 2nd, 2004, 8:52pm »

I'm trying to setup Eclipse to work with Processing, but am stumbling at the first step. I followed all the steps, but when I tried to compile and run the project, I get a dialog box that says "Errors exist in a required project. Continue launch?" and of course, if I do, the applet doesn't properly initialize or anything.
 
The code in my "HelloP5.java" file is just like toxi's:
Code:

public class HelloP5 extends BApplet {
 void setup() {
  size(200, 200);
 }
 
 void loop() {
  fill(random(255), 50);
  noStroke();
  rect(random(width), random(height), random(100), random(100));
 }
}

There is also a HelloP5.class file in the src folder as well. If I open it, its identical to the HelloP5.java file. Also in the package explorer at the top level are a .classpath and .project file. Anyone know where these erros are arising from? Using Processing 68 and Eclipse 3.0.1. Thanks.
 
-Aaron
 
toxi

WWW
Re: P5 vs Eclipse
« Reply #34 on: Oct 5th, 2004, 7:18pm »

on Oct 2nd, 2004, 8:52pm, adm wrote:
I'm trying to setup Eclipse to work with Processing, but am stumbling at the first step. I followed all the steps, but when I tried to compile and run the project, I get a dialog box that says "Errors exist in a required project. Continue launch" and of course, if I do, the applet doesn't properly initialize or anything

 
hi adm, i'm pretty sure something went wrong somewhere on your journey - i've just finally installed eclipse v3.0.1 + JDTs myself and could rebuild the tutorial without any probs. i'm almost certain you haven't really created a proper "source folder", but just a "normal" folder called "src". it's not the same thing, at least not for eclipse.
 

 
so just repeat that step and try again. hope that helps!
 

http://toxi.co.uk/
akimi

3271202632712026
Re: P5 vs Eclipse
« Reply #35 on: Oct 7th, 2004, 2:29pm »

Hi Toxi,  
 
I tried to follow your guide. There were no errors loading the Applet viewer, however, everytime I run an applet, it's always lead to the same output on the screen, a gray rectangle. Nice. But I think it worked, minor settings is just needed. Any ideas?
 
I have error running Processing V68 IDE that I can't solve, so I thought Eclipse will give me a different result, that's why.
 
Also, I tried to use the Video Samples from the Processing IDE (e.g. loading_Quicktime). However there are undefined methods like loadVideo, beginVideo, image and so on. I mapped all the jars in the lib from processing already. Is there a missing library that I need to map somewhere?
 
Thanks!
 
akimi

3271202632712026
Re: P5 vs Eclipse
« Reply #36 on: Oct 8th, 2004, 7:47pm »

Hi, I dunno which one solved the problem. But it worked! I tried to uninstall all Java softwares (V.1.4.2_04) and remove all javasoft entries from the system registry. And made a fresh installation. I also moved eclipse(V3.0.1)and processing (V6 installation to the main PC directory (C:\), and all applets can be viewed now including the video applets. Great!
 
_C


Re: P5 vs Eclipse
« Reply #37 on: Nov 20th, 2004, 1:38pm »

hi
 
i get various strange looking icons in  
other classes i create in eclipse while
using p5 functions or variables like  
'mouseX', why is this?  
 
greets  
c
 
Bryan


Re: P5 vs Eclipse
« Reply #38 on: Jan 7th, 2005, 9:49pm »

If you're having this issue read on...
 
[quote author=mKoser Code:

Buildfile: C:\eclipse\workspace\HelloP5\build.xml
 
init:
 [delete] Deleting directory C:\eclipse\workspace\HelloP5\build
  [mkdir] Created dir: C:\eclipse\workspace\HelloP5\build
 
compile:
  [javac] Compiling 2 source files to C:\eclipse\workspace\HelloP5\build
  [javac] BUILD FAILED: file:C:/eclipse/workspace/HelloP5/build.xml:38: Error running javac.exe compiler
Total time: 280 milliseconds

 
I've got java installed at "C:\j2sdk1.4.2" I am wondering if the "."'s in the address are bugging Eclipse?
 
[/quote]
 
If you're getting this error open up a command prompt (Start > Programs > Run... type 'cmd' and hit 'OK') and type the following: javac
 
If you receive an error you may need to add the Java SDK to your Windows Path variable.
 
Right click on 'My Computer' (on your desktop) and select 'Properties' - click on the 'Advanced' tab, and then click the 'Environment Variables' button at the bottom.
 
Under 'System Variables' select 'Path' and press 'Edit'. Be VERY careful here - do not erase what is currently there. Simple ADD the following to the end:
 
;C:\j2sdk1.4.2\bin;
 
ONLY add the first semi-colon if there isn't one at the END of the current path variable(s). When finsihed click 'OK' and then 'OK' again. Open up your command prompt again and type 'javac' (without the quotes).
 
You should now see usage info for the javac application. I'm on XP - if you're on an older version of Windows you may need to reboot after setting environment variables.
 
There are probably better ways to set-up the environment vars (using '%JAVA_HOME%', etc) - but I find this usually works regardless. Not sure why the vars in Eclipse/Ant settings don't take - but this does get it working.
 
Cheers,
 
Bryan
« Last Edit: Jan 7th, 2005, 11:17pm by Bryan »  
carloslara

Email
Re: P5 vs Eclipse
« Reply #39 on: Jan 17th, 2005, 11:47pm »

Hey i managed to set up the p5 eclipse environment.  
it will accept a lot of p5 functions  
however doesnt like the color class. for some reason. has this happened to anybody else?
 
arielm

WWW
Re: P5 vs Eclipse
« Reply #40 on: Jan 18th, 2005, 6:23pm »

the color construct is something added by processing's "preprocessor", so it won't work in pure java environments like eclipse...
 
in the same collection: processing let you enter a number in the form 1.5 and make the compiler think it's a float while in pure java this syntax would have mean "double" (for floats, you need to write 1.5f...)
 

Ariel Malka | www.chronotext.org
carloslara

Email
thanks
« Reply #41 on: Jan 18th, 2005, 7:26pm »

alright so i should just not use it or do my own color class right?
 
thanks
 
Carlos
 
eskimoblood

222550793222550793 WWW
Re: P5 vs Eclipse
« Reply #42 on: Jan 20th, 2005, 6:15pm »

Is there a way to work with the netscape.javascript classes in eclipse? At the import netscape.javascript.* statment, eclipse told me: "The import netscape cannot be resolved"
 
toxi

WWW
Re: P5 vs Eclipse
« Reply #43 on: Jan 21st, 2005, 3:25pm »

eskimo, of course you've got to add the netscape classes to your eclipse classpath first. the classes themselves are bundled with every processing distribution, so in eclipse (v3) do the following...
 
* open the project preferences (eg. right-click on project name and choose properties)
 
* from the left pane select "Java Build Path", then press the "Add class folder" button..
 
* in the dialog box select "create new folder..."
 
* use "lib" as new folder name, then press the "advanced" button
 
* check the "link to folder" checkbox and choose the "lib" folder inside your processing root directory
 
* confirm all dialogs with "OK" and you should be ready to go...
 

http://toxi.co.uk/
eskimoblood

222550793222550793 WWW
Re: P5 vs Eclipse
« Reply #44 on: Jan 24th, 2005, 6:41pm »

It works. Thanks toxi
 
Pages: 1 2 3 4 5 

« Previous topic | Next topic »