Bryan Schumaker
cafc19fbed
Don't set score when importing library
...
The score system has been replaced with a like / dislike system. Score
is no longer an attribute that can be set.
2010-12-18 14:36:21 -05:00
Bryan Schumaker
8349efe8c7
Library export formatting changes
...
This patch rearranges the decode functions to put decoders for a single
version together. I also removed some extra whitespace and clearly
labeled the decoding sections.
2010-12-18 14:33:17 -05:00
Bryan Schumaker
0eb3a15783
Add functions for controlling "like"
...
This patch adds a function for getting the "like" status of the current
song. It also changes the "set_like" function to use an event, rather
than just setting it.
2010-12-18 11:03:25 -05:00
Bryan Schumaker
f55cb44a64
Fix set_attr()
...
First, set_attr() needs to find the id of the current song. Second, we
should save after changing attributes.
2010-12-18 11:02:32 -05:00
Bryan Schumaker
076e89783a
Add save() to the Source class
...
This will allow us to save any changes made to the Source()
2010-12-18 11:01:44 -05:00
Bryan Schumaker
401241ac47
Track recent songs for sequential next too
...
Why was I only adding recent songs to the list when picking a random
song? It really doesn't make any sense. This patch tracks recent songs
any time next() is called in the playlist.
2010-12-18 09:36:01 -05:00
Bryan Schumaker
2d0643dd7b
Just skip songs the user doesn't like
...
If the user doesn't like a song, we shouldn't have a 25% chance of
playing the song anyway. We should just pick a different song.
2010-12-18 09:27:01 -05:00
Bryan Schumaker
0bcb444317
Remove score field
...
This patch removes the score field from the Track() class
2010-12-17 23:37:06 -05:00
Bryan Schumaker
7c2778614d
Added control to set like value
...
First, this patch adds a function for setting attributes for the current
file. Second, it adds a function for specifically setting the "like"
attribute.
2010-12-17 23:33:05 -05:00
Bryan Schumaker
d91c099723
Added set_attr to the Source() class
...
Having access to the set_attr function should allow us to change
attributes for the current track easily.
2010-12-17 23:28:55 -05:00
Bryan Schumaker
0c254aa957
Remove score changing code
...
I am switching to a like / dislike system, so I don't need to worry
about scores anymore.
2010-12-17 23:18:19 -05:00
Bryan Schumaker
6449b6badb
Skip songs based on like, rather than score
...
I think I can get a better guess for what users like based on what they
tell me, rather than trying to analyze their playback habits.
2010-12-17 23:15:19 -05:00
Bryan Schumaker
da6b0fd3eb
Add "like" field to the Track() class
...
This will allow the users to tell us if they do or don't like a song.
Songs default to None for unrated songs.
2010-12-17 23:06:46 -05:00
Bryan Schumaker
4e5995ec64
Added pause_after control to libsaria
...
This gives me a chance to remove it as a plugin. I noticed that
sometimes I would hear a fraction of a second of music before the
pausing started. This should fix that.
2010-12-17 23:00:45 -05:00
Bryan Schumaker
b5fef6ba3c
Check if cur_source is None
...
We should do this before attempting to return an ID...
2010-12-17 08:31:22 -05:00
Bryan Schumaker
3abc80bdc4
Add seeking to controls
...
Seeking should be part of controls, rather than existing independently
as part of the audio package. This patch moves the seeking functions,
and removes the need to pass a specific number of seconds.
2010-12-16 22:08:26 -05:00
Bryan Schumaker
b6c9c12ea9
Remove datetime module import
...
This was added to test timing changes for my recent pickle improvements.
2010-12-16 11:02:32 -05:00
Bryan Schumaker
84eb73d2a2
Pickling improvements
...
By using pickle correctly, I can now load in files significantly faster
than the old way. Library loading times have gone from about 3 seconds
to 0.25 seconds. I like this.
2010-12-16 09:29:06 -05:00
Bryan Schumaker
677240eabe
Added toggle_play()
...
This function will call play() if audio is currently paused. It will
call pause() all other times.
2010-12-15 22:26:45 -05:00
Bryan Schumaker
588a2bfb7a
Update library in background
...
This patch adds a function for updating the entire library in the
background.
2010-12-14 20:37:15 -05:00
Bryan Schumaker
646fc59c5c
Save playlist after choosing next
2010-12-12 14:47:19 -05:00
Bryan Schumaker
6fc8415838
next() selects from queue
...
We check the queue for a song first, then go to the playlist.
2010-12-12 14:45:30 -05:00
Bryan Schumaker
4acb972583
Play songs in the queue
...
Selecting songs in the queue will play the song and remove it from the
queue.
2010-12-12 14:28:19 -05:00
Bryan Schumaker
f47aa206d1
Remove songs from queue
...
I can now remove songs from the queue. Additionally, I only add songs
to the queue if they are not already in it.
2010-12-12 14:20:12 -05:00
Bryan Schumaker
c7c81c1b03
Queue reset
...
I can now reset the queue to an empty state.
2010-12-12 14:13:18 -05:00
Bryan Schumaker
e7bab2fc94
Queue filtering
...
The queue can now be filtered using the default text entry.
2010-12-12 14:04:36 -05:00
Bryan Schumaker
e997d4df33
Fill queue page
...
This patch shows what songs are currently in the queue.
2010-12-12 13:57:26 -05:00
Bryan Schumaker
1e3c48bbf1
Add songs to the Queue
...
I can add songs from both the library and the playlist to the queue
2010-12-12 13:54:38 -05:00
Bryan Schumaker
25dcd0619c
Added framework for Queue
...
This patch adds the queue as a tab on the main window. I also added the
libsaria queue functions, but right now the don't do anything.
2010-12-12 13:46:49 -05:00
Bryan Schumaker
d01d75cbe5
Find artwork using new get_attrs()
...
Using the new get_attrs() function makes things easier, and allows us to
find artwork for songs played that aren't in the library.
2010-12-12 08:55:30 -05:00
Bryan Schumaker
4a3e6184ab
get_attrs uses list.append()
...
Appending to the list should be slightly faster than using +=
2010-12-11 21:54:36 -05:00
Bryan Schumaker
6957cc96f6
Clean up playlist
...
Removed extra spaces and old, commented out code
2010-12-09 08:11:31 -05:00
Bryan Schumaker
a233861cfd
Playlist with generic init function
...
The playlist is now initialized using the generic init function.
2010-12-09 08:10:42 -05:00
Bryan Schumaker
9acd22b402
Library with generic init function
...
The library is now initialized with the generic init function.
2010-12-09 08:09:37 -05:00
Bryan Schumaker
9785796642
Add generic init function
...
The generic init function will start a new thread and call the user
given init function with the user given callback function.
2010-12-09 08:07:53 -05:00
Bryan Schumaker
47927bf9d3
File source attrs added
...
I added length and year attributes
2010-12-08 07:59:20 -05:00
Bryan Schumaker
4749c49e16
Use the file source
...
When opening a file, we should use the file source instead of directly
loading it.
2010-12-07 20:47:32 -05:00
Bryan Schumaker
5fc2628160
Add file source
...
The file source is used to play and get attributes for files on disk
that the user wants us to play.
2010-12-07 20:46:42 -05:00
Bryan Schumaker
e2fa7fff78
Don't have named sources
...
I don't use the named of each source any more. It can be removed.
2010-12-07 20:45:30 -05:00
Bryan Schumaker
4af08350e2
cur_source no longer a string
...
It is now a pointer to the current source instance for faster access (no
dictionary lookup needed)
2010-12-07 20:10:33 -05:00
Bryan Schumaker
1089b85e88
Get_attrs current source
...
The generic get_attrs() function now works correctly. I had to
introduce a "get_cur_id()" function for each source to get this working.
2010-12-07 08:07:10 -05:00
Bryan Schumaker
9cef85a0e9
Remove play_selected_id
...
Nothing uses this function so it should be removed
2010-12-05 17:16:04 -05:00
Bryan Schumaker
265e063fe0
Remove lib_get_cur_id()
...
Nothing using this function, so it should be removed
2010-12-05 17:15:35 -05:00
Bryan Schumaker
f063da5b56
Began work on virtual sources
...
Virtual sources should make it easier to do things with the current song
without having to know anything about it (such as a song id or file
path).
2010-12-05 17:11:41 -05:00
Bryan Schumaker
a32315e1e5
Remove libsaria.sources.play_id
...
Nothing uses this function. Time to remove it
2010-12-05 13:50:24 -05:00
Bryan Schumaker
b6dba32e47
Rename file2id in backup
...
It is easier to use file_id
2010-12-05 13:42:23 -05:00
Bryan Schumaker
3eeb35d81c
Stop using file_to_id
...
We should now use file_id located in libsaria.path
2010-12-05 13:40:39 -05:00
Bryan Schumaker
fbfc5738c6
Bump version numbers
...
We are now developing Ocarina 4.3!
2010-12-05 13:40:15 -05:00
Bryan Schumaker
fff834a14c
Find file_id for a given path
...
Finding the id of a file shouldn't be the job of the library. Instead,
it should exist as part of the path minipulation code.
2010-12-05 13:29:10 -05:00
Bryan Schumaker
9646d256ff
Remove plist_refresh()
2010-12-05 13:18:29 -05:00