Seite 1 von 1

S3d-modi und auflösungen zusammenfassen

Verfasst: 19.10.2005 22:04
von dllfreak2001
Holala,

das hier ist ein Prog das eine Zusammenfassung macht welche Sprite3d-modi und auflösungen eure karten unterstützen.
Die Farbwerte werden dann in eine txt-datei im Source-Ordner geschrieben (Achtung kann sehr groß werden).

Ich werde mal noch ein Prog zu basteln mit dem man den Kram auswerten kann.

Code: Alles auswählen

OpenWindow(0,0,0,440,45,#PB_Window_MinimizeGadget|#PB_Window_ScreenCentered,"PB-Grafiktestprogram v1.1")
    CreateGadgetList(WindowID(0))
        TextGadget(100,5,5,100,15,"Betriebssystem:")
        ComboBoxGadget(0,5,20,100,200)
            AddGadgetItem(0,-1,"Win 95")
            AddGadgetItem(0,-1,"Win 98")
            AddGadgetItem(0,-1,"Win 2000")
            AddGadgetItem(0,-1,"Win XP Home")
            AddGadgetItem(0,-1,"Win XP Prof.")
            AddGadgetItem(0,-1,"Win XP 64")
            SetGadgetState(0,3)               
            
        TextGadget(101,110,5,200,15,"Grafikkarte u. Treiberversion:")
            StringGadget(1,110,20,250,20,"")
        ButtonGadget(2,365,20,70,20,"Fertig!")
Repeat
    winevent = WaitWindowEvent()
    gadgetevent = EventGadgetID() 


    If winevent = #PB_Event_CloseWindow 
        CloseWindow(0)
        End
    EndIf
Until gadgetevent = 2 And winevent = #PB_Event_Gadget 

CreateFile(0,"Gfxlog.txt")
WriteStringN("Grafiktestprogramm v1.1" )
WriteStringN(FormatDate("%dd.%mm.%yyyy %hh:%ii:%ss", Date()))
WriteStringN(">> Betriebssystem ist "+GetGadgetText(0))
WriteStringN(">> Grafikkarte ist " + GetGadgetText(1))
WriteStringN("")

CloseWindow(0)

InitSprite()
InitSprite3D()
InitKeyboard()
Global res.s

For ix = 0 To 2
    If OpenScreen(800,600,16+8*ix,"GFX-Test v1.1") = 1
        WriteStringN("+ " + Str(16 + 8*ix)+"-Bit Modus: ")

        CreateSprite(0,128,128,#PB_Sprite_Texture)
        CreateSprite(1,128,256,#PB_Sprite_Texture)
        CreateSprite(2,512,512,#PB_Sprite_Texture)
        CreateSprite(3,252,171,#PB_Sprite_Texture)
        For x = 0 To 3
            StartDrawing(SpriteOutput(x))
           
                Box(3,3,56,56,RGB(255,0,0))
                Box(67,3,56,56,RGB(0,255,0))
                Box(67,67,56,56,RGB(0,0,255))
                Box(3,67,56,56,RGB(255,0,255))
            StopDrawing()
            TransparentSpriteColor(x,255,0,255)
            CreateSprite3D(x,x)
        Next
        
        For x = 1 To 13
            res = ""
            For y = 1 To 13

                For s = 0 To 3
                ClearScreen(0,0,0)
                StartDrawing(ScreenOutput())
                    Box(7,7,24,24,RGB(255,0,0)):Box(31,7,24,24,RGB(0,255,0)):Box(31,31,24,24,RGB(0,0,255)):Box(7,31,24,24,RGB(255,255,255))
                    Box(71,7,24,24,RGB(255,0,0)):Box(95,7,24,24,RGB(0,255,0)):Box(95,31,24,24,RGB(0,0,255)):Box(71,31,24,24,RGB(255,255,255))                    
                    Box(71,71,24,24,RGB(255,0,0)):Box(95,71,24,24,RGB(0,255,0)):Box(95,95,24,24,RGB(0,0,255)):Box(71,95,24,24,RGB(255,255,255))          
                    Box(7,71,24,24,RGB(255,0,0)):Box(31,71,24,24,RGB(0,255,0)):Box(31,95,24,24,RGB(0,0,255)):Box(7,95,24,24,RGB(255,255,255))              
                    Box(0,3,3,8,RGB(255,255,255))
                StopDrawing()
                    Start3D()
                        Sprite3DBlendingMode(x,y)
                        DisplaySprite3D(s,0,0, 255)
                    Stop3D()
                StartDrawing(ScreenOutput())
                      res = res + Str(Point(0,0)) + " "
                      res = res + Str(Point(1,4)) + " "
                      res = res + Str(Point(4,4)) + " "
                      res = res + Str(Point(68,4)) + " "
                      res = res + Str(Point(68,68)) + " "
                      res = res + Str(Point(4,68)) + " "
                      
                      res = res + Str(Point(8,8)) + " "
                      res = res + Str(Point(32,8)) + " "
                      res = res + Str(Point(32,32)) + " "
                      res = res + Str(Point(8,32)) + " "
                      
                      res = res + Str(Point(72,8)) + " "
                      res = res + Str(Point(96,8)) + " "
                      res = res + Str(Point(96,32)) + " "
                      res = res + Str(Point(72,32)) + " "
                     
                      res = res + Str(Point(72,72)) + " "
                      res = res + Str(Point(96,72)) + " "
                      res = res + Str(Point(96,96)) + " "
                      res = res + Str(Point(72,96)) + " "
                      
                      
                      res = res + Str(Point(8,72)) + " "
                      res = res + Str(Point(32,72)) + " "
                      res = res + Str(Point(32,96)) + " "
                      res = res + Str(Point(8,96)) + " "
                      
                StopDrawing()
                FlipBuffers()
                
                ClearScreen(0,0,0)
                StartDrawing(ScreenOutput())
                    Box(7,7,24,24,RGB(255,0,0)):Box(31,7,24,24,RGB(0,255,0)):Box(31,31,24,24,RGB(0,0,255)):Box(7,31,24,24,RGB(255,255,255))
                    Box(71,7,24,24,RGB(255,0,0)):Box(95,7,24,24,RGB(0,255,0)):Box(95,31,24,24,RGB(0,0,255)):Box(71,31,24,24,RGB(255,255,255))                    
                    Box(71,71,24,24,RGB(255,0,0)):Box(95,71,24,24,RGB(0,255,0)):Box(95,95,24,24,RGB(0,0,255)):Box(71,95,24,24,RGB(255,255,255))          
                    Box(7,71,24,24,RGB(255,0,0)):Box(31,71,24,24,RGB(0,255,0)):Box(31,95,24,24,RGB(0,0,255)):Box(7,95,24,24,RGB(255,255,255))              
                    Box(0,3,3,8,RGB(255,255,255))
                StopDrawing()
                    Start3D()
                        Sprite3DBlendingMode(x,y)
                        DisplaySprite3D(s,0,0, 150)
                    Stop3D()
                StartDrawing(ScreenOutput())
                      res = res + Str(Point(0,0)) + " "
                      res = res + Str(Point(1,4)) + " "
                      res = res + Str(Point(4,4)) + " "
                      res = res + Str(Point(68,4)) + " "
                      res = res + Str(Point(68,68)) + " "
                      res = res + Str(Point(4,68)) + " "
                      
                      res = res + Str(Point(8,8)) + " "
                      res = res + Str(Point(32,8)) + " "
                      res = res + Str(Point(32,32)) + " "
                      res = res + Str(Point(8,32)) + " "
                      
                      res = res + Str(Point(72,8)) + " "
                      res = res + Str(Point(96,8)) + " "
                      res = res + Str(Point(96,32)) + " "
                      res = res + Str(Point(72,32)) + " "
                     
                      res = res + Str(Point(72,72)) + " "
                      res = res + Str(Point(96,72)) + " "
                      res = res + Str(Point(96,96)) + " "
                      res = res + Str(Point(72,96)) + " "
                      
                      
                      res = res + Str(Point(8,72)) + " "
                      res = res + Str(Point(32,72)) + " "
                      res = res + Str(Point(32,96)) + " "
                      res = res + Str(Point(8,96)) + " "
                      
                StopDrawing()
                FlipBuffers()
                Next
                
            Next
            WriteStringN(res)
        Next

        CloseScreen()

    Else
        WriteStringN(">> " + Str(16 + 8*ix)+"-Bit Modus wird nicht unterstützt!")
    EndIf
Next
CloseFile(0)
End

Ist zwar nicht sehr schön erfüllt aber seinen Zweck...