Skip to content

Instantly share code, notes, and snippets.

View maximveksler's full-sized avatar
Wow

Maxim Veksler maximveksler

Wow
  • Tel Aviv, Israel
  • 06:14 (UTC +03:00)
  • X @mvxlr
View GitHub Profile
@maximveksler
maximveksler / Lecture 14. UIApplication, Network Activity Indicator, and Maps.txt
Created January 25, 2014 18:21
Captions for Stanford CS193p Developing Applications for iOS Fall 2013-14, Lecture 14. UIApplication, Network Activity Indicator, and Maps. For more info visit http://maximveksler.github.io/CS193p/
00:00 [ Music ]
00:04 >> Stanford University.
00:08 >> Welcome to the lecture 14 of CS193P for Fall of 2013 and 14.
00:16 Today I'm going to talk a little bit about miscellaneous topics, UI application and network activity indicator, and then I'm going to follow up a little bit on the demo we did last time, then I'm going to continue that demo, and we're going to take Photo Mania that we built last week and we're going to make it work on the iPad, and we're going to add a popover segue to it, because I talked about popovers a couple weeks ago, but I never showed you how to do it, and you know, all this stuff if I just tell you about it, it's really not real probably for you until I show you how to do it, so we'll do a popover.
00:48 And then we're going to dive into maps, so I'll be doing the lecture today on maps.
00:53 Hopefully, I'll get all the way through it.
00:55 And then on Wednesday, I will do a demo with the maps, and also then on Wednesday, I will demo some more segues, especially the embed segue.
@maximveksler
maximveksler / Lecture 15. MapKit and Embed Segue.txt
Created January 25, 2014 18:22
Captions for Stanford CS193p Developing Applications for iOS Fall 2013-14, Lecture 15. MapKit and Embed Segue. For more info visit http://maximveksler.github.io/CS193p/
00:00 [ Music ]
00:05 >> Stanford University.
00:09 >> Okay. Well, welcome to lecture 15 of CS193p for fall of 2013/14.
00:15 And our primary topic today is going to be the map kit, which is kind of the UI on what we talked about on Monday.
00:22 As part of that, though, especially in the demonstration that I do, I'm going to show you two things about SegwayÕs that are pretty important.
00:27 One is how to fire off a segue from code.
00:30 So far all the time that we've made a segue go, we just control, dragged from something in a storyboard to another storyboard, and then we clicked on that something.
00:38 It would segue, so now we're going to able to fire off a segue from in code.
00:42 And then I'm also going to teach you a new kind of segue today, which is the embed segue, and I'm going to demo that, as well, in a big demo that shows you all the map stuff and manual segue and the embedded segue.
00:53 Okay? So that's what's on tap for today.
@maximveksler
maximveksler / Lecture 16. Modal Segues, Text Fields, Alerts, and Action Sheets.txt
Created January 25, 2014 18:23
Captions for Stanford CS193p Developing Applications for iOS Fall 2013-14, Lecture 16. Modal Segues, Text Fields, Alerts, and Action Sheets. For more info visit http://maximveksler.github.io/CS193p/
00:00 [ Music ]
00:05 >> Stanford University.
00:07 >> Okay, well welcome to lecture 16 of Stanford CS193P fall of 2013-14.
00:15 So today we are going to talk about the last of the segues, which is modal segues and their kind of related segue which is unwinding segues.
00:27 Okay these can be a little, modal segue's really easy.
00:31 The unwinding, you know, can be a little confusing and so hopefully both the combination of the slides and the demo will get you there.
00:39 But it's an important one to understand, these unwinding segues.
00:43 Also, briefly we're going to talk about text fields which we haven't covered yet and also alert and action [inaudible] and then I'm going to do this demo.
00:51 It says camera time permitting, but we will definitely not have time for that.
00:54 That's what we'll start off on Wednesday with.
@maximveksler
maximveksler / Lecture 17. Camera, Core Motion, Application Lifecycle.txt
Created January 25, 2014 18:24
Captions for Stanford CS193p Developing Applications for iOS Fall 2013-14, Lecture 17. Camera, Core Motion, Application Lifecycle. For more info visit http://maximveksler.github.io/CS193p/
00:00 [ Music ]
00:05 >> Announcer: Stanford University.
00:07 >> Alright, well welcome to lecture 17 of CS193P, Fall 2013/14.
00:14 And today I'm going to spend just a couple minutes typing up some loose ends from the demo we had on Monday, and then I'm going to talk about taking pictures with the camera.
00:24 And then we'll do a demo about that.
00:28 And that's basically PhotoMania, what we kind of set this all up for in our last demo.
00:33 Then we'll talk about core motion, which is the accelerometer and the gyro and all that business, and I'll have a demo of that.
00:40 And if time permitting at the end here, we'll talk a little bit about the application life cycle.
00:45 We talked about the view controller life cycle where it appears and disappears and all those things, well the application kind of, you know, you come into the foreground, you run, then you go away, then you go the background, you come back, so there's kind of a life cycle there too, which we can talk about briefly, and I could even de
@maximveksler
maximveksler / Lecture 18. Localization, Adding UI to Settings.txt
Created January 25, 2014 18:25
Captions for Stanford CS193p Developing Applications for iOS Fall 2013-14, Lecture 18. Localization, Adding UI to Settings. For more info visit http://maximveksler.github.io/CS193p/
00:00 [ Music ]
00:05 >> Stanford University.
00:07 >> Okay. Well, welcome to lecture number 18 of CS193P, fall 2013/14.
00:15 Before I talk about what I'm going to talk about today, let's talk a little bit about what's coming up because we're right at the end of the quarter here.
00:22 So on Wednesday -- next lecture -- we are going to have this alternate final presentation day.
00:28 And a few of you have already said that you wanted to do that.
00:32 And really, the only thing you need to do to sign up to do that if you want to use this Wednesday as opposed to the following Thursday normal final presentation time to do your presentation, is to submit the Keynote slides, okay, by tomorrow at noon.
00:48 That's very important.
00:49 If I don't see your slides by tomorrow at noon, then you're basically not going to be presenting on Wednesday.
00:52 And then you'll be forced to present next Thursday.
@maximveksler
maximveksler / FuckingAVFoundation.m
Created February 25, 2014 23:36
Fucking AV Foundation code with audio and video mixing
- (void)buildTransitionCompositionAUDIO:(AVMutableComposition *)composition andVideoComposition:(AVMutableVideoComposition *)videoComposition andAudioMix:(AVMutableAudioMix *)audioMix
{
CMTime nextClipStartTime = kCMTimeZero;
// Add two video tracks and two audio tracks.
AVMutableCompositionTrack *compositionVideoTracks[2];
AVMutableCompositionTrack *compositionAudioTracks[2];
compositionVideoTracks[0] = [composition addMutableTrackWithMediaType:AVMediaTypeVideo preferredTrackID:kCMPersistentTrackID_Invalid];
compositionVideoTracks[1] = [composition addMutableTrackWithMediaType:AVMediaTypeVideo preferredTrackID:kCMPersistentTrackID_Invalid];
@property (nonatomic) NSInteger *playPosition;
- (NSInteger *)playPosition
{
if (!_playPosition) {
_playPosition = [NSNumber numberWithInt:0]; // Error
} else {
_playPosition += 1;
}
D, [2014-07-22T02:35:05.508567 #2405] DEBUG -- : Scraping for library/prerelease of iOS.
D, [2014-07-22T02:35:05.508735 #2405] DEBUG -- : Reading source https://developer.apple.com/library/prerelease/ios/navigation/library.json
I, [2014-07-22T02:35:17.867594 #2405] INFO -- : Good news everyone! Project Update: AdaptivePhotos: An Adaptive Application/2014-07-16/AdaptivePhotosAnAdaptiveApplication.zip
W, [2014-07-22T02:35:17.914741 #2405] WARN -- : Fuckers! Zip name: [AdaptivePhotosAnAdaptiveApplication.zip] Project name: [AdaptivePhotos: An Adaptive Application]
I, [2014-07-22T02:35:56.996631 #2405] INFO -- : Good news everyone! Project Update: Adventure: Building a SpriteKit Game Using Swift/2014-07-16/AdventureBuildingaSpriteKitGameUsingSwift.zip
W, [2014-07-22T02:35:57.034085 #2405] WARN -- : Fuckers! Zip name: [AdventureBuildingaSpriteKitGameUsingSwift.zip] Project name: [Adventure: Building a SpriteKit Game Using Swift]
I, [2014-07-22T02:39:08.238609 #2405] INFO -- : Good news everyone! Project Updat
Mind Mapping tools for Mac
-- Yes --
iMindQ (DropMind) 100$
MindNode 20$
Curio $100
-- Filtered out --
XMind # Needs java. That sucks.
#!/usr/bin/python
import csv
import re
from collections import Counter, OrderedDict
count_total = Counter()
count_by_date = {}
def get_count_today(by_date):