<commit_before>﻿#include "CGEKRenderSystem.h"
#include "IGEKRenderFilter.h"
#include "CGEKProperties.h"
#include <windowsx.h>
#include <atlpath.h>
#include <algorithm>
#include <concurrent_vector.h>
#include <ppl.h>

#include "GEKEngineCLSIDs.h"
#include "GEKSystemCLSIDs.h"

DECLARE_INTERFACE_IID_(IGEKMaterial, IUnknown, "819CA201-F652-4183-B29D-BB71BB15810E")
{
    STDMETHOD_(void, Enable)                (THIS_ CGEKRenderSystem *pManager, IGEKVideoContext *pContext) PURE;
    STDMETHOD_(float4, GetColor)            (THIS) PURE;
    STDMETHOD_(bool, IsFullBright)          (THIS) PURE;
};

class CGEKMaterial : public CGEKUnknown
                   , public IGEKMaterial
                   , public CGEKRenderStates
                   , public CGEKBlendStates
{
private:
    CComPtr<IUnknown> m_spAlbedoMap;
    CComPtr<IUnknown> m_spNormalMap;
    CComPtr<IUnknown> m_spInfoMap;
    bool m_bFullBright;
    float4 m_nColor;

public:
    DECLARE_UNKNOWN(CGEKMaterial);
    CGEKMaterial(IUnknown *pAlbedoMap, IUnknown *pNormalMap, IUnknown *pInfoMap, const float4 &nColor, bool bFullBright)
        : m_spAlbedoMap(pAlbedoMap)
        , m_spNormalMap(pNormalMap)
        , m_spInfoMap(pInfoMap)
        , m_nColor(nColor)
        , m_bFullBright(bFullBright)
    {
    }

    ~CGEKMaterial(void)
    {
    }

    // IGEKMaterial

    STDMETHODIMP_(void) Enable(CGEKRenderSystem *pManager, IGEKVideoContext *pContext)
    {
        pManager->SetResource(pContext->GetPixelSystem(), 0, m_spAlbedoMap);
        pManager->SetResource(pContext->GetPixelSystem(), 1, m_spNormalMap);
        pManager->SetResource(pContext->GetPixelSystem(), 2, m_spInfoMap);
        CGEKRenderStates::Enable(pContext);
        CGEKBlendStates::Enable(pContext);
    }

    STDMETHODIMP_(float4) GetColor(void)
    {
        return m_nColor;
    }

    STDMETHODIMP_(bool) IsFullBright(void)
    {
        return m_bFullBright;
    }
};
<commit_msg>Removing extra blank line<commit_after>﻿#include "CGEKRenderSystem.h"
#include "IGEKRenderFilter.h"
#include "CGEKProperties.h"
#include <windowsx.h>
#include <atlpath.h>
#include <algorithm>
#include <concurrent_vector.h>
#include <ppl.h>

#include "GEKEngineCLSIDs.h"
#include "GEKSystemCLSIDs.h"

DECLARE_INTERFACE_IID_(IGEKMaterial, IUnknown, "819CA201-F652-4183-B29D-BB71BB15810E")
{
    STDMETHOD_(void, Enable)                (THIS_ CGEKRenderSystem *pManager, IGEKVideoContext *pContext) PURE;
    STDMETHOD_(float4, GetColor)            (THIS) PURE;
    STDMETHOD_(bool, IsFullBright)          (THIS) PURE;
};

class CGEKMaterial : public CGEKUnknown
                   , public IGEKMaterial
                   , public CGEKRenderStates
                   , public CGEKBlendStates
{
private:
    CComPtr<IUnknown> m_spAlbedoMap;
    CComPtr<IUnknown> m_spNormalMap;
    CComPtr<IUnknown> m_spInfoMap;
    bool m_bFullBright;
    float4 m_nColor;

public:
    DECLARE_UNKNOWN(CGEKMaterial);
    CGEKMaterial(IUnknown *pAlbedoMap, IUnknown *pNormalMap, IUnknown *pInfoMap, const float4 &nColor, bool bFullBright)
        : m_spAlbedoMap(pAlbedoMap)
        , m_spNormalMap(pNormalMap)
        , m_spInfoMap(pInfoMap)
        , m_nColor(nColor)
        , m_bFullBright(bFullBright)
    {
    }

    ~CGEKMaterial(void)
    {
    }

    // IGEKMaterial
    STDMETHODIMP_(void) Enable(CGEKRenderSystem *pManager, IGEKVideoContext *pContext)
    {
        pManager->SetResource(pContext->GetPixelSystem(), 0, m_spAlbedoMap);
        pManager->SetResource(pContext->GetPixelSystem(), 1, m_spNormalMap);
        pManager->SetResource(pContext->GetPixelSystem(), 2, m_spInfoMap);
        CGEKRenderStates::Enable(pContext);
        CGEKBlendStates::Enable(pContext);
    }

    STDMETHODIMP_(float4) GetColor(void)
    {
        return m_nColor;
    }

    STDMETHODIMP_(bool) IsFullBright(void)
    {
        return m_bFullBright;
    }
};

{'fraction_non_alphanumeric': 0.10333247222939809, 'fraction_numerical': 0.014983208473262722, 'mean_word_length': 3.3262569832402233, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 31, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6877019', 'n_tokens_mistral': 1460, 'n_tokens_neox': 1400, 'n_words': 211}