private static ResU.GX2.GX2CompSel ConvertBNTXToWiiUChannel(ResGFXBNTX.ChannelType compNX)
        {
            ResU.GX2.GX2CompSel type = new ResU.GX2.GX2CompSel();

            switch (compNX)
            {
            case ResGFXBNTX.ChannelType.Zero:
                type = ResU.GX2.GX2CompSel.Always0;
                break;

            case ResGFXBNTX.ChannelType.One:
                type = ResU.GX2.GX2CompSel.Always1;
                break;

            case ResGFXBNTX.ChannelType.Alpha:
                type = ResU.GX2.GX2CompSel.ChannelA;
                break;

            case ResGFXBNTX.ChannelType.Blue:
                type = ResU.GX2.GX2CompSel.ChannelB;
                break;

            case ResGFXBNTX.ChannelType.Green:
                type = ResU.GX2.GX2CompSel.ChannelG;
                break;

            case ResGFXBNTX.ChannelType.Red:
                type = ResU.GX2.GX2CompSel.ChannelR;
                break;
            }

            return(type);
        }
        private static ResGFXBNTX.ChannelType ConvertWiiUToBNTXChannel(ResU.GX2.GX2CompSel compU)
        {
            ResGFXBNTX.ChannelType type = new ResGFXBNTX.ChannelType();

            switch (compU)
            {
            case ResU.GX2.GX2CompSel.Always0:
                type = ResGFXBNTX.ChannelType.Zero;
                break;

            case ResU.GX2.GX2CompSel.Always1:
                type = ResGFXBNTX.ChannelType.One;
                break;

            case ResU.GX2.GX2CompSel.ChannelA:
                type = ResGFXBNTX.ChannelType.Alpha;
                break;

            case ResU.GX2.GX2CompSel.ChannelB:
                type = ResGFXBNTX.ChannelType.Blue;
                break;

            case ResU.GX2.GX2CompSel.ChannelG:
                type = ResGFXBNTX.ChannelType.Green;
                break;

            case ResU.GX2.GX2CompSel.ChannelR:
                type = ResGFXBNTX.ChannelType.Red;
                break;
            }

            return(type);
        }
예제 #3
0
 private STChannelType GX2ChanneToGeneric(Syroot.NintenTools.Bfres.GX2.GX2CompSel comp)
 {
     if (comp == Syroot.NintenTools.Bfres.GX2.GX2CompSel.ChannelR)
     {
         return(STChannelType.Red);
     }
     else if (comp == Syroot.NintenTools.Bfres.GX2.GX2CompSel.ChannelG)
     {
         return(STChannelType.Green);
     }
     else if (comp == Syroot.NintenTools.Bfres.GX2.GX2CompSel.ChannelB)
     {
         return(STChannelType.Blue);
     }
     else if (comp == Syroot.NintenTools.Bfres.GX2.GX2CompSel.ChannelA)
     {
         return(STChannelType.Alpha);
     }
     else if (comp == Syroot.NintenTools.Bfres.GX2.GX2CompSel.Always0)
     {
         return(STChannelType.Zero);
     }
     else
     {
         return(STChannelType.One);
     }
 }