Results 1 to 4 of 4

Thread: Processing help

  1. #1
    menez is offline Member
    Join Date
    Feb 2010
    Posts
    1
    Rep Power
    0

    Default Processing help

    Hi guys I recently got into this and need some help developing a certain app. The instructions of the app is to make the color of the app change. I am using Processing now and the instructions is to use the IF/ELSE. I am familiar with PHP but this is a bit new to me. I have to use mouseX and mouseY. here is the code I have. I want it that when I click over the left top square it changed both black squares white.

    Java Code:
    int x;
    int y;
    void setup() {  
        loop();
      size(200, 200);
      background(255,0,0);	
      fill(0);
      rect(0, 0, 100, 100);
      fill(0);
      rect(100, 100, 100, 100);
    }
    if (mouseX - (0, 0, 100, 100)) {
      fill(255);
      rect(0, 0, 100, 100);
      fill(255);
      rect(100, 100, 100, 100);
    }

  2. #2
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

  3. #3
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    26

  4. #4
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

Similar Threads

  1. image processing
    By sunithamm in forum Advanced Java
    Replies: 6
    Last Post: 12-30-2010, 11:46 AM
  2. Image Processing
    By Josh_FL in forum Advanced Java
    Replies: 4
    Last Post: 12-30-2008, 02:45 AM
  3. image processing
    By sathish natrajan in forum Java 2D
    Replies: 2
    Last Post: 11-06-2008, 05:13 PM
  4. list processing
    By kazitula in forum Java Applets
    Replies: 1
    Last Post: 01-22-2008, 09:35 PM

Posting Permissions

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