xref: /haiku/src/kits/media/BufferCache.h (revision 2b76973fa2401f7a5edf68e6470f3d3210cbcff3)
1 /*
2  * Copyright 2009, Axel Dörfler, axeld@pinc-software.de.
3  * Copyright 2002, Marcus Overhagen. All Rights Reserved.
4  * Distributed under the terms of the MIT License.
5  */
6 #ifndef _BUFFER_CACHE_H_
7 #define _BUFFER_CACHE_H_
8 
9 
10 #include <map>
11 
12 #include <MediaDefs.h>
13 
14 
15 class BBuffer;
16 
17 
18 namespace BPrivate {
19 
20 
21 class BufferCache {
22 public:
23 								BufferCache();
24 								~BufferCache();
25 
26 			BBuffer*			GetBuffer(media_buffer_id id);
27 
28 private:
29 	typedef std::map<media_buffer_id, BBuffer*> BufferMap;
30 
31 			BufferMap			fMap;
32 };
33 
34 
35 }	// namespace BPrivate
36 
37 
38 #endif	// _BUFFER_CACHE_H_
39