Mercurial > libdvdnav.hg
comparison read_cache.c @ 114:b6834e6359cf src
big libdvdnav cleanup, quoting the ChangeLog:
* some bugfixes
* code cleanup
* build process polishing
* more sensible event order in get_next_block to ensure useful event delivery
* VOBU level resume
* fixed: seeking in a multiangle feature briefly showed the wrong angle
author | mroi |
---|---|
date | Thu, 20 Feb 2003 15:32:21 +0000 |
parents | 293bb1798e86 |
children | 3bfaec0c1288 |
comparison
equal
deleted
inserted
replaced
113:ec2df154be56 | 114:b6834e6359cf |
---|---|
104 #define READ_CACHE_TRACE 0 | 104 #define READ_CACHE_TRACE 0 |
105 */ | 105 */ |
106 | 106 |
107 #ifdef __GNUC__ | 107 #ifdef __GNUC__ |
108 # if READ_CACHE_TRACE | 108 # if READ_CACHE_TRACE |
109 # define dprintf(fmt, args...) fprintf(MSG_OUT, "libdvdnav: %s: "fmt, __func__ , ## arg | 109 # define dprintf(fmt, args...) fprintf(MSG_OUT, "libdvdnav: %s: "fmt, __func__ , ## args) |
110 # else | 110 # else |
111 # define dprintf(fmt, args...) /* Nowt */ | 111 # define dprintf(fmt, args...) /* Nowt */ |
112 # endif | 112 # endif |
113 #else | 113 #else |
114 # if READ_CACHE_TRACE | 114 # if READ_CACHE_TRACE |
115 # define dprintf(fmt, ...) fprintf(MSG_OUT, "libdvdnav: %s: "fmt, __func__ , __VA_ARGS_ | 115 # define dprintf(fmt, ...) fprintf(MSG_OUT, "libdvdnav: %s: "fmt, __func__ , __VA_ARGS__) |
116 # else | 116 # else |
117 # define dprintf(fmt, ...) /* Nowt */ | 117 # define dprintf(fmt, ...) /* Nowt */ |
118 # endif | 118 # endif |
119 #endif | 119 #endif |
120 | 120 |
282 } | 282 } |
283 | 283 |
284 pthread_mutex_unlock(&self->cache_lock); | 284 pthread_mutex_unlock(&self->cache_lock); |
285 } | 285 } |
286 | 286 |
287 /* This function will do the cache read once implemented */ | 287 /* This function will do the cache read */ |
288 int dvdnav_read_cache_block( read_cache_t *self, int sector, size_t block_count, uint8_t **buf) { | 288 int dvdnav_read_cache_block( read_cache_t *self, int sector, size_t block_count, uint8_t **buf) { |
289 int result, diff; | 289 int result, diff; |
290 | 290 |
291 if(!self) | 291 if(!self) |
292 return 0; | 292 return 0; |