~registry/dolphin-emu/triforce

« back to all changes in this revision

Viewing changes to Source/Core/DiscIO/Src/BannerLoaderWii.h

  • Committer: Sérgio Benjamim
  • Date: 2015-02-13 05:54:40 UTC
  • Revision ID: sergio_br2@yahoo.com.br-20150213055440-ey2rt3sjpy27km78
Dolphin Triforce branch from code.google, commit b957980 (4.0-315).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Copyright 2013 Dolphin Emulator Project
 
2
// Licensed under GPLv2
 
3
// Refer to the license.txt file included.
 
4
 
 
5
#ifndef _BANNER_LOADER_WII_H_
 
6
#define _BANNER_LOADER_WII_H_
 
7
 
 
8
#include "BannerLoader.h"
 
9
 
 
10
namespace DiscIO
 
11
{
 
12
class CBannerLoaderWii
 
13
        : public IBannerLoader
 
14
{
 
15
        public:
 
16
 
 
17
                CBannerLoaderWii(DiscIO::IVolume *pVolume);
 
18
 
 
19
                virtual ~CBannerLoaderWii();
 
20
 
 
21
                virtual bool IsValid();
 
22
 
 
23
                virtual std::vector<u32> GetBanner(int* pWidth, int* pHeight);
 
24
 
 
25
                virtual std::vector<std::string> GetNames();
 
26
                virtual std::string GetCompany();
 
27
                virtual std::vector<std::string> GetDescriptions();
 
28
 
 
29
        private:
 
30
                
 
31
                enum
 
32
                {
 
33
                        TEXTURE_SIZE = 192 * 64 * 2,
 
34
                        ICON_SIZE = 48 * 48 * 2,
 
35
                        COMMENT_SIZE = 32
 
36
                };
 
37
 
 
38
                enum CommentIndex
 
39
                {
 
40
                        NAME_IDX,
 
41
                        DESC_IDX
 
42
                };
 
43
 
 
44
                struct SWiiBanner
 
45
                {
 
46
                        u32 ID;
 
47
 
 
48
                        u32 m_Flag;
 
49
                        u16 m_Speed;
 
50
                        u8  m_Unknown[22];
 
51
 
 
52
                        // Not null terminated!
 
53
                        u16 m_Comment[2][COMMENT_SIZE];
 
54
                        u8  m_BannerTexture[TEXTURE_SIZE];
 
55
                        u8  m_IconTexture[8][ICON_SIZE];
 
56
                } ;
 
57
 
 
58
                u8* m_pBannerFile;
 
59
 
 
60
                bool m_IsValid;
 
61
 
 
62
                bool GetStringFromComments(const CommentIndex index, std::string& s);
 
63
};
 
64
} // namespace
 
65
 
 
66
#endif
 
67