BaseSingleBatchRenderQueue::BaseSingleBatchRenderQueue(IRenderTarget* renderTarget /*= nullptr*/, Camera* camera /*= nullptr*/, RenderingStrategy strategy /*= RenderingStrategy::MultipleDynamicBatch*/) :mRenderTarget(renderTarget), mCamera(camera) { SAFE_RETAIN(mRenderTarget); SAFE_RETAIN(mCamera); mBatch = BatchPool::Instance().Create(strategy); mBatch->Initialize(); }
BlockReadStream::BlockReadStream(const IStream& stream,uint32 blockSize) : mSourceStream(&stream), mBuffer(blockSize, false), mBufferLength(0), mBlockIndex(Math::UIntMaxValue) { SAFE_RETAIN(mSourceStream); }
BufferStream::BufferStream(const IStream& stream, uint bufferSize) : mSourceStream((IStream*)&stream), mIsSourceReadonly(true), mBuffer(bufferSize, false) { SAFE_RETAIN(mSourceStream); mPrevOperation = StreamDataOperation::None; }
IMaterial::IMaterial(ITexture* texture /*= nullptr*/, IEffect* effect /*= nullptr*/, GraphicsDrawMode drawMode /*= GraphicsDrawMode::Triangles*/, const FileIdRef& fileId /*= FileIdRef::Empty*/) :IResource(fileId), mFirstTexture(nullptr), mEffect(effect), mDrawMode(drawMode) { mId = AutoIncreaseId<IMaterial>::New(); SAFE_RETAIN(mEffect); if(texture!=nullptr) { AddTexture(texture); } }
MessageEventArg::MessageEventArg( IMessage* message ) :mMessage(message) { SAFE_RETAIN(mMessage); }
MessageEventArg::MessageEventArg( const MessageEventArg& e ) { mMessage=e.mMessage; SAFE_RETAIN(mMessage); }
void CLInstanceMaterial::setBindVertexInputList(CArray<CLBindVertexInput>* _array) { SAFE_RELEASE(m_bindVertexInputList); SAFE_RETAIN(_array); m_bindVertexInputList = _array; }
BaseFontModel::BaseFontModel( IFont* font,Alignment alignment/*=Alignment::LeftBottom*/,Size2U restrictSize/*=Size2U::Zero*/) :BaseMultipleModel(font->Name()),mFont(font),mAlignment(alignment),mColor(Color4F::White),mRestrictSize(restrictSize) { SAFE_RETAIN(mFont); }
BlockWriteStream::BlockWriteStream(IStream& stream, uint32 blockSize) : mSourceStream(&stream), mBuffer(blockSize, false) { SAFE_RETAIN(mSourceStream); }
RenderingObject::RenderingObject(const RenderingObject& val) :mMesh(val.mMesh),mMaterial(val.mMaterial) { SAFE_RETAIN(mMesh); SAFE_RETAIN(mMaterial); }
RenderingObject::RenderingObject(IMesh* mesh /*= nullptr*/, IMaterial* material /*= nullptr*/) :mMesh(mesh),mMaterial(material) { SAFE_RETAIN(mMesh); SAFE_RETAIN(mMaterial); }