From 72f2b58e12b0f86ed4f49cb939c18f18bb43e0df Mon Sep 17 00:00:00 2001 From: hyzboy Date: Tue, 9 Jun 2020 19:39:37 +0800 Subject: [PATCH] add TellPointer function in MemoryInputStream --- inc/hgl/io/MemoryInputStream.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/inc/hgl/io/MemoryInputStream.h b/inc/hgl/io/MemoryInputStream.h index 8cebe5f..b7a7445 100644 --- a/inc/hgl/io/MemoryInputStream.h +++ b/inc/hgl/io/MemoryInputStream.h @@ -145,6 +145,12 @@ namespace hgl return cur_pos; } + const void *TellPointer()const + { + if(!buf)return(nullptr); + return buf+cur_pos; + } + int64 GetSize()const { if(!buf)return(-1);