Mtg 4/26: Thu-21-Jan-2021

Outline for Today

Media

No Media

Transcript

Binary Code

Next Meeting

    Decode unicode - the world's writing systems

UTF 8

Zoom Audio Transcript

  • Everyone How's everyone doing today. Before So just noticing I get some chat messages going here. So, This came up in the ad class just before That it seemed like I can say Participants can chat with everyone publicly, but that doesn't mean that they can't that people can send me direct messages.
  • So,
  • If I see somebody sending me a direct message. I'm going to just tell you to stop. So, Just because I think that if you're going to have a conversation. You can you want to ask you something during class, you can ask, so everybody can see Anyway, So just be mindful. That you don't send me direct messages. Okay. So I have attended set up today. See where that is. Here, I'm gonna share my screen and Become like a student I can't do that yet. password that you need. Meeting. Going to Let me share the screen. Okay, so if you go to attend. If he has the hamburger menu open on the left and you can just go to attendances And I have one set up for today. And then you can say submit attendance. And then this is where you add the password which I'm going to give you Presence. Makes sense. Let's see now. Somebody bring me lunch. Anyway, So people ask me about the password as soon as it got into the meeting. So don't do that please So I didn't mean any I didn't Mean to say there's anything wrong with it. They're just Saying that it was nice to see those all So we'll do the password at some point during the meetings. And then Then you can record your attendance and Then we'll go from there. So that'll be part of your Participation marks. So there are other things you can do to do participate get participation. But I just wanted to To go through and Do this for Sure it's clear what's required So when you log in. You have four choices. I think presently Excused or absent. So it's making a comment about how you wouldn't necessarily Login to make yourself record yourself is absent. But I guess that's more of my option to Anyway, So there we go. So I did actually put this up yesterday the syllabus, but here it is on the link and your courses. Mistakes. Let me know when these links should work. And the document. The dates are correct. Now, And the labs are correct. Okay, so this Is a PDF version of the syllabus. Thinking about ways to organize Before With some clarity. And so I was experimenting with this idea of using the summary is the outline for everything. But I realized that's confusing in terms of the plan for today. So what I'm going to do is move Instead of including things for For next meeting here, which I did. This case. I'll put the next meeting stuff into The plan. And I may forgo these separate files. It's just seems like a little extra step. It's Not going as smoothly as I Hoped So if you want to give me suggestions about Doing this in a In an effective way for you. I'd certainly welcome them. In terms of The generative design. Reference that I mentioned. Sketches organized a few different color and shape. Click on particular sketch So you can see when you Enter the Put the cursor into the Into the sketch then enter in. You're getting different colors. Based on the Cursor to reappear. So I wanted to say that all these things are available in the p five JS editor. So we can open Okay, so let me just go through things. So first of all, a question. Does anyone have you even looked at the FIFA JS editor. Anyone created an account. Look at that for a second. Okay, so you can either do your own Username Or you can do one that's based on you can You can log in as GitHub, or Google or do your own username email. The neat thing. About it is it'll give you A new name. For a sketch that you create. Unless you want to change it to something comprehensible. Where you can spend a few minutes thinking about teen albacore or So, Inspiration. setup function. And this is done. These are the things that are done once At the beginning before everything else. And then So, Our first setup is to do a create a canvas. It's 400 400 And things in the drop function. Those happen each Each time it's refresh so You can think of the draft function is being done every time. So we do the draft function once and then we go through and start again. So, so it's looping Okay, so let's see what this first sketch looks like. Let's try To make this Color or the background color change. So you can see that I get a message as I'm typing. Because I have a lot of refresh on Here so it's it's trying to reinterpret everything they type it in. You see that console. Below here. So it's just as well. It's an incomplete line. So let's see. So now I've introduced a variable. So in the way to declare it is to say last So it's fairly forgiving, so you can also say VR. VR. That is more It's a more recent version of JavaScript. Or it's actually more particularly, it's called ECMO script. Stands for European computer. Manufacturers Association. How many people knew that Anyone familiar with. Does that make sense. This program makes sense so far. Okay, so we have the idea of a variable is We're creating a name a name for location and memory. And we're assigning zero to it. So where can you find documentation. All over. Here. include a reference Get started. What's nice about The reference here. You can copy things and then where you get examples. Not sure where that it was that is that you can edit the code in the example. Let me just change the background color here. You can work with examples inside the documentation. As well. Okay, and then it can be set. For the original one. Doing anything You don't have a suggestion for me. 20 of us today. See more reason to use microphones. Yeah. initialization code into the loop reset to zero, every time. declared outside. So it's a global variable. Give you created on elegance of JavaScript code. So by putting the decoration here, then it's successful to every Elsewhere. So if it's inside the function The function. Incoming Background variable by one A bit longer way. Make sure that was all is between black and white. There we go. So there were returned to block and go to white and then black to white and black to white. Never know what that percent simple as used for Yeah. It's the modular modulus Remainder So what's the number that we We want to Yeah. So that's the maximum value be one. Sort of redo to 56 Makes sense in terms of Her sketch so Let's see, what, what would we do if We want to make it grow from white to black for me from black to white and then white to black. Stop. We want to switch Okay. Let's make a new variable. Other languages. Do one equal science and US assignments are assigning value to the variable. If you want to test whether it's as a certain value. Then we need to do to signs actually JavaScript, you can do three signs as well to give a more precise comparison. Has a value of one. Then we want to go up with incremental until we get
  • I thought we were trying to make it go from black to white and then back from white to black not have it reset at Black again and then go to white.
  • Yeah, so we're not done with our solution yet.
  • Okay.
  • So let's take the assignment up here. Condition here. Test for the top The highest value, we can have in this variable. You're wondering why is it What's your question.
  • My question was why we can take the mix all my you to 55
  • So, We're starting out with Zero and then we're doing a modular
  • Oh, yeah.
  • Okay.
  • Yeah, thank you.
  • You're welcome. So how many bits do we need to store 256 alternatives. Or how many bytes. One bite. Right. Had eight cards we could guess numbers between zero to 55 But then it's going to be harder to keep track of which cards for Court cards is already to keep track of but Lot more difficult. Anyway, so we're testing. When the background color value. Background intensity is variable. The zero There. We're going to say we're going to go up from there. And if He could have to 35 then we're gonna go back down. So what I'm doing here is The values I could do Boolean true and false that I Am used to also doing zeros and ones.
  • Like
  • Like one free true And False. Meeting. Of a comment. Any questions or comments. You'd written 32 OK, so The relationship invites and Eight fits in a bite. 32 bites. That would be 200 Okay.
  • Does

