Examples and other materials from lectures


Shape programs, from C to C++ to Java 
  1. Encapsulation
  2. shape1
  3. shape2
  4. shape3
  5. shape4
  6. shape5
  7. shape6 (other files are same as before)
  8. shape7
  9. shape8
  10. shape9
  11. Lab: Java Setup
  12. shape10
Java GUI programs 
  1. Lab: SimpleButton0
  2. Window Systems
  3. SimpleButton1
  4. SimpleButton2 (other files are same as before)
  5. SimpleButton3 (other files are same as before)
  6. Lab: Modify SimpleButton3
  7. Scroll1 (other files are same as before)
  8. Scroll2 (other files are same as before)
  9. AWT class hierarchy
  10. Widgets
  11. Draw1 (the WRONG way)
  12. Draw2
  13. Java graphics commands
  14. More on Java graphics commands
  15. Lab: Java drawing
  16. Draw3 (other files are same as before)
  17. Lab: Java mouse and drawing
  18. Draw4 (other files are same as before)
  19. Different kinds of widgets
  20. Layout1
  21. Layout2 (for reference; optional)
  22. (Movie frames)
  23. Timeout1
  24. Timeout2 (other files are same as before)
  25. Lab: Simple animation
  26. Lab: Installing Eclipse and Windowbuilder
  27. SimpleButton3 using Eclipse IDE
  28. Widgets using Eclipse IDE
  29. Menus (using Eclipse)
Button Programs, GUI with OOP 
  1. Button1
  2. Three Hierarchies for Button3
  3. Button3 (no Button2)
  4. Hierarchies for Button4
  5. Button4 (other files are same as before)
  6. Design for Button5 Program
  7. Button5
  8. Lab: Pan and zoom
OO Design 
  1. Overall steps for object-oriented design
  2. Abstraction 1
  3. Abstraction 2
  4. (UML diagram examples)
  5. UML class diagrams 1
  6. UML class diagrams 2
  7. UML class diagrams 3
  8. UML class diagrams 4
  9. UML class diagrams 5
  10. UML class diagrams 6
  11. UML class diagrams 7
  12. (CRC cards)
  13. (CRC examples)
  14. Button5 UML base
  15. Button5 UML collab
  16. Button5 UML aggreg
  17. Button5 UML inherit
  18. Button5 UML all
  19. UML sequence diagrams 1
  20. UML sequence diagrams 2
  21. UML sequence diagrams 3
  22. UML state diagrams 1
  23. UML state diagrams 2
  24. UML state diagrams 3
Incdec 
  1. Incdec1
  2. Incdec2
  3. Incdec3
  4. Incdec4
Javascript and Browser Interfaces 
  1. SimpleButton1 (plain HTML)
  2. SimpleButton2 (Javascript)
  3. Draw
  4. SimpleButton3
  5. Lab: User interface in Javascript
  6. SimpleButton3o (for reference)
  7. Timeout1
  8. Timeout2
  9. Bounce
  10. Button5c
  11. Incdec1
  12. Incdec2
  13. Ajax1
  14. Ajax2
  15. Paint
  16. Breakout game
  17. Lab: Breakout game
  18. Breakout lab sample solution
Non-WIMP Interaction Styles 
  1. Webgazer: Web page (by Jeff Huang, Brown Univ.)
  2. Webgazer: Usage example code
  3. Webgazer: Simple skeleton program code
  4. Trackingjs: Web page
  5. Trackingjs: Head tracking example code
  6. Trackingjs: Color tracking example code
  7. Affectiva: Web page
  8. Affectiva: Demo
  9. Affectiva: Demo code
  10. Affectiva: UI example code
  11. Gest.js: Web page
  12. Gest.js: Github
  13. Gest.js: Demo
  14. Gest.js: Example code
  15. JSHG, another hand gesture system: Web page
  16. JSHG: Demo
  17. One dollar recognizer: Web page
  18. One dollar recognizer: Example code
  19. Topcodes: Web page
  20. Topcodes: Video
  21. Topcodes: Code for algorithm
  22. Web speech API: Web page
  23. Web speech API: Demo
  24. Web speech API code: Example code
3D Graphics in Three.js 
  1. box
  2. scene
  3. lights
  4. robot1
  5. robot2
  6. (Virtual Reality)
  7. (HMD picture)
  8. Stereo example 1 (for reference; optional)
  9. Stereo example 2 (for reference; optional)
  10. load
  11. house
  12. (More 3D graphics techniques)
Additional Topics in Java 
  1. Rawbutton
  2. Threads
  3. Threads1
  4. Threads2 (other files are same as before)
  5. Threads3 (other files are same as before)
Object-oriented programming in Python 
  1. Interactive python examples
  2. shape6
  3. shape7
  4. Code for first python lab
  5. Lab: First python lab
  6. First python lab sample solution
GUI programming in Python 
  1. simplebutton2
  2. simplebutton3
  3. draw3
  4. button5 (for reference; optional)
  5. Code for second python lab
  6. Lab: Second python lab
  7. Second python lab sample solution
  8. Objective C (for reference: Optional)