From mint-bounce@lists.fishpool.fi Thu Jul 29 15:45:42 2010 X-Squirrel-UserHash: EhVcX1lFRQVaRwYcDQ== X-Squirrel-FromHash: UANfXlsQEAo= Message-ID: <1deef33c678b0e816d70a3ed88bec353-EhVcX1lFRQVaRwYcDTpQCEFddQZLVF5dQUNBAjBTXF5bVkYPW0F0Alc6XF1XQUEBXV9fRA==-webmailer2@server07.webmailer.hosteurope.de> Date: Thu, 29 Jul 2010 21:42:44 +0200 Subject: [MiNT] VDI Device Independant format From: "m0n0" To: mint@lists.fishpool.fi Reply-To: ole@monochrom.net User-Agent: Host Europe Webmailer/1.0 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-HE-Access: Yes X-bounce-key: webpack.hosteurope.de;ole@monochrom.net;1280432564;4998ccbc; X-ecartis-version: Ecartis v1.0.0 Sender: mint-bounce@lists.fishpool.fi Errors-to: mint-bounce@lists.fishpool.fi X-original-sender: ole@monochrom.net Precedence: bulk List-help: List-unsubscribe: List-Id: X-List-ID: List-subscribe: List-owner: List-post: Hello, I was reading http://toshyp.atari.org/en/VDI_fundamentals.html#Device-independent_20format and I just wanted to make sure that I understand it right. Of course Memory in the machine is not layered like the image shows it, and although the doc says the planes are placed contiguous placed in memory, I'm not really sure about that. (maybe because I think to much about Atari ST interleaved format when reading the doc) Let's assume I want to read color data of the device independent screen data. And Let's assume 16x16 pixel screen data is located at 0x0e1024... Instead of writing how I understand the doc, I just type some pseudo code, I think I that expresses my thoughts better: base = 0x0e1024; // imaginary address where the device independent screen data is stored LONG img_width = 16; // dimension of device independent screen data LONG img_height = 16; // dimension of device independent screen data LONG plane_size = img_width * img_height; WORD * plane_0 = base + plane_size * 0; WORD * plane_1 = base + plane_size * 1; WORD * plane_2 = base + plane_size * 2; WORD * last_word_in_plane_2 = plane_2 + plane_size - sizeof( WORD ) Would the pointers ( plane_0 - plane_2 ) point to the correct location? One thing I could think of is that the plane data is not contiguous - like the Screen Format for Atari ST in 16 color mode, but maybe it's wrong to think about that format when working with the VDI device independent format... Thanks for reading & possible answers! :) -- Greets, Ole