1 /* 2 * Copyright 2000-2008 Ingo Weinhold <ingo_weinhold@gmx.de> All rights reserved. 3 * Distributed under the terms of the MIT license. 4 */ 5 #include "VideoTarget.h" 6 7 VideoTarget()8VideoTarget::VideoTarget() 9 : fBitmapLock(), 10 fBitmap(NULL) 11 { 12 } 13 14 ~VideoTarget()15VideoTarget::~VideoTarget() 16 { 17 } 18 19 20 bool LockBitmap()21VideoTarget::LockBitmap() 22 { 23 return fBitmapLock.Lock(); 24 } 25 26 27 void UnlockBitmap()28VideoTarget::UnlockBitmap() 29 { 30 fBitmapLock.Unlock(); 31 } 32 33 34 void SetBitmap(const BBitmap * bitmap)35VideoTarget::SetBitmap(const BBitmap* bitmap) 36 { 37 LockBitmap(); 38 fBitmap = bitmap; 39 UnlockBitmap(); 40 } 41 42 43 const BBitmap* GetBitmap() const44VideoTarget::GetBitmap() const 45 { 46 return fBitmap; 47 } 48 49