operations implemented

This commit is contained in:
jan 2016-07-10 17:51:01 -07:00
parent 8c41aa417a
commit 19ca54add7
18 changed files with 879 additions and 742 deletions

View File

@ -2,18 +2,24 @@
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="6e752a8c-6cb9-4ef9-9031-0329ce15fcb4" name="Default" comment="Ellipse can be drawn..."> <list default="true" id="6e752a8c-6cb9-4ef9-9031-0329ce15fcb4" name="Default" comment="Ellipse can be drawn...">
<change type="DELETED" beforePath="$PROJECT_DIR$/src/Procedure.java" afterPath="" /> <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/src/Expand.java" />
<change type="DELETED" beforePath="$PROJECT_DIR$/src/clearDisplay.java" afterPath="" /> <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/src/Rotate.java" />
<change type="MOVED" beforePath="$PROJECT_DIR$/src/LineClass.java" afterPath="$PROJECT_DIR$/src/Line.java" /> <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/src/Shrink.java" />
<change type="MOVED" beforePath="$PROJECT_DIR$/src/RectangleClass.java" afterPath="$PROJECT_DIR$/src/Rectangle.java" /> <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/src/Translate.java" />
<change type="MOVED" beforePath="$PROJECT_DIR$/src/TriangleClass.java" afterPath="$PROJECT_DIR$/src/Triangle.java" /> <change type="DELETED" beforePath="$PROJECT_DIR$/src/ExpandClass.java" afterPath="" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/compiler.xml" afterPath="$PROJECT_DIR$/.idea/compiler.xml" /> <change type="DELETED" beforePath="$PROJECT_DIR$/src/RotateClass.java" afterPath="" />
<change type="DELETED" beforePath="$PROJECT_DIR$/src/ShrinkClass.java" afterPath="" />
<change type="DELETED" beforePath="$PROJECT_DIR$/src/TranslateClass.java" afterPath="" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Calibrator.java" afterPath="$PROJECT_DIR$/src/Calibrator.java" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/ClickGetter.java" afterPath="$PROJECT_DIR$/src/ClickGetter.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Ellipse.java" afterPath="$PROJECT_DIR$/src/Ellipse.java" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Ellipse.java" afterPath="$PROJECT_DIR$/src/Ellipse.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/EuglenaApplet.java" afterPath="$PROJECT_DIR$/src/EuglenaApplet.java" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/EuglenaApplet.java" afterPath="$PROJECT_DIR$/src/EuglenaApplet.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Line.java" afterPath="$PROJECT_DIR$/src/Line.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Menu.java" afterPath="$PROJECT_DIR$/src/Menu.java" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Menu.java" afterPath="$PROJECT_DIR$/src/Menu.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/ProjectorApplet.java" afterPath="$PROJECT_DIR$/src/ProjectorApplet.java" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/ProjectorApplet.java" afterPath="$PROJECT_DIR$/src/ProjectorApplet.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/ProjectorCommand.java" afterPath="$PROJECT_DIR$/src/ProjectorCommand.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Rectangle.java" afterPath="$PROJECT_DIR$/src/Rectangle.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/Triangle.java" afterPath="$PROJECT_DIR$/src/Triangle.java" />
</list> </list>
<ignored path="processing-intellij.iws" /> <ignored path="processing-intellij.iws" />
<ignored path=".idea/workspace.xml" /> <ignored path=".idea/workspace.xml" />
@ -37,8 +43,8 @@
<file leaf-file-name="euglena_basic_stimuli.java" pinned="false" current-in-tab="true"> <file leaf-file-name="euglena_basic_stimuli.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/euglena_basic_stimuli.java"> <entry file="file://$PROJECT_DIR$/src/euglena_basic_stimuli.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="193"> <state relative-caret-position="432">
<caret line="59" column="15" selection-start-line="59" selection-start-column="15" selection-end-line="59" selection-end-column="15" /> <caret line="83" column="4" selection-start-line="83" selection-start-column="0" selection-end-line="83" selection-end-column="4" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
</folding> </folding>
@ -57,60 +63,49 @@
</component> </component>
<component name="FileEditorManager"> <component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300"> <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="EuglenaApplet.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/EuglenaApplet.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="889">
<caret line="105" column="11" selection-start-line="105" selection-start-column="11" selection-end-line="105" selection-end-column="11" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="ProjectorApplet.java" pinned="false" current-in-tab="false"> <file leaf-file-name="ProjectorApplet.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java"> <entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="648"> <state relative-caret-position="1530">
<caret line="60" column="33" selection-start-line="60" selection-start-column="33" selection-end-line="60" selection-end-column="33" /> <caret line="97" column="0" selection-start-line="97" selection-start-column="0" selection-end-line="97" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#549#550#0" expanded="true" /> <element signature="e#545#546#0" expanded="true" />
<element signature="e#608#609#0" expanded="true" /> <element signature="e#604#605#0" expanded="true" />
<element signature="e#1255#1256#0" expanded="true" /> <element signature="e#1739#1740#0" expanded="true" />
<element signature="e#1282#1283#0" expanded="true" /> <element signature="e#1779#1780#0" expanded="true" />
<element signature="e#1333#1334#0" expanded="true" />
<element signature="e#1373#1374#0" expanded="true" />
<element signature="e#1404#1405#0" expanded="true" />
<element signature="e#1434#1435#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
<file leaf-file-name="Calibrator.java" pinned="false" current-in-tab="false"> <file leaf-file-name="Ellipse.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Calibrator.java"> <entry file="file://$PROJECT_DIR$/src/Ellipse.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="396"> <state relative-caret-position="450">
<caret line="101" column="29" selection-start-line="101" selection-start-column="29" selection-end-line="101" selection-end-column="29" /> <caret line="58" column="0" selection-start-line="58" selection-start-column="0" selection-end-line="79" selection-end-column="5" />
<folding> <folding>
<element signature="e#0#3821#0" expanded="true" />
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
<file leaf-file-name="LEDControl.java" pinned="false" current-in-tab="false"> <file leaf-file-name="Rectangle.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/LEDControl.java"> <entry file="file://$PROJECT_DIR$/src/Rectangle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="306">
<caret line="39" column="37" selection-start-line="39" selection-start-column="37" selection-end-line="39" selection-end-column="37" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="Triangle.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Triangle.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="252"> <state relative-caret-position="252">
<caret line="7" column="20" selection-start-line="7" selection-start-column="20" selection-end-line="7" selection-end-column="20" /> <caret line="50" column="0" selection-start-line="50" selection-start-column="0" selection-end-line="50" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
</folding> </folding>
@ -118,11 +113,61 @@
</provider> </provider>
</entry> </entry>
</file> </file>
<file leaf-file-name="Menu.java" pinned="false" current-in-tab="false"> <file leaf-file-name="shrinkingCircle.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Menu.java"> <entry file="file://$PROJECT_DIR$/src/shrinkingCircle.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8424"> <state relative-caret-position="630">
<caret line="234" column="26" selection-start-line="234" selection-start-column="26" selection-end-line="234" selection-end-column="26" /> <caret line="35" column="7" selection-start-line="35" selection-start-column="7" selection-end-line="35" selection-end-column="7" />
<folding>
<element signature="e#0#1183#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="Rotate.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Rotate.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="540">
<caret line="30" column="52" selection-start-line="30" selection-start-column="52" selection-end-line="30" selection-end-column="52" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="Shrink.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Shrink.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="576">
<caret line="39" column="34" selection-start-line="39" selection-start-column="34" selection-end-line="39" selection-end-column="34" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#821#822#0" expanded="true" />
<element signature="e#869#870#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="Translate.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Translate.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="542">
<caret line="94" column="29" selection-start-line="94" selection-start-column="29" selection-end-line="94" selection-end-column="29" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="Expand.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Expand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="360">
<caret line="20" column="33" selection-start-line="20" selection-start-column="33" selection-end-line="20" selection-end-column="33" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
</folding> </folding>
@ -135,8 +180,8 @@
<component name="FileTemplateManagerImpl"> <component name="FileTemplateManagerImpl">
<option name="RECENT_TEMPLATES"> <option name="RECENT_TEMPLATES">
<list> <list>
<option value="Class" />
<option value="Interface" /> <option value="Interface" />
<option value="Class" />
</list> </list>
</option> </option>
</component> </component>
@ -161,29 +206,33 @@
<option value="$PROJECT_DIR$/src/Camera.java" /> <option value="$PROJECT_DIR$/src/Camera.java" />
<option value="$PROJECT_DIR$/src/EllipseClass.java" /> <option value="$PROJECT_DIR$/src/EllipseClass.java" />
<option value="$PROJECT_DIR$/src/Command.java" /> <option value="$PROJECT_DIR$/src/Command.java" />
<option value="$PROJECT_DIR$/src/ProjectorCommand.java" />
<option value="$PROJECT_DIR$/src/MouseGetter.java" /> <option value="$PROJECT_DIR$/src/MouseGetter.java" />
<option value="$PROJECT_DIR$/src/ClickGetter.java" />
<option value="$PROJECT_DIR$/src/Procedure.java" /> <option value="$PROJECT_DIR$/src/Procedure.java" />
<option value="$PROJECT_DIR$/src/LEDControl.java" /> <option value="$PROJECT_DIR$/src/LEDControl.java" />
<option value="$PROJECT_DIR$/src/euglena_basic_stimuli.java" /> <option value="$PROJECT_DIR$/src/euglena_basic_stimuli.java" />
<option value="$PROJECT_DIR$/src/Ellipse.java" />
<option value="$PROJECT_DIR$/src/Rectangle.java" />
<option value="$PROJECT_DIR$/src/Calibrator.java" /> <option value="$PROJECT_DIR$/src/Calibrator.java" />
<option value="$PROJECT_DIR$/src/Line.java" />
<option value="$PROJECT_DIR$/src/Triangle.java" />
<option value="$PROJECT_DIR$/src/clearDisplay.java" /> <option value="$PROJECT_DIR$/src/clearDisplay.java" />
<option value="$PROJECT_DIR$/src/ProjectorApplet.java" />
<option value="$PROJECT_DIR$/src/Menu.java" /> <option value="$PROJECT_DIR$/src/Menu.java" />
<option value="$PROJECT_DIR$/src/EuglenaApplet.java" /> <option value="$PROJECT_DIR$/src/EuglenaApplet.java" />
<option value="$PROJECT_DIR$/src/ClickGetter.java" />
<option value="$PROJECT_DIR$/src/Line.java" />
<option value="$PROJECT_DIR$/src/Ellipse.java" />
<option value="$PROJECT_DIR$/src/Rectangle.java" />
<option value="$PROJECT_DIR$/src/Triangle.java" />
<option value="$PROJECT_DIR$/src/ProjectorCommand.java" />
<option value="$PROJECT_DIR$/src/RotateClass.java" />
<option value="$PROJECT_DIR$/src/ProjectorApplet.java" />
<option value="$PROJECT_DIR$/src/Shrink.java" />
<option value="$PROJECT_DIR$/src/Rotate.java" />
<option value="$PROJECT_DIR$/src/Translate.java" />
<option value="$PROJECT_DIR$/src/Expand.java" />
</list> </list>
</option> </option>
</component> </component>
<component name="ProjectFrameBounds"> <component name="ProjectFrameBounds">
<option name="x" value="-2" /> <option name="x" value="1920" />
<option name="y" value="-2" /> <option name="width" value="1280" />
<option name="width" value="1602" /> <option name="height" value="1440" />
<option name="height" value="1804" />
</component> </component>
<component name="ProjectLevelVcsManager" settingsEditedManually="true"> <component name="ProjectLevelVcsManager" settingsEditedManually="true">
<OptionsSetting value="true" id="Add" /> <OptionsSetting value="true" id="Add" />
@ -196,7 +245,7 @@
<ConfirmationsSetting value="0" id="Remove" /> <ConfirmationsSetting value="0" id="Remove" />
</component> </component>
<component name="ProjectView"> <component name="ProjectView">
<navigator proportions="" version="1"> <navigator currentView="ProjectPane" proportions="" version="1">
<flattenPackages /> <flattenPackages />
<showMembers /> <showMembers />
<showModules /> <showModules />
@ -209,7 +258,45 @@
<manualOrder /> <manualOrder />
<foldersAlwaysOnTop value="true" /> <foldersAlwaysOnTop value="true" />
</navigator> </navigator>
<panes /> <panes>
<pane id="Scope" />
<pane id="ProjectPane">
<subPane>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="processing-intellij" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="processing-intellij" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="eug3" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="processing-intellij" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="eug3" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
</subPane>
</pane>
<pane id="Scratches" />
<pane id="PackagesPane" />
</panes>
</component> </component>
<component name="PropertiesComponent"> <component name="PropertiesComponent">
<property name="last_opened_file_path" value="$PROJECT_DIR$" /> <property name="last_opened_file_path" value="$PROJECT_DIR$" />
@ -243,62 +330,14 @@
<envs /> <envs />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="GradleRunConfiguration" factoryName="Gradle"> <configuration default="true" type="CargoCommandRunConfiguration" factoryName="Cargo Command" show_console_on_std_err="false" show_console_on_std_out="false">
<ExternalSystemSettings> <option name="additionalArguments" value="" />
<option name="executionName" /> <option name="command" value="run" />
<option name="externalProjectPath" /> <option name="environmentVariables">
<option name="externalSystemIdString" value="GRADLE" /> <map />
<option name="scriptParameters" />
<option name="taskDescriptions">
<list />
</option> </option>
<option name="taskNames"> <option name="printBacktrace" value="false" />
<list /> <module name="processing-intellij" />
</option>
<option name="vmOptions" />
</ExternalSystemSettings>
<method />
</configuration>
<configuration default="true" type="JUnit" factoryName="JUnit">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<module name="" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" />
<option name="MAIN_CLASS_NAME" />
<option name="METHOD_NAME" />
<option name="TEST_OBJECT" value="class" />
<option name="VM_PARAMETERS" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="ENV_VARIABLES" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="TEST_SEARCH_SCOPE">
<value defaultName="singleModule" />
</option>
<envs />
<patterns />
<method />
</configuration>
<configuration default="true" type="JUnitTestDiscovery" factoryName="JUnit Test Discovery" changeList="All">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<module name="" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" />
<option name="MAIN_CLASS_NAME" />
<option name="METHOD_NAME" />
<option name="TEST_OBJECT" value="class" />
<option name="VM_PARAMETERS" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="ENV_VARIABLES" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="TEST_SEARCH_SCOPE">
<value defaultName="singleModule" />
</option>
<envs />
<patterns />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="JarApplication" factoryName="JAR Application"> <configuration default="true" type="JarApplication" factoryName="JAR Application">
@ -355,62 +394,6 @@
<option name="PORT" value="5005" /> <option name="PORT" value="5005" />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="TestNG" factoryName="TestNG">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<module name="" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="SUITE_NAME" />
<option name="PACKAGE_NAME" />
<option name="MAIN_CLASS_NAME" />
<option name="METHOD_NAME" />
<option name="GROUP_NAME" />
<option name="TEST_OBJECT" value="CLASS" />
<option name="VM_PARAMETERS" value="-ea" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
<option name="OUTPUT_DIRECTORY" />
<option name="ANNOTATION_TYPE" />
<option name="ENV_VARIABLES" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="TEST_SEARCH_SCOPE">
<value defaultName="singleModule" />
</option>
<option name="USE_DEFAULT_REPORTERS" value="false" />
<option name="PROPERTIES_FILE" />
<envs />
<properties />
<listeners />
<method />
</configuration>
<configuration default="true" type="TestNGTestDiscovery" factoryName="TestNG Test Discovery" changeList="All">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<module name="" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="SUITE_NAME" />
<option name="PACKAGE_NAME" />
<option name="MAIN_CLASS_NAME" />
<option name="METHOD_NAME" />
<option name="GROUP_NAME" />
<option name="TEST_OBJECT" value="CLASS" />
<option name="VM_PARAMETERS" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="OUTPUT_DIRECTORY" />
<option name="ANNOTATION_TYPE" />
<option name="ENV_VARIABLES" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="TEST_SEARCH_SCOPE">
<value defaultName="singleModule" />
</option>
<option name="USE_DEFAULT_REPORTERS" value="false" />
<option name="PROPERTIES_FILE" />
<envs />
<properties />
<listeners />
<method />
</configuration>
<configuration default="false" name="ExampleApplet" type="Application" factoryName="Application"> <configuration default="false" name="ExampleApplet" type="Application" factoryName="Application">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" /> <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<option name="MAIN_CLASS_NAME" value="EuglenaApplet" /> <option name="MAIN_CLASS_NAME" value="EuglenaApplet" />
@ -465,29 +448,29 @@
<servers /> <servers />
</component> </component>
<component name="ToolWindowManager"> <component name="ToolWindowManager">
<frame x="-2" y="-2" width="1602" height="1804" extended-state="4" /> <frame x="1920" y="0" width="1280" height="1440" extended-state="4" />
<editor active="true" /> <editor active="true" />
<layout> <layout>
<window_info id="Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.18503937" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4006192" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" /> <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4006192" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Palette&#9;" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> <window_info id="Palette&#9;" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="true" content_ui="tabs" /> <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="true" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" /> <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.26811147" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" /> <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.2675112" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.18503937" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32879257" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.2159031" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.2159031" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="true" content_ui="tabs" /> <window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="true" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" /> <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.39940387" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> <window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="SLIDING" type="SLIDING" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="SLIDING" type="SLIDING" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" /> <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32879257" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
</layout> </layout>
<layout-to-restore> <layout-to-restore>
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
@ -536,34 +519,16 @@
<option name="FILTER_TARGETS" value="false" /> <option name="FILTER_TARGETS" value="false" />
</component> </component>
<component name="editorHistoryManager"> <component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/src/EuglenaApplet.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="630">
<caret line="39" column="5" selection-start-line="39" selection-start-column="5" selection-end-line="39" selection-end-column="5" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java"> <entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="558"> <state relative-caret-position="558">
<caret line="33" column="18" selection-start-line="33" selection-start-column="8" selection-end-line="33" selection-end-column="18" /> <caret line="33" column="18" selection-start-line="33" selection-start-column="8" selection-end-line="33" selection-end-column="18" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#549#550#0" expanded="true" /> <element signature="e#545#546#0" expanded="true" />
<element signature="e#608#609#0" expanded="true" /> <element signature="e#604#605#0" expanded="true" />
<element signature="e#1255#1256#0" expanded="true" /> <element signature="e#1739#1740#0" expanded="true" />
<element signature="e#1282#1283#0" expanded="true" /> <element signature="e#1779#1780#0" expanded="true" />
<element signature="e#1333#1334#0" expanded="true" />
<element signature="e#1373#1374#0" expanded="true" />
<element signature="e#1404#1405#0" expanded="true" />
<element signature="e#1434#1435#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -626,10 +591,10 @@
<caret line="40" column="35" selection-start-line="40" selection-start-column="35" selection-end-line="40" selection-end-column="35" /> <caret line="40" column="35" selection-start-line="40" selection-start-column="35" selection-end-line="40" selection-end-column="35" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -665,10 +630,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -679,10 +644,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -693,10 +658,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -707,10 +672,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -721,10 +686,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -735,10 +700,10 @@
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
@ -793,22 +758,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/ProjectorCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="36">
<caret line="1" column="4" selection-start-line="1" selection-start-column="4" selection-end-line="1" selection-end-column="4" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ClickGetter.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="36">
<caret line="1" column="42" selection-start-line="1" selection-start-column="42" selection-end-line="1" selection-end-column="42" />
<folding />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/core.jar!/processing/core/PApplet.class"> <entry file="jar://$PROJECT_DIR$/lib/core.jar!/processing/core/PApplet.class">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="812"> <state relative-caret-position="812">
@ -817,101 +766,26 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/Procedure.java"> <entry file="file://$PROJECT_DIR$/src/Procedure.java" />
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="36">
<caret line="1" column="17" selection-start-line="1" selection-start-column="17" selection-end-line="1" selection-end-column="17" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Presets.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="72">
<caret line="30" column="6" selection-start-line="30" selection-start-column="6" selection-end-line="30" selection-end-column="6" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/euglena_basic_stimuli.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="193">
<caret line="59" column="15" selection-start-line="59" selection-start-column="15" selection-end-line="59" selection-end-column="15" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Line.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="961">
<caret line="74" column="0" selection-start-line="74" selection-start-column="0" selection-end-line="74" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Triangle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="849">
<caret line="29" column="27" selection-start-line="29" selection-start-column="27" selection-end-line="29" selection-end-column="27" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/testing.java"> <entry file="file://$PROJECT_DIR$/src/testing.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="180"> <state relative-caret-position="180">
<caret line="5" column="10" selection-start-line="5" selection-start-column="10" selection-end-line="5" selection-end-column="10" /> <caret line="5" column="10" selection-start-line="5" selection-start-column="10" selection-end-line="5" selection-end-column="10" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/clearDisplay.java" />
<entry file="jar:///usr/lib/jvm/java-8-openjdk-amd64/jre/lib/rt.jar!/java/lang/Integer.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1015">
<caret line="201" column="5" selection-start-line="201" selection-start-column="5" selection-end-line="201" selection-end-column="5" />
<folding /> <folding />
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/Ellipse.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="288">
<caret line="8" column="20" selection-start-line="0" selection-start-column="0" selection-end-line="82" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Rectangle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/clearDisplay.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="144">
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="8" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Menu.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8424">
<caret line="234" column="26" selection-start-line="234" selection-start-column="26" selection-end-line="234" selection-end-column="26" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/LEDControl.java"> <entry file="file://$PROJECT_DIR$/src/LEDControl.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="252"> <state relative-caret-position="126">
<caret line="7" column="20" selection-start-line="7" selection-start-column="20" selection-end-line="7" selection-end-column="20" /> <caret line="7" column="20" selection-start-line="7" selection-start-column="20" selection-end-line="7" selection-end-column="20" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
@ -919,9 +793,19 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/Menu.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="396">
<caret line="190" column="46" selection-start-line="190" selection-start-column="46" selection-end-line="190" selection-end-column="46" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Calibrator.java"> <entry file="file://$PROJECT_DIR$/src/Calibrator.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="396"> <state relative-caret-position="416">
<caret line="101" column="29" selection-start-line="101" selection-start-column="29" selection-end-line="101" selection-end-column="29" /> <caret line="101" column="29" selection-start-line="101" selection-start-column="29" selection-end-line="101" selection-end-column="29" />
<folding> <folding>
<element signature="e#0#3821#0" expanded="true" /> <element signature="e#0#3821#0" expanded="true" />
@ -930,38 +814,199 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java"> <entry file="file://$PROJECT_DIR$/src/Line.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="648"> <state relative-caret-position="740">
<caret line="60" column="33" selection-start-line="60" selection-start-column="33" selection-end-line="60" selection-end-column="33" /> <caret line="68" column="47" selection-start-line="68" selection-start-column="47" selection-end-line="68" selection-end-column="47" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/euglena_basic_stimuli.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="432">
<caret line="83" column="4" selection-start-line="83" selection-start-column="0" selection-end-line="83" selection-end-column="4" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#549#550#0" expanded="true" />
<element signature="e#608#609#0" expanded="true" />
<element signature="e#1255#1256#0" expanded="true" />
<element signature="e#1282#1283#0" expanded="true" />
<element signature="e#1333#1334#0" expanded="true" />
<element signature="e#1373#1374#0" expanded="true" />
<element signature="e#1404#1405#0" expanded="true" />
<element signature="e#1434#1435#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/EuglenaApplet.java"> <entry file="file://$PROJECT_DIR$/src/EuglenaApplet.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="889"> <state relative-caret-position="918">
<caret line="105" column="11" selection-start-line="105" selection-start-column="11" selection-end-line="105" selection-end-column="11" /> <caret line="55" column="44" selection-start-line="55" selection-start-column="39" selection-end-line="55" selection-end-column="44" />
<folding> <folding>
<element signature="imports" expanded="true" /> <element signature="imports" expanded="true" />
<element signature="e#474#475#0" expanded="true" /> <element signature="e#2317#2318#0" expanded="true" />
<element signature="e#519#520#0" expanded="true" /> <element signature="e#2360#2361#0" expanded="true" />
<element signature="e#2486#2487#0" expanded="true" /> <element signature="e#2415#2416#0" expanded="true" />
<element signature="e#2529#2530#0" expanded="true" /> <element signature="e#2458#2459#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/ClickGetter.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="540">
<caret line="30" column="2" selection-start-line="30" selection-start-column="2" selection-end-line="30" selection-end-column="2" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ProjectorCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="162">
<caret line="9" column="0" selection-start-line="9" selection-start-column="0" selection-end-line="9" selection-end-column="0" />
<folding>
<element signature="e#206#207#0" expanded="true" />
<element signature="e#236#237#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Presets.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="36">
<caret line="30" column="6" selection-start-line="30" selection-start-column="6" selection-end-line="30" selection-end-column="6" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Ellipse.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="450">
<caret line="58" column="0" selection-start-line="58" selection-start-column="0" selection-end-line="79" selection-end-column="5" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ShrinkClass.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-36">
<caret line="33" column="31" selection-start-line="33" selection-start-column="21" selection-end-line="33" selection-end-column="31" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/RotateClass.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="504">
<caret line="28" column="1" selection-start-line="0" selection-start-column="0" selection-end-line="68" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ProjectorApplet.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1530">
<caret line="97" column="0" selection-start-line="97" selection-start-column="0" selection-end-line="97" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#545#546#0" expanded="true" />
<element signature="e#604#605#0" expanded="true" />
<element signature="e#1739#1740#0" expanded="true" />
<element signature="e#1779#1780#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/TranslateClass.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="90">
<caret line="35" column="1" selection-start-line="0" selection-start-column="0" selection-end-line="99" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/ExpandClass.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="414">
<caret line="25" column="42" selection-start-line="0" selection-start-column="0" selection-end-line="84" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/merge.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="828">
<caret line="46" column="58" selection-start-line="46" selection-start-column="58" selection-end-line="46" selection-end-column="58" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Expand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="360">
<caret line="20" column="33" selection-start-line="20" selection-start-column="33" selection-end-line="20" selection-end-column="33" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Translate.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="542">
<caret line="94" column="29" selection-start-line="94" selection-start-column="29" selection-end-line="94" selection-end-column="29" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Shrink.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="576">
<caret line="39" column="34" selection-start-line="39" selection-start-column="34" selection-end-line="39" selection-end-column="34" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#821#822#0" expanded="true" />
<element signature="e#869#870#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Rotate.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="540">
<caret line="30" column="52" selection-start-line="30" selection-start-column="52" selection-end-line="30" selection-end-column="52" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/shrinkingCircle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="630">
<caret line="35" column="7" selection-start-line="35" selection-start-column="7" selection-end-line="35" selection-end-column="7" />
<folding>
<element signature="e#0#1183#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Triangle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="252">
<caret line="50" column="0" selection-start-line="50" selection-start-column="0" selection-end-line="50" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/Rectangle.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="306">
<caret line="39" column="37" selection-start-line="39" selection-start-column="37" selection-end-line="39" selection-end-column="37" />
<folding />
</state>
</provider>
</entry>
</component> </component>
<component name="masterDetails"> <component name="masterDetails">
<states> <states>

