Skip to content

Commit

Permalink
moving repository from google code to github.
Browse files Browse the repository at this point in the history
  • Loading branch information
sojamo committed Jul 22, 2014
0 parents commit e3a05cb
Show file tree
Hide file tree
Showing 281 changed files with 107,725 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .buildpath
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<buildpath>
<buildpathentry kind="src" path="src"/>
<buildpathentry kind="con" path="org.eclipse.dltk.mod.launching.INTERPRETER_CONTAINER"/>
<buildpathentry kind="con" path="org.eclipse.vjet.eclipse.core.JSNATIVE_CONTAINER/JS Native Types"/>
<buildpathentry kind="con" path="org.eclipse.vjet.eclipse.core.BROWSER_CONTAINER/Browser SDK"/>
</buildpath>
7 changes: 7 additions & 0 deletions .classpath
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
<classpathentry kind="lib" path="/Users/andreasschlegel/Documents/workspace/libs/core.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
7 changes: 7 additions & 0 deletions .externalToolBuilders/cp5-build.launch
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.ui.externaltools.ProgramBuilderLaunchConfigurationType">
<booleanAttribute key="org.eclipse.debug.ui.ATTR_LAUNCH_IN_BACKGROUND" value="false"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/controlp5/resources/jar.sh}"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_RUN_BUILD_KINDS" value="full,incremental,auto,"/>
<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_TRIGGERS_CONFIGURED" value="true"/>
</launchConfiguration>
6 changes: 6 additions & 0 deletions .gitignore
@@ -0,0 +1,6 @@
/bin/
/distribution/src/
/distribution/tmp/
/distribution/web/
/src-js/
.svn/
33 changes: 33 additions & 0 deletions .project
@@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>controlp5</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.vjet.eclipse.core.builder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
<triggers>auto,full,incremental,</triggers>
<arguments>
<dictionary>
<key>LaunchConfigHandle</key>
<value>&lt;project&gt;/.externalToolBuilders/cp5-build.launch</value>
</dictionary>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.vjet.core.nature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
291 changes: 291 additions & 0 deletions .settings/org.eclipse.jdt.core.prefs

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions .settings/org.eclipse.jdt.ui.prefs
@@ -0,0 +1,3 @@
eclipse.preferences.version=1
formatter_profile=_sojamo
formatter_settings_version=12
2 changes: 2 additions & 0 deletions .settings/org.eclipse.vjet.eclipse.core.prefs
@@ -0,0 +1,2 @@
eclipse.preferences.version=1
initialized_project_from_v4classpath=true
67 changes: 67 additions & 0 deletions README.md
@@ -0,0 +1,67 @@
# ControlP5

ControlP5 is a library written by Andreas Schlegel for the programming environment [processing](http://www.processing.org). ControlP5 is a GUI and controller library for processing that can be used in authoring, application mode.

The range of available controllers includes Slider, Button, Toggle, Knob, Textfield, RadioButton, Checkbox, Lists amongst others. These controllers can be easily added to a processing sketch, or displayed inside a separate control window. They can be organized in tabs or groups as well as rendered into PGraphics buffers. The state of a controller can be saved to file in JSON format.


## Getting Started

To get started, a simple example that will create a slider and automatically link its value to variable v1.

```java

import controlP5.*;

ControlP5 cp5;
int v1;

void setup() {
size(400,400);
noStroke();
cp5 = new ControlP5(this);
cp5.addSlider("v1")
.setPosition(40,40)
.setSize(200,20)
.setRange(100,300)
.setValue(250)
.setColorCaptionLabel(0xff111111);
}

void draw() {
background(0xffdddddd);
pushMatrix();
fill(0xffffdc00);
rect(v1,100,60,200);
fill(0xff01ff70);
rect(40,v1,320,40);
translate(200,200);
rotate(map(v1,100,300,-PI,PI));
fill(0xff39cccc);
rect(0,0,100,100);
popMatrix();
}
```



## History

ControlP5 is a project that started in 2006 as a very simple UI for controlling Processing parameters for better debugging, testing and interaction purposes. Starting from only 3 controllers its controller base has grown up to around 30 controllers and over 70 examples. A history of controlP5 versions is available at [google code downloads](https://code.google.com/p/controlp5/downloads/list?can=1&q=&colspec=Filename+Summary+Uploaded+ReleaseDate+Size+DownloadCount). This library has been widely used by processing user in academic, research and professional environments for prototyping and tool development.


### Why is controlP5's source code so convoluted and bloated

ControlP5 has been in development for over 9 years and started as a small GUI library for Processing. Over the years both Processing and ControlP5 have grown substantially and as part of that journey many changes have been applied to both. From a ControlP5 perspective some changes were due to changes made to Processing's API and source code, other changes were due to additional controller implementations, extended functionality, user feedback and reuqests. Since writing controlP5 from scratch was a learning process for myself in itself, a proper initial strategy for the software architecture of the library was missing. When it became apparent that a proper architecture would have made the development much easier and comfortable it was already too late, I had to comply to the piles of code I had created. Would I do things differently now? yes I would.


## Font rendering

Why is the bit-font so blurry? it used to be crisp. Let me blame this on the OpenGL texture rendering. If you have a suggestion or a simple and easy to implement solution, please let me know inside the issues section.



## Javascript

Currently there is no javascript version of ControlP5, though I had started implementing a slimmed down version for processing.js but since it is currently unclear which javascript version - processing.js or p5.js - will become the default js version of processing, controlP5.js is on hold. There is a tendency that p5.js will become the primary javascript environment

Binary file added distribution/library/controlP5.jar
Binary file not shown.

0 comments on commit e3a05cb

Please sign in to comment.