diff VideoPlayer.cpp @ 2070:4231fdf46dde

Minimap's drawing
author Nomad
date Tue, 03 Dec 2013 21:25:05 +0200
parents 259df09dfb50
children ba5cd8a8a0d3
line wrap: on
line diff
--- a/VideoPlayer.cpp	Tue Dec 03 20:18:17 2013 +0200
+++ b/VideoPlayer.cpp	Tue Dec 03 21:25:05 2013 +0200
@@ -458,6 +458,8 @@
   a2.dwSize = 32;
   a2.dwFlags = 64;
   pRenderer->GetTargetPixelFormat(&a2);
+  if (a2.dwRGBBitCount == 32)
+    return SMACKBUFFER565;
   if ( a2.dwRGBBitCount != 8 )
   {
     if ( a2.dwRBitMask == 0xF800 )
@@ -849,6 +851,9 @@
   unsigned int v5; // eax@1
   //_SMACK *v6; // eax@1
 
+  Log::Warning(L"smacker");
+  return;
+
   pRenderer->BeginScene();
 
   auto pixels = new unsigned short[640 * 480];
@@ -859,7 +864,7 @@
   SmackToBuffer(pSmackerMovie, 8, 8, 2 * v4, pRenderer->field_14, v3, v5);
 
   
-  for (unsigned int y = 8; y < 8 + pRenderer->field_14; ++y)
+  for (unsigned int y = 8; y < 8 + pSmackerMovie->Height; ++y)
     for (unsigned int x = 8; x < 8 + pSmackerMovie->Width; ++x)
     {
       pRenderer->WritePixel16(x, y, pixels[x + y * 640]);
@@ -867,7 +872,7 @@
   delete [] pixels;
 
   //v6 = pSmackerMovie;
-  if ( pSmackerMovie->NewPalette )
+  if (false&& pSmackerMovie->NewPalette )
   {
     SmackBufferNewPalette((long)pSmackerBuffer, (long)pSmackerMovie->Palette, LOWORD(pSmackerMovie->PalType));
     SmackColorRemapWithTrans(