1dcaec19cSAlexander von Gluck IV /* 2dcaec19cSAlexander von Gluck IV * Copyright 2005 Michael Lotz <mmlr@mlotz.ch> 3dcaec19cSAlexander von Gluck IV * All rights reserved. Distributed under the terms of the MIT license. 4dcaec19cSAlexander von Gluck IV */ 5dcaec19cSAlexander von Gluck IV #ifndef ACCELERANT_BUFFER_H 6dcaec19cSAlexander von Gluck IV #define ACCELERANT_BUFFER_H 7dcaec19cSAlexander von Gluck IV 8dcaec19cSAlexander von Gluck IV #include <Accelerant.h> 9dcaec19cSAlexander von Gluck IV #include "RenderingBuffer.h" 10dcaec19cSAlexander von Gluck IV 11dcaec19cSAlexander von Gluck IV class AccelerantBuffer : public RenderingBuffer { 12dcaec19cSAlexander von Gluck IV public: 13dcaec19cSAlexander von Gluck IV AccelerantBuffer(); 14dcaec19cSAlexander von Gluck IV AccelerantBuffer(const display_mode& mode, 15dcaec19cSAlexander von Gluck IV const frame_buffer_config& config); 16dcaec19cSAlexander von Gluck IV AccelerantBuffer(const AccelerantBuffer& other, 17dcaec19cSAlexander von Gluck IV bool offscreenBuffer = false); 18dcaec19cSAlexander von Gluck IV virtual ~AccelerantBuffer(); 19dcaec19cSAlexander von Gluck IV 20dcaec19cSAlexander von Gluck IV virtual status_t InitCheck() const; IsGraphicsMemory()21*77870621SAugustin Cavalier virtual bool IsGraphicsMemory() const { return true; /* TODO! */ } 22dcaec19cSAlexander von Gluck IV 23dcaec19cSAlexander von Gluck IV virtual color_space ColorSpace() const; 24dcaec19cSAlexander von Gluck IV virtual void* Bits() const; 25dcaec19cSAlexander von Gluck IV virtual uint32 BytesPerRow() const; 26dcaec19cSAlexander von Gluck IV virtual uint32 Width() const; 27dcaec19cSAlexander von Gluck IV virtual uint32 Height() const; 28dcaec19cSAlexander von Gluck IV 29dcaec19cSAlexander von Gluck IV void SetDisplayMode(const display_mode& mode); 30dcaec19cSAlexander von Gluck IV void SetFrameBufferConfig( 31dcaec19cSAlexander von Gluck IV const frame_buffer_config& config); 32dcaec19cSAlexander von Gluck IV void SetOffscreenBuffer(bool offscreenBuffer); 33dcaec19cSAlexander von Gluck IV 34dcaec19cSAlexander von Gluck IV private: 35dcaec19cSAlexander von Gluck IV display_mode fDisplayMode; 36dcaec19cSAlexander von Gluck IV frame_buffer_config fFrameBufferConfig; 37dcaec19cSAlexander von Gluck IV 38dcaec19cSAlexander von Gluck IV bool fDisplayModeSet : 1; 39dcaec19cSAlexander von Gluck IV bool fFrameBufferConfigSet : 1; 40dcaec19cSAlexander von Gluck IV bool fIsOffscreenBuffer : 1; 41dcaec19cSAlexander von Gluck IV }; 42dcaec19cSAlexander von Gluck IV 43dcaec19cSAlexander von Gluck IV #endif // ACCELERANT_BUFFER_H 44