Zoom Chat Transcript

  • good afternoon!
  • good afternoon
  • good afternoon prof.
  • good after noon
  • Hello professor
  • Good, how are you?
  • alright, how about yourself?
  • great
  • Great thanks. Yourself?
  • I am good, I had a nice swim this morning
  • Excellent, yourself ?
  • what's the password
  • hj2zsa
  • Worked
  • Thanks mom
  • I have class from 10 until 2:15 with no breaks so she brought me food
  • shoutout to Kathy
  • No
  • not yet
  • no
  • no
  • no
  • no
  • not yet.
  • Not yet
  • done.
  • yess
  • yes
  • nope
  • JS yes not ECMA
  • yes some what
  • only c++ and some assbly
  • assembly
  • yes
  • where can I find documentation for the functions?
  • oh I see, thank you
  • It's getting set back to 0 at the start of the frame.
  • Why not just declare bgv and set it to zero in the same line? Or no particular reason for that?
  • remainder
  • mod
  • 255
  • white to black huh...
  • A bool variable that you use in an if statement saying to increase or decrease. Gets flipped at 256 or 0.
  • yeah that's an idea
  • 255?
  • 256
  • I am wondering why is it !
  • 8
  • 32
  • your question on how many bytes
  • 1 byte
  • ok thanks
  • how can we get other colors than black and white?
  • Not yet
  • yes
  • yup
  • yes
  • Yes
  • use hexadecimal code for all the colors
  • #ffffff for the color white
  • Yup!
  • I have
  • Yes
  • yes
  • i’ve
  • yup
  • yes
  • yes
  • yep
  • It would go back to greyscale
  • Good Day Sir!
  • Have a nice weekend!
  • thank you sir
  • Thanks, you too!
  • have a good weekend! thank you!
  • see ya !!
  • you too.
  • Thanks you too
  • thank you! have a great day

p5js

Responses

Wiki

Link to the UR Courses wiki page for this meeting