comparison Render.cpp @ 150:d92c78ab54fe

Слияние
author Ritor1
date Tue, 12 Feb 2013 10:17:35 +0600
parents 2b0c652cc165 b099dd069171
children 796b79187c27
comparison
equal deleted inserted replaced
149:2b0c652cc165 150:d92c78ab54fe
2936 2936
2937 2937
2938 //----- (0047BACF) -------------------------------------------------------- 2938 //----- (0047BACF) --------------------------------------------------------
2939 void Render::TransformBillboardsAndSetPalettesODM() 2939 void Render::TransformBillboardsAndSetPalettesODM()
2940 { 2940 {
2941 int v0; // edi@1 2941 //int v0; // edi@1
2942 char *v1; // esi@2 2942 char *v1; // esi@2
2943 unsigned int v2; // edx@3 2943 unsigned int v2; // edx@3
2944 int v3; // eax@3 2944 int v3; // eax@3
2945 int v4; // edi@3 2945 int v4; // edi@3
2946 int v5; // eax@3 2946 int v5; // eax@3
2952 DWORD v11; // eax@13 2952 DWORD v11; // eax@13
2953 int v12; // eax@13 2953 int v12; // eax@13
2954 int v13; // eax@14 2954 int v13; // eax@14
2955 RenderBillboardTransform_local0 billboard; // [sp+4h] [bp-60h]@1 2955 RenderBillboardTransform_local0 billboard; // [sp+4h] [bp-60h]@1
2956 int v15; // [sp+54h] [bp-10h]@13 2956 int v15; // [sp+54h] [bp-10h]@13
2957 int v16; // [sp+58h] [bp-Ch]@1 2957 //int v16; // [sp+58h] [bp-Ch]@1
2958 int v17; // [sp+5Ch] [bp-8h]@2 2958 int v17; // [sp+5Ch] [bp-8h]@2
2959 int v18; // [sp+60h] [bp-4h]@13 2959 int v18; // [sp+60h] [bp-4h]@13
2960 2960
2961 billboard.uParentBillboardID = -1; 2961 billboard.uParentBillboardID = -1;
2962 billboard.pTarget = pRenderer->pTargetSurface; 2962 billboard.pTarget = pRenderer->pTargetSurface;
2964 billboard.uTargetPitch = pRenderer->uTargetSurfacePitch; 2964 billboard.uTargetPitch = pRenderer->uTargetSurfacePitch;
2965 billboard.uViewportX = pViewport->uViewportX; 2965 billboard.uViewportX = pViewport->uViewportX;
2966 billboard.uViewportY = pViewport->uViewportY; 2966 billboard.uViewportY = pViewport->uViewportY;
2967 billboard.uViewportZ = pViewport->uViewportZ - 1; 2967 billboard.uViewportZ = pViewport->uViewportZ - 1;
2968 billboard.uViewportW = pViewport->uViewportW; 2968 billboard.uViewportW = pViewport->uViewportW;
2969 v0 = 0; 2969 //v0 = 0;
2970 pOutdoorCamera->uNumBillboards = uNumBillboardsToDraw; 2970 pOutdoorCamera->uNumBillboards = uNumBillboardsToDraw;
2971 v16 = 0; 2971
2972 if ( (signed int)uNumBillboardsToDraw > 0 ) 2972 //v16 = 0;
2973 { 2973 for (int i = 0; i < uNumBillboardsToDraw; ++i)
2974 {
2975 auto pBillboard = pBillboardRenderList + i;
2974 v17 = 0; 2976 v17 = 0;
2975 v1 = (char *)&pBillboardRenderList[0].uScreenSpaceY; 2977 v1 = (char *)&pBillboardRenderList[i].uScreenSpaceY;
2976 do 2978 //do
2977 { 2979 //{
2978 billboard.uScreenSpaceX = *((short *)v1 - 1); 2980 billboard.uScreenSpaceX = pBillboard->uScreenSpaceX;
2979 v2 = *((short *)v1 - 5); 2981 v2 = *((short *)v1 - 5);
2980 billboard.uScreenSpaceY = *(short *)v1; 2982 billboard.uScreenSpaceY = pBillboard->uScreenSpaceY;
2981 v3 = *((int *)v1 - 10); 2983 v3 = *((int *)v1 - 10);
2982 billboard.uParentBillboardID = v0; 2984 billboard.uParentBillboardID = i;
2983 v4 = *((int *)v1 + 1); 2985 v4 = *((int *)v1 + 1);
2984 billboard.field_10 = v3; 2986 billboard.field_10 = v3;
2985 v5 = *((int *)v1 - 9); 2987 v5 = *((int *)v1 - 9);
2986 billboard.uTintColor = v4; 2988 billboard.uTintColor = v4;
2987 v6 = *((short *)v1 - 8); 2989 v6 = *((short *)v1 - 8);
3020 if ( v13 >= 0 ) 3022 if ( v13 >= 0 )
3021 pSprites_LOD->pSpriteHeaders[v13]._4ACC38(&billboard, 1); 3023 pSprites_LOD->pSpriteHeaders[v13]._4ACC38(&billboard, 1);
3022 } 3024 }
3023 } 3025 }
3024 v17 += 5; 3026 v17 += 5;
3025 v0 = v16 + 1; 3027 //v0 = v16 + 1;
3026 v1 += 52; 3028 v1 += 52;
3027 ++v16; 3029 //++v16;
3028 } 3030 //}
3029 while ( v16 < (signed int)uNumBillboardsToDraw ); 3031 //while ( v16 < (signed int)uNumBillboardsToDraw );
3030 } 3032 }
3031 } 3033 }
3032 3034
3033 3035
3034 //----- (0047AF11) -------------------------------------------------------- 3036 //----- (0047AF11) --------------------------------------------------------