View File

@ -1,3 +1,43 @@
public interface ClickGetter { public interface ClickGetter {
boolean click(int mouseX, int mouseY); boolean click(int mouseX, int mouseY);
} }
//public interface Shape {
// public int numVertices();
//}
//
//
//class Circle2 implements Shape {
// Circle2() {
// blah;
// }
//
// int numVertices() {
// return 0;
// }
//
// void expand() {
// blah2;
// }
//}
//
//class Square implements Shape {
// int numVertices() {
// return 4;
// }
//}
//
//
//Shape g = new Circle2();
////g.expand(); // bad
//println(g.numVertices()); //good
//g = new Square();
//println(g.numVertices());
//
//void printNumberOfVertices(Shape s) {
// println(s.numVertices());
//}
//
//printNumberOfVertices(new Circle2());
//printNumberOfVertices(new Square());

View File

@ -32,7 +32,7 @@ class Ellipse {
this.widthComplete = true; this.widthComplete = true;
} }
ProjectorCommand drawCommand() { ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> { return (ProjectorApplet p) -> {
if (!visible) { if (!visible) {
//done drawing already //done drawing already
@ -49,6 +49,7 @@ class Ellipse {
p.ellipse(p.convertXCoord(centerX), p.convertYCoord(centerY), p.ellipse(p.convertXCoord(centerX), p.convertYCoord(centerY),
p.convertXDistance(width), p.convertYDistance(height)); p.convertXDistance(width), p.convertYDistance(height));
p.strokeWeight(old_strokeWeight); p.strokeWeight(old_strokeWeight);
p.stroke(old_strokeColor); p.stroke(old_strokeColor);
return true; return true;
@ -72,7 +73,7 @@ class Ellipse {
height = abs(centerY - y) * 2; height = abs(centerY - y) * 2;
visible = true; visible = true;
p.commandQueue.add(drawCommand()); p.commandQueue.add(makeProjectorCommand());
return true; return true;
} }
}; };

View File

@ -60,8 +60,15 @@ public class EuglenaApplet extends PApplet {
@Override @Override
public void mouseClicked(){ public void mouseClicked(){
// Ignore mouse clicks in menu area
if (mouseX > width - menu.width) {
return;
}
// If we have a clickGetter, use that to handle the mouse click
if (clickGetter != null) { if (clickGetter != null) {
if (clickGetter.click(mouseX, mouseY)) { boolean done = clickGetter.click(mouseX, mouseY);
if (done) {
clickGetter = null; clickGetter = null;
} }
} }
@ -69,17 +76,12 @@ public class EuglenaApplet extends PApplet {
@Override @Override
public void keyPressed() { public void keyPressed() {
ledControl.keyPressed(key);
if (key == CODED) { if (key == CODED) {
projectorApplet.calibrator.buttonPressed(keyCode); projectorApplet.calibrator.buttonPressed(keyCode);
} else { } else {
switch(key) { switch(key) {
case 'd':
case 'w':
case 'a':
case 's':
ledControl.keyPressed(key);
break;
case ENTER: case ENTER:
//TODO: snapshot //TODO: snapshot
//snapshot(); //snapshot();
@ -93,14 +95,7 @@ public class EuglenaApplet extends PApplet {
@Override @Override
public void keyReleased() { public void keyReleased() {
switch(key) {
case 'd':
case 'w':
case 'a':
case 's':
ledControl.keyReleased(key); ledControl.keyReleased(key);
break;
}
} }
public void controlEvent(ControlEvent theEvent) { public void controlEvent(ControlEvent theEvent) {

96
src/Expand.java Normal file
View File

@ -0,0 +1,96 @@
import processing.core.*;
import static processing.core.PApplet.*;
public class Expand {
float corner1x, corner1y, corner2x, corner2y, speed;
int timeElapsed, millisInit;
PImage expandRegion;
private boolean corner1complete;
Expand(float speed) {
this.speed = speed;
this.corner1complete = false;
}
Expand(float corner1x, float corner1y, float corner2x, float corner2y, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.speed = speed;
this.corner1complete = true;
}
float aspectRatio() {
return abs((corner2x - corner1x) / (corner2y - corner1y));
}
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
void saveExpandRegion(ProjectorApplet p) {
this.expandRegion = p.get(
(int) p.convertXCoord(corner1x),
(int) p.convertYCoord(corner1y),
(int) abs(p.convertXDistance(corner2x - corner1x)),
(int) abs(p.convertYDistance(corner2y - corner1y)));
}
ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> {
timeElapsed = p.millis() - millisInit;
float spaceElapsed = speed * (timeElapsed / 1000f);
if (p.convertYDistance(corner2y - corner1y) + spaceElapsed >= p.convertYDistance(p.height)) {
return true;
}
p.noFill();
p.noStroke();
p.rectMode(CORNER);
p.rect(p.convertXCoord(corner1x), p.convertYCoord(corner1y),
p.convertXDistance(corner2x - corner1x), p.convertYDistance(corner2y - corner1y));
p.imageMode(CENTER);
p.image(expandRegion,
p.convertXCoord(this.centerx()),
p.convertYCoord(this.centery()),
p.convertXDistance(corner2x - corner1x) + spaceElapsed * aspectRatio(),
p.convertYDistance(corner2y - corner1y) + spaceElapsed);
return false;
};
}
ClickGetter makeClickGetter(ProjectorApplet p) {
return (int x, int y) -> {
if (!corner1complete) {
corner1x = x;
corner1y = y;
corner1complete = true;
return false;
} else {
corner2x = x;
corner2y = y;
millisInit = p.millis();
saveExpandRegion(p);
p.commandQueue.add(makeProjectorCommand());
return true;
}
};
}
}

View File

@ -1,84 +0,0 @@
class Expand {
ExpandWindow expandinprogress;
boolean corner1complete;
void reset() {
expandinprogress = new ExpandWindow(-1,-1,0,0,0);
corner1complete = false;
}
Expand(){
corner1complete = false;
}
void mouseClicked(float x, float y){
if (!corner1complete){
expandinprogress.corner1x = x;
expandinprogress.corner1y = y;
corner1complete = true;
} else {
expandinprogress.corner2x = x;
expandinprogress.corner2y = y;
expandinprogress.speed = speed;
expandinprogress.millisInit = millis();
expandinprogress.saveExpandRegion();
expandwindows.add(expandinprogress);
this.reset();
}
}
}
class ExpandWindow {
float corner1x, corner1y, corner2x, corner2y, speed;
int timeElapsed, millisInit;
PImage expandRegion;
ExpandWindow(float corner1x, float corner1y, float corner2x, float corner2y, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.speed = speed;
}
float aspectRatio() {
return abs((corner2x - corner1x) / (corner2y - corner1y));
}
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
void saveExpandRegion() {
this.expandRegion = get(int(convertXCoord(corner1x)), int(convertYCoord(corner1y)),
int(convertXDistance(corner2x - corner1x)),int(convertYDistance(corner2y - corner1y)));
}
void draw() {
timeElapsed = millis() - millisInit;
if (convertYDistance(corner2y - corner1y) + speed * (timeElapsed / 1000) < convertYDistance(screenHeight)) {
noFill();
noStroke();
rectMode(CORNER);
rect(convertXCoord(corner1x), convertYCoord(corner1y),
convertXDistance(corner2x - corner1x), convertYDistance(corner2y - corner1y));
imageMode(CENTER);
image(expandRegion, convertXCoord(this.centerx()), convertYCoord(this.centery()),
convertXDistance(corner2x - corner1x) + speed * this.aspectRatio() * (timeElapsed / 1000),
convertYDistance(corner2y - corner1y) + speed * (timeElapsed / 1000));
}
}
}

View File

@ -30,7 +30,7 @@ class Line {
} }
ProjectorCommand drawCommand() { ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> { return (ProjectorApplet p) -> {
if (!visible) { if (!visible) {
//done drawing already //done drawing already
@ -66,7 +66,7 @@ class Line {
y2 = y; y2 = y;
visible = true; visible = true;
p.commandQueue.add(drawCommand()); p.commandQueue.add(makeProjectorCommand());
return true; return true;
} }
}; };

View File

@ -189,9 +189,7 @@ class Menu {
} }
void controlEvent(ControlEvent theEvent) { void controlEvent(ControlEvent theEvent) {
println(theEvent); //println(theEvent);
println(theEvent.getName());
println(theEvent.getLabel());
if (theEvent.isFrom(shapesList)) { if (theEvent.isFrom(shapesList)) {
switch((int) shapesList.getValue()) { switch((int) shapesList.getValue()) {
case 0: case 0:
@ -211,19 +209,15 @@ class Menu {
switch((int) animateList.getValue()) { switch((int) animateList.getValue()) {
case 0: case 0:
// shrink.reset(); // shrink.reset();
// drawtype = 's';
break; break;
case 1: case 1:
// expand.reset(); // expand.reset();
// drawtype = 'x';
break; break;
case 2: case 2:
// translate.reset(); // translate.reset();
// drawtype = 'm';
break; break;
case 3: case 3:
// rotate.reset(); // rotate.reset();
// drawtype = 'c';
break; break;
} }
} else if (theEvent.isFrom(presetsList)){ } else if (theEvent.isFrom(presetsList)){
@ -231,13 +225,26 @@ class Menu {
} else { } else {
switch (theEvent.getLabel()) { switch (theEvent.getLabel()) {
case "Commit": case "Commit":
try {
int rVal = Integer.parseInt(redField.getText()); int rVal = Integer.parseInt(redField.getText());
int gVal = Integer.parseInt(greenField.getText()); int gVal = Integer.parseInt(greenField.getText());
int bVal = Integer.parseInt(blueField.getText()); int bVal = Integer.parseInt(blueField.getText());
parent.penColor = parent.color(rVal, gVal, bVal); parent.penColor = parent.color(rVal, gVal, bVal);
} catch (NumberFormatException e) {
println("Ignored non-numeric color.");
}
try {
parent.penWidth = Integer.parseInt(penwidthField.getText()); parent.penWidth = Integer.parseInt(penwidthField.getText());
} catch (NumberFormatException e) {
println("Ignored bad pen width");
}
try {
parent.projectorApplet.setBgColor(Integer.parseInt(backgroundField.getText())); parent.projectorApplet.setBgColor(Integer.parseInt(backgroundField.getText()));
} catch (NumberFormatException e) {
println("Ignored bad background color.");
}
// parent.lagTime = Integer.parseInt(lagField.getText()); // parent.lagTime = Integer.parseInt(lagField.getText());
// parent.totalTime = Integer.parseInt(totaltimeField.getText()); // parent.totalTime = Integer.parseInt(totaltimeField.getText());
// parent.speed = Integer.parseInt(speedField.getText()); // parent.speed = Integer.parseInt(speedField.getText());

View File

@ -1,6 +1,5 @@
import processing.core.PApplet; import processing.core.PApplet;
import java.util.ArrayList;
import java.util.ArrayDeque;
class ProjectorApplet extends PApplet { class ProjectorApplet extends PApplet {
final int projectorScreenNumber = 2; final int projectorScreenNumber = 2;
@ -13,12 +12,12 @@ class ProjectorApplet extends PApplet {
EuglenaApplet parent; EuglenaApplet parent;
Calibrator calibrator; Calibrator calibrator;
ArrayDeque<ProjectorCommand> commandQueue; ArrayList<ProjectorCommand> commandQueue;
ProjectorApplet(EuglenaApplet parent) { ProjectorApplet(EuglenaApplet parent) {
this.parent = parent; this.parent = parent;
calibrator = new Calibrator(this); calibrator = new Calibrator(this);
commandQueue = new ArrayDeque<>(); commandQueue = new ArrayList<>();
} }
public void settings() { public void settings() {
@ -36,14 +35,29 @@ class ProjectorApplet extends PApplet {
public void draw() { public void draw() {
calibrator.draw(parent); calibrator.draw(parent);
while (!commandQueue.isEmpty()) { ArrayList<Integer> entriesToRemove = new ArrayList<>();
ProjectorCommand command = commandQueue.getFirst(); try {
if (command.run(this)) { for (int i = 0; i < commandQueue.size(); i++) {
commandQueue.removeFirst();
} else { boolean done = commandQueue.get(i).run(this);
break; if (done) {
entriesToRemove.add(i);
}
}
} catch (ProjectorCommandException e) {
// Do nothing
}
// Remove entries (have to do it in reverse order to preserve indices)
for (int i = entriesToRemove.size() - 1; i >= 0; i--) {
commandQueue.remove(i);
} }
} }
public void reset() {
commandQueue.clear();
this.clear();
} }
public void clear() { public void clear() {

View File

@ -1,3 +1,9 @@
public interface ProjectorCommand { public interface ProjectorCommand {
boolean run(ProjectorApplet p); boolean run(ProjectorApplet p) throws ProjectorCommandException;
}
class ProjectorCommandException extends Exception {
ProjectorCommandException(String message) {
super(message);
}
} }

View File

@ -30,7 +30,7 @@ class Rectangle {
this.corner1complete = true; this.corner1complete = true;
} }
ProjectorCommand drawCommand() { ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> { return (ProjectorApplet p) -> {
if (!visible) { if (!visible) {
//done drawing already //done drawing already
@ -66,7 +66,7 @@ class Rectangle {
corner2y = y; corner2y = y;
visible = true; visible = true;
p.commandQueue.add(drawCommand()); p.commandQueue.add(makeProjectorCommand());
return true; return true;
} }
}; };

76
src/Rotate.java Normal file
View File

@ -0,0 +1,76 @@
import processing.core.*;
import static processing.core.PApplet.*;
public class Rotate {
float centerx, centery, radius, speed;
int timeElapsed, millisInit;
PImage rotateRegion;
private boolean centercomplete;
Rotate(float speed) {
this.speed = speed;
this.centercomplete = false;
}
Rotate(float centerx, float centery, float radius, float speed) {
this.centerx = centerx;
this.centery = centery;
this.radius = radius;
this.speed = speed;
this.centercomplete = true;
}
void saveRotateRegion(ProjectorApplet p) {
this.rotateRegion = p.get(
(int) p.convertXCoord(centerx - radius),
(int) p.convertYCoord(centery - radius),
(int) p.convertXDistance(2*radius),
(int) p.convertYDistance(2*radius));
}
ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> {
timeElapsed = p.millis() - millisInit;
p.noFill();
p.noStroke();
p.rectMode(CENTER);
p.rect(p.convertXCoord(centerx), p.convertYCoord(centery),
p.convertXDistance(radius), p.convertYDistance(radius));
p.pushMatrix();
p.translate(p.convertXCoord(centerx), p.convertYCoord(centery));
p.rotate(radians(speed * timeElapsed/1000f));
p.imageMode(CENTER);
p.image(rotateRegion, 0, 0, p.convertXDistance(2*radius), p.convertYDistance(2*radius));
p.popMatrix();
return false;
};
}
ClickGetter makeClickGetter(ProjectorApplet p){
return (int x, int y) -> {
if (!centercomplete){
centerx = x;
centery = y;
centercomplete = true;
return false;
} else {
radius = sqrt(pow(x - centerx, 2) + pow(y - centery, 2));
millisInit = p.millis();
saveRotateRegion(p);
p.commandQueue.add(makeProjectorCommand());
return true;
}
};
}
}

View File

@ -1,68 +0,0 @@
class Rotate {
RotateWindow rotateinprogress;
boolean centercomplete;
void reset() {
rotateinprogress = new RotateWindow(-1,-1,0,0);
centercomplete = false;
}
Rotate(){
centercomplete = false;
}
void mouseClicked(float x, float y){
if (!centercomplete){
rotateinprogress.centerx = x;
rotateinprogress.centery = y;
centercomplete = true;
} else {
rotateinprogress.radius = sqrt(pow(x - rotateinprogress.centerx, 2) + pow(y - rotateinprogress.centery, 2));
rotateinprogress.speed = speed;
rotateinprogress.millisInit = millis();
rotateinprogress.saveRotateRegion();
rotatewindows.add(rotateinprogress);
this.reset();
}
}
}
class RotateWindow {
float centerx, centery, radius, speed;
int timeElapsed, millisInit;
PImage rotateRegion;
RotateWindow(float centerx, float centery, float radius, float speed) {
this.centerx = centerx;
this.centery = centery;
this.radius = radius;
this.speed = speed;
}
void saveRotateRegion() {
this.rotateRegion = get(int(convertXCoord(centerx - radius)), int(convertYCoord(centery - radius)),
int(convertXDistance(2*radius)),int(convertYDistance(2*radius)));
}
void draw() {
timeElapsed = millis() - millisInit;
noFill();
noStroke();
rectMode(CENTER);
rect(convertXCoord(centerx), convertYCoord(centery),
convertXDistance(radius), convertYDistance(radius));
pushMatrix();
translate(convertXCoord(centerx), convertYCoord(centery));
rotate(radians(speed*timeElapsed/1000));
imageMode(CENTER);
image(rotateRegion, 0, 0, convertXDistance(2*radius), convertYDistance(2*radius));
popMatrix();
}
}

90
src/Shrink.java Normal file
View File

@ -0,0 +1,90 @@
import processing.core.*;
import static processing.core.PApplet.*;
class Shrink {
float corner1x, corner1y, corner2x, corner2y, speed;
int timeElapsed, millisInit;
PImage shrinkRegion;
private boolean corner1complete;
Shrink(float speed) {
this.speed = speed;
this.corner1complete = false;
}
Shrink(float corner1x, float corner1y, float corner2x, float corner2y, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.speed = speed;
this.corner1complete = true;
}
float aspectRatio() {
return abs((corner2x-corner1x)/(corner2y-corner1y));
}
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
void saveShrinkRegion(ProjectorApplet p) {
this.shrinkRegion = p.get(
(int) p.convertXCoord(corner1x),
(int) p.convertYCoord(corner1y),
(int) abs(p.convertXDistance(corner2x-corner1x)),
(int) abs(p.convertYDistance(corner2y-corner1y)));
}
ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> {
timeElapsed = p.millis() - millisInit;
if (p.convertXDistance(corner2x-corner1x) - speed * aspectRatio() * (timeElapsed/1000f) < 25) {
return true;
}
p.noFill();
p.noStroke();
p.rectMode(CORNER);
p.rect(p.convertXCoord(corner1x), p.convertYCoord(corner1y),
p.convertXDistance(corner2x - corner1x), p.convertYDistance(corner2y - corner1y));
p.imageMode(CENTER);
p.image(shrinkRegion, p.convertXCoord(this.centerx()), p.convertYCoord(this.centery()),
p.convertXDistance(corner2x - corner1x) - speed * aspectRatio() * (timeElapsed / 1000f),
p.convertYDistance(corner2y - corner1y) - speed * (timeElapsed / 1000f));
return false;
};
}
ClickGetter makeClickGetter(ProjectorApplet p){
return (int x, int y) -> {
if (!corner1complete){
corner1x = x;
corner1y = y;
corner1complete = true;
return false;
} else {
corner2x = x;
corner2y = y;
millisInit = p.millis();
saveShrinkRegion(p);
p.commandQueue.add(makeProjectorCommand());
return true;
}
};
}
}

View File

@ -1,93 +0,0 @@
class Shrink {
ShrinkWindow shrinkinprogress;
boolean corner1complete;
void reset() {
shrinkinprogress = new ShrinkWindow(-1,-1,0,0,0);
corner1complete = false;
}
Shrink(){
corner1complete = false;
}
void mouseClicked(float x, float y){
if (!corner1complete){
shrinkinprogress.corner1x = x;
shrinkinprogress.corner1y = y;
corner1complete = true;
} else {
shrinkinprogress.corner2x = x;
shrinkinprogress.corner2y = y;
shrinkinprogress.speed = speed;
shrinkinprogress.millisInit = millis();
shrinkinprogress.saveShrinkRegion();
shrinkwindows.add(shrinkinprogress);
this.reset();
}
}
}
class ShrinkWindow {
float corner1x, corner1y, corner2x, corner2y, speed;
int timeElapsed, millisInit;
PImage shrinkRegion;
ShrinkWindow(float corner1x, float corner1y, float corner2x, float corner2y, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.speed = speed;
}
float aspectRatio() {
return abs((corner2x-corner1x)/(corner2y-corner1y));
}
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
void saveShrinkRegion() {
this.shrinkRegion = get(int(convertXCoord(corner1x)), int(convertYCoord(corner1y)),
abs(int(convertXDistance(corner2x-corner1x))), abs(int(convertYDistance(corner2y-corner1y))));
}
void draw(){
timeElapsed = millis()-millisInit;
if(convertXDistance(corner2x-corner1x) - speed * aspectRatio() * (timeElapsed/1000) > 25) {
noFill();
noStroke();
rectMode(CORNER);
rect(convertXCoord(corner1x), convertYCoord(corner1y),
convertXDistance(corner2x - corner1x), convertYDistance(corner2y - corner1y));
imageMode(CENTER);
image(shrinkRegion, convertXCoord(this.centerx()), convertYCoord(this.centery()),
convertXDistance(corner2x - corner1x) - speed * aspectRatio() * (timeElapsed / 1000),
convertYDistance(corner2y - corner1y) - speed * (timeElapsed / 1000));
}
//
// print(convertXDistance(corner2x-corner1x) - speed * aspectRatio() * (timeElapsed/1000));
// print("\n");
// print(timeElapsed);
// print("\n");
// print(aspectRatio);
// print("\n");
}
}

111
src/Translate.java Normal file
View File

@ -0,0 +1,111 @@
import processing.core.*;
import static processing.core.PApplet.*;
public class Translate {
float corner1x, corner1y, corner2x, corner2y, endpointx, endpointy, speed;
int timeElapsed, millisInit;
PImage translateRegion;
private boolean corner1complete, corner2complete;
Translate(float speed) {
this.speed = speed;
this.corner1complete = false;
this.corner2complete = false;
}
Translate(float corner1x, float corner1y, float corner2x, float corner2y,
float endpointx, float endpointy, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.endpointx = endpointx;
this.endpointy = endpointy;
this.speed = speed;
this.corner1complete = true;
this.corner2complete = true;
}
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
float theta() {
return (atan((endpointy-centery())/(endpointx-centerx())));
}
void saveTranslateRegion(ProjectorApplet p) {
this.translateRegion = p.get(
(int) p.convertXCoord(corner1x),
(int) p.convertYCoord(corner1y),
(int) abs(p.convertXDistance(corner2x-corner1x)),
(int) abs(p.convertYDistance(corner2y-corner1y)));
}
ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> {
timeElapsed = p.millis() - millisInit;
float spaceElapsed = timeElapsed * speed / 1000f;
if (spaceElapsed * cos(theta()) * p.calibrator.magx > endpointx - centerx()) {
return true;
}
p.noFill();
p.noStroke();
p.rectMode(CORNERS);
p.rect(p.convertXCoord(corner1x) + spaceElapsed * cos(theta()),
p.convertYCoord(corner1y) + spaceElapsed * sin(theta()),
p.convertXCoord(corner2x) + spaceElapsed * cos(theta()),
p.convertYCoord(corner2y) + spaceElapsed * sin(theta()));
p.imageMode(CENTER);
p.image(translateRegion,
p.convertXCoord(this.centerx()) + spaceElapsed * cos(theta()),
p.convertYCoord(this.centery()) + spaceElapsed * sin(theta()),
p.convertXDistance(corner2x - corner1x),
p.convertYDistance(corner2y - corner1y));
return false;
};
}
ClickGetter makeClickGetter(ProjectorApplet p){
return (int x, int y) -> {
if (!corner1complete){
corner1x = x;
corner1y = y;
corner1complete = true;
return false;
} else if (!corner2complete) {
corner2x = x;
corner2y = y;
corner2complete = true;
return false;
} else{
endpointx = x;
endpointy = y;
millisInit = p.millis();
saveTranslateRegion(p);
p.commandQueue.add(makeProjectorCommand());
return true;
}
};
}
}

View File

@ -1,99 +0,0 @@
class Translate {
TranslateWindow translateWindowinprogress;
boolean corner1complete, corner2complete;
void reset() {
translateWindowinprogress = new TranslateWindow(-1,-1,0,0,0,0,0);
corner1complete = false;
corner2complete = false;
}
Translate(){
corner1complete = false;
corner2complete = false;
}
void mouseClicked(float x, float y){
if (!corner1complete){
translateWindowinprogress.corner1x = x;
translateWindowinprogress.corner1y = y;
corner1complete = true;
} else if (!corner2complete) {
translateWindowinprogress.corner2x = x;
translateWindowinprogress.corner2y = y;
corner2complete = true;
} else{
translateWindowinprogress.endpointx = x;
translateWindowinprogress.endpointy = y;
translateWindowinprogress.speed = speed;
translateWindowinprogress.millisInit = millis();
translateWindowinprogress.saveTranslateRegion();
translatewindows.add(translateWindowinprogress);
this.reset();
}
}
}
class TranslateWindow {
float corner1x, corner1y, corner2x, corner2y, endpointx, endpointy, speed;
int timeElapsed, millisInit;
PImage translateRegion;
TranslateWindow(float corner1x, float corner1y, float corner2x, float corner2y,
float endpointx, float endpointy, float speed) {
this.corner1x = corner1x;
this.corner1y = corner1y;
this.corner2x = corner2x;
this.corner2y = corner2y;
this.endpointx = endpointx;
this.endpointy = endpointy;
this.speed = speed;
}
// float aspectRatio() {
// return abs((corner2x - corner1x) / (corner2y - corner1y));
// }
float centerx() {
return (corner1x + corner2x) / 2;
}
float centery() {
return (corner1y + corner2y) / 2;
}
float theta() {
return (atan((endpointy-centery())/(endpointx-centerx())));
}
void saveTranslateRegion() {
this.translateRegion = get(int(convertXCoord(corner1x)), int(convertYCoord(corner1y)),
int(abs(convertXDistance(corner2x - corner1x))),int(abs(convertYDistance(corner2y - corner1y))));
}
void draw() {
timeElapsed = millis() - millisInit;
if (timeElapsed*speed/1000*cos(theta())*calibrator.magx <= endpointx - centerx()) {
noFill();
noStroke();
rectMode(CORNERS);
rect(convertXCoord(corner1x) + timeElapsed*speed/1000*cos(theta()),
convertYCoord(corner1y) + timeElapsed*speed/1000*sin(theta()),
convertXCoord(corner2x) + timeElapsed*speed/1000*cos(theta()),
convertYCoord(corner2y) + timeElapsed*speed/1000*sin(theta()));
imageMode(CENTER);
image(translateRegion, convertXCoord(this.centerx()) + timeElapsed*speed/1000*cos(theta()),
convertYCoord(this.centery()) + timeElapsed*speed/1000*sin(theta()),
convertXDistance(corner2x - corner1x), convertYDistance(corner2y - corner1y));
}
}
}

View File

@ -35,7 +35,7 @@ class Triangle {
this.point2complete = true; this.point2complete = true;
} }
ProjectorCommand drawCommand() { ProjectorCommand makeProjectorCommand() {
return (ProjectorApplet p) -> { return (ProjectorApplet p) -> {
if (!visible) { if (!visible) {
//done drawing already //done drawing already
@ -78,7 +78,7 @@ class Triangle {
point3y = y; point3y = y;
visible = true; visible = true;
p.commandQueue.add(drawCommand()); p.commandQueue.add(makeProjectorCommand());
return true; return true;
} }
}; };