Programming Games Show your simple video. More video examples. Audio. Classwork/Homework: Produce more complex video program.

Slides:



Advertisements
Similar presentations
Video Game Design Lesson 1. Game Designer Person involved in the development of a video game Person involved in the development of a video game Usually.
Advertisements

HOW TO BUILD A WEBSITE In 5 easy steps. Overview ◦ Decide on the Website’s Purpose ◦ Sketch a Rough Draft ◦ Create Content ◦ Code and Assemble Assets.
AUTOMATIC ORGANIZING AND FORMATTING FOR LECTURE NOTES SHIQING (LICIA) HE ADIVISOR: PROF.KRISTINA STRIEGNITZ SPRING 2014 STRUCTURING THE UNSTRUCTURED NOTE:
HTML and Web Page Design Presented by Frank H. Osborne, Ph. D. © 2005 ID 2950 Technology and the Young Child.
Part or all of this lesson was adapted from the University of Washington’s “Web Design & Development I” Course materials.
GAME:IT Junior Bouncing Ball Objectives: Create Sprites Create Sounds Create Objects Create Room Program simple game.
Comparing Python and Visual Basic
A Prezi presentation is like creating a mind map. It is created on a blank canvas and you decide where the information goes on this canvas.
Chapter 11 Adding Media and Interactivity. Flash is a software program that allows you to create low-bandwidth, high-quality animations and interactive.
Programming Games Computer science big ideas. Computer Science jargon. Show virtual dog Homework: [Catch up: dice game, credit card or other form.] Plan.
Programming games Flash drawing trick(s). Rock paper scissors. Classwork: Complete rock paper scissors.
DHTML. What is DHTML?  DHTML is the combination of several built-in browser features in fourth generation browsers that enable a web page to be more.
Create Interfaces College exercise. Continue HTML5: HTML5 logo, drawing images. Coin toss. Homework: acquire video & audio.
Programming Games Recap on Google Maps. Creating elements. Dynamic creation of elements (multiple video elements). Geolocation. Classwork/Homework: Catch-up.
Programming Games Review for midterm. Work session. Homework: Prepare for midterm.
Programming games Examples: Audio example. Google Maps api. Classwork: show more complex video. Classwork/Homework: Find place (lat and long) for basic.
Programming Games Basic HTML5 audio example. Catch-up. Work on basic video. Homework: Complete basic video.
Chapter 2 Developing a Web Page. A web page is composed of two distinct sections: –The head content –The body Creating Head Content and Setting Page Properties.
Programming Games Show your cannonball. HTML5 video. Miro. Classwork/Homework: Acquire video, convert to multiple formats, and produce simple (just html)
Locally Edited Animations We will need 3 files to help get us started at
Rujchai Ung-arunyawee Department of Computer Engineering Khon Kaen University.
Javascript: More features B. Ramamurthy 7/4/2014B. Ramamurthy, CSE651C1.
2.02 Develop Computer Animations Review By: Adam Garcia,Christian Brown, Richard Williams, Tyler Borden.
Programming Games Google Map API examples. CSS. Classwork/homework: Catch up. Upload work. Show your [more] complex Google Maps API example. Plan your.
Programming Games Show project. Refresher on coordinates. Scaling, translation. HTML5 logo. Refresher on animation. Bouncing ball. Homework: Do your own.
Programming games Flash drawing trick(s). Past due: Your completion of rock-paper-scissors) Classwork: Bouncing ball: read tutorial. Start coding.
Programming games Reflection Bouncing things, Memory Server-side: Survey. ActionScript 2 examples. Homework: Finish Video or Audio. Post proposal for your.
Programming games Examples. Classwork: work and show something of your final project. Homework: (finish…)
Programming games Show your version of Bo the dog. Start cannonball Preview: video, audio work session (cannonball) Homework: Cannonball with ball in a.
Lab 12: Other Languages User Interface Lab: GUI Lab Nov. 12 th, 2013.
Programming Games Preview Video & Audio. Work on cannonball. Homework: finish cannonball!
Term 2, 2011 Week 1. CONTENTS Problem-solving methodology Programming and scripting languages – Programming languages Programming languages – Scripting.
Creating User Interfaces Recap HTML/HTML5 JavaScript features Homework: keep working on user observation studies. Review JavaScript.
Introduction to Flash Animation CS 318. Topics Introduction to Flash and animation The Flash development environment Creating Flash animations  Layers.
Programming Games Reprise on drawing on canvas. Jargon (concepts): objects. Demonstrate slingshot. Mouse events. Work on your cannonball. Homework: Finish.
Programming Games [Show Google Maps project.] Demonstrate more examples. Classwork/Homework: Decide on final project. Post proposal to moodle.
Intro to Multimedia Unit 1.
Programming games Problems. Schedule Various examples. Homework: rps, bo (don't go back to do this), cannonball, Video or Audio should be complete. Now.
Reading Flash. Training target: Read the following reading materials and use the reading skills mentioned in the passages above. You may also choose some.
Programming games Context of what we are doing. Drawing on canvas. Homework: [Complete coin toss examples.] Do your own drawings. Upload files to website.
Programming Games Logic. Slide show. Range input. Storage. Datatypes. Binary numbers. Homework: Catch up. This includes uploading projects to your server.
Programming games Cannonball due. Drawing & printing example. Acquiring video or sound Homework: Catch up: complete projects (rps, Bo, cb). Start video.
Creating User Interfaces HTML5 video & audio. Role of video and audio. Homework: Complete your own [small/simple] HTML5 video and audio projects.
Chapter 11 Adding Media and Interactivity. Chapter 11 Lessons Introduction 1.Add and modify Flash objects 2.Add rollover images 3.Add behaviors 4.Add.
Computer Science I Share plans for virtual something. Text. Show my virtual dog. Classwork: Plans for your virtual something. Homework: start implementation.
JavaScript 101 Introduction to Programming. Topics What is programming? The common elements found in most programming languages Introduction to JavaScript.
Learning Aim B.  In this section, you will consider the resources necessary for designing your website.  You will also think about any constraints that.
Computer Science I More class examples. Paths. Jigsaw. Tolerance. Classwork/homework: Your class project. Post proposal for midterm project.
Time to upload Virtual something.
Creating User Interfaces VoiceXML. Examples. Classwork/Homework: Make proposal and start work on your VoiceXML project.
ICT/COMPUTING RULES Only use software allowed by the teacher
Creating User Interfaces Reprise on guest speaker. Usability checklists. Reprise on user- centered. Semantic tags. Responsive design. Classwork/homework:
Introduction of Presented by Neetu sharma MCA (8 th trim)
丁建文 國立高雄應用科大資管系副教授 兼任計網中心軟體發展組組長 跨平台行動應用軟體開發技術 : HTML5 & Mobile JavaScript Framework 暨南大學.
Boxes. boxes- learning targets o I will be able to display buttons (boxes) o I will be able to organize boxes o I will be able to create an animation.
Game Maker Tutorials Introduction Clickball IntroductionClickball Where is it? Shooting Where is it?Shooting.
Programming games Show work on site. Work on slide show. Timed event for bouncing ball. Homework: [Finish slide show and upload to site.] Acquire a short.
JQuery Fundamentals Introduction Tutorial Videos
DHTML.
Introduction to HTML5.
Building a Custom Video Player
Programming Games Computer science big ideas and Computer Science jargon: review of things we have used in examples. Show virtual dog Homework: [Catch.
Objective Understand web-based digital media production methods, software, and hardware. Course Weight : 10%
Scratch Programming Brian Cain.
Programming games Classes and objects (used for Jigsaw, Bouncing stuff, other projects) Homework: Complete cannonball. Video or Audio. Your own project.
Catchup. Work on project.
Creating User Interfaces
Programming Games Reprise on drawing on canvas. Jargon (concepts): objects. Demonstrate slingshot. Mouse events. Work on animation project. Homework: Finish.
Show your animation project. HTML5 video. Miro.
Presentation transcript:

Programming Games Show your simple video. More video examples. Audio. Classwork/Homework: Produce more complex video program.

Bouncing video Bouncing video element: html5/videobounceE.html html5/videobounceE.html Draws mask on canvas –Need to make sure canvas is on top. –Alternative is to modify video element using CSS.

Audio situation similar to video: no one format recognized by all browsers. –mp3 and ogg

Simple audio Plus an image html5/simpleaudio.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/simpleaudio.html

rock paper scissors (with audio) animation (setInterval), addEventListener for click, calculations to determine which throw, audio object html5/rockpaperscissorssounds.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/rockpaperscissorssounds.html

My thinking “the computer’s” turn to emerge from screen –Implement by making an image get bigger and bigger, use setInterval for the animation Play sound corresponding to tie, or paper wafting over rock, or rock breaking scissors, or scissors cutting paper

But… Problem: sound played and score computed before computer move fully emerged! Solution: keep checking on size variable (a state variable) and when it is big enough –Stop animation –Play sound

Put audio elements in body In init function: musicelements = document.getElementsByTagName(" audio"); In other code, determine which one: musicelements[musicch].play();

Parallel Structures “poor man’s database” Correspondence between choices and audio elements. The beats and musicch arrays are organized by computer move and then player move –If variable compch is computer move and i is player move result = beats[compch][i];

Examine code html5/rockpaperscissorssounds.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/rockpaperscissorssounds.html

Other Bouncing ball video html5/videobounce.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/videobounce.html Draws a frame from the video on the canvas Draws mask on canvas

jigsaw html5/jigsaw/jigsawdance.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/jigsaw/jigsawdance.html Works on iPhone and iPad –Older iOS required user to click to start video. Why do you think Apple did that? –Newer iOS does not require it. Works on Android

Critical requirements for jigsaw Acquire video clip Acquire first frame as image break up into pieces and record positions of pieces –Program needs to "know" the proper position. –NOTE: checking is done using a tolerance value. Program set up of event handling for mouse dragging AND for touch events Program moving (dragging) pieces around –does not use the new drag and drop features. Uses mouse down, mouse move, and mouse up and touch equivalents. Program checking if jigsaw is (close enough) complete Program playing of video

Note on checking in jigsaw “Close enough”, aka tolerance, aka margin of error, etc. is typical of games and other applications. We cannot expect players/users to position pieces precisely. –Precision can be factor defining level of game. Note: my jigsaw does allow completed puzzle to be anywhere in the window.

Execution time … when the document has been loaded and any JavaScript in the script element is running. Development time: when you are creating the program. Note: typically, the HTML document, including everything in the body element is created by you during development time and built when the document is loaded. It is possible to create html elements entirely by coding.

Jigsaw puzzle pieces Each piece is HTML markup created dynamically (during execution time). s = document.createElement('piece'); s.innerHTML = (" "); document.body.appendChild(s); thingelem = document.getElementById(uniqueid); x = piecesx[i] +100; y = piecesy[i] + 100; thingelem.style.top = String(y)+"px"; thingelem.style.left = String(x)+"px";

Origami directions html5/origamifish.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/origamifish.html Each of the steps is a function. Some functions draw on the canvas; two of the functions play video.

Aside I made decision on when to use –line drawing –Photograph –Video Gave up consistency for … better instruction What do you think?

Collage example Example manipulates video by extracting frames and drawing each on canvas over and over… html5/collagebase.htmlhttp://faculty.purchase.edu/jeanine.meyer/ html5/collagebase.html Note use of object-oriented programming

Other videos Re-positions (and keeps re-positioning) a video element along a path 5/movingpictures.html Plays sections of a video clip ml5/booktrip1.html ml5/booktrip1.html

Preview Next topic is Google Maps API –Bring Google Maps functionality into YOUR program. –The Application Programming Interface is a set of objects that you/we can use, including map, marker, latlng, others. Note: I will show an example using Maps and video and audio.

Pop quiz Go online and find out how to play a video with no sound and play audio with sound. Write the answer AND the website(s) you used.

Classwork / homework More complex video example Consider other posted examples –Reward for play Will show Google Maps and video Ask me for others! Enjoy the break!