1. Dashboard
  2. Mitglieder
    1. Letzte Aktivitäten
    2. Benutzer online
    3. Team
    4. Mitgliedersuche
  3. Forenregeln
  4. Forum
    1. Unerledigte Themen
  • Anmelden
  • Registrieren
  • Suche
Alles
  • Alles
  • Artikel
  • Seiten
  • Forum
  • Erweiterte Suche
  1. AutoIt.de - Das deutschsprachige Forum.
  2. Mitglieder
  3. UEZ

Beiträge von UEZ

  • eukalyptus memFont und GDI+

    • UEZ
    • 16. Januar 2012 um 21:49

    Hier noch ein Beispiel:

    Source Code ist zu groß für die Code Box -> http://pastebin.com/KKqi3WBe

    Gruß,
    UEZ

  • Daten aus .txt auslesen, Txt anhand der Daten erstellen und Inhalt einfügen

    • UEZ
    • 15. Januar 2012 um 22:33

    Probiere es mal damit:

    [autoit]


    #include <File.au3>

    [/autoit][autoit][/autoit][autoit]

    Global $aZahlen
    _FileReadToArray(@ScriptDir & "\Zahlen.txt", $aZahlen)

    [/autoit][autoit][/autoit][autoit]

    For $i = 1 To $aZahlen[0]
    $hFile = FileOpen(@ScriptDir & "\" & $aZahlen[$i] & ".txt", 2)
    FileWrite($hFile, $aZahlen[$i])
    FileClose($hFile)
    Next

    [/autoit]

    Zahlen.txt ist die Datei mit den 4 Zeilen an Zahlen.

    Gruß,
    UEZ

  • Musik Visualiserung

    • UEZ
    • 14. Januar 2012 um 18:29

    Irgendwie kommt mir das bekannt vor... ;)

    Schaue mal hier nach: Audio Visualization Collection

    Gruß,
    UEZ

  • GUI anzeigen UND aus der taskleiste ausblenden?

    • UEZ
    • 11. Januar 2012 um 23:25

    Guckst du hier:

    [autoit]


    #include <GUIConstantsEx.au3>

    [/autoit][autoit][/autoit][autoit]

    $hGUI = GUICreate("No Taskbar", 200, 200, -1, -1, Default, Default, WinGetHandle(AutoItWinGetTitle()))
    GUISetState()

    [/autoit][autoit][/autoit][autoit]

    While 1
    Switch GUIGetMsg()
    Case $GUI_EVENT_CLOSE
    Exit
    EndSwitch
    WEnd

    [/autoit]

    Gruß,
    UEZ

  • UDF - TrueType Fonts im Script mitgeben und verwenden

    • UEZ
    • 11. Januar 2012 um 22:42

    "Nur" den Font in den Binärstring umwandeln reicht nicht. DU musst auch die Zeile

    GUICtrlSetFont(-1, 20, 400, 0, <Fontname>")

    anpassen, wobei der Fontname nicht der Dateiname ist, sondern der interne Name -> Eigenschatf TTF -> Title.


    Gruß,
    UEZ

    Dateien

    Fluted Germanica.7z 27,44 kB – 440 Downloads
  • Gui-Fenster "magnetisch" machen?

    • UEZ
    • 8. Januar 2012 um 21:10

    Oder vielleicht hier: http://www.autoitscript.com/forum/topic/24342-form-snap oder hier: http://www.autoitscript.com/forum/topic/12…w-alignment-udf

    Gruß,
    UEZ

  • Png, Jpg in Menü einfügen?

    • UEZ
    • 7. Januar 2012 um 21:14

    Probiere es mal damit:

    Spoiler anzeigen
    [autoit]


    #include <GUIConstantsEx.au3>
    #include <GuiMenu.au3>
    #include <WindowsConstants.au3>
    #include <GDIPlus.au3>
    #Include <GuiMenu.au3>
    $Form1 = GUICreate("Form1", 615, 438, 192, 124)
    Global Enum $idSave = 1000
    $hFile = _GUICtrlMenu_CreateMenu()
    _GUICtrlMenu_InsertMenuItem($hFile, 0, "&Speichern", $idSave)
    $hMain = _GUICtrlMenu_CreateMenu()
    _GUICtrlMenu_InsertMenuItem($hMain, 0, "&Datei", 0, $hFile)
    _GUICtrlMenu_SetMenu($Form1, $hMain)
    GUISetState()
    Global Const $sFile = StringReplace(@AutoItExe, "autoit3.exe", "Examples\GUI\Torus.png")
    Global $hBMP_File_Save = _GUICtrlMenu_CreateBitmap($sFile, 0)
    _GUICtrlMenu_SetItemBmp($hFile, 0, $hBMP_File_Save)

    [/autoit] [autoit][/autoit] [autoit]

    While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
    Case $GUI_EVENT_CLOSE
    _WinAPI_DeleteObject($hBMP_File_Save)
    Exit
    EndSwitch
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    Func _GUICtrlMenu_CreateBitmap($file, $iIndex = 0, $iW = 18, $iH = 18)
    If FileExists($file) Then
    Local $iStride = 0, $iPixelFormat = $GDIP_PXF32ARGB, $pScan0 = 0
    Local $GDIp = True, $Ret, $hIcon, $hImage, $hBitmap, $hContext, $hIcon
    If Not $ghGDIPDll Then
    $GDIp = False
    _GDIPlus_Startup()
    EndIf
    Local $fext = StringMid($file, StringLen($file) - 3)
    Switch $fext
    Case ".dll"
    $Ret = DllCall("shell32", "long", "ExtractAssociatedIcon", "int", 0, "str", $file, "int*", $iIndex)
    If @error Then Return SetError(2, @extended, 0)
    $hIcon = $Ret[0]
    $Ret = DllCall($ghGDIPDll, "int", "GdipCreateBitmapFromHICON", "ptr", $hIcon, "int*", 0)
    If @error Then Return SetError(3, @extended, 0)
    $hImage = $Ret[2]
    _WinAPI_DestroyIcon($hIcon)
    Case ".jpg", ".png", ".bmp", ".gif"
    $hImage = _GDIPlus_ImageLoadFromFile($file)
    If @error Then Return SetError(4, @extended, 0)
    EndSwitch

    [/autoit] [autoit][/autoit] [autoit]

    $Ret = DllCall($ghGDIPDll, "uint", "GdipCreateBitmapFromScan0", "int", $iW, "int", $iH, "int", $iStride, "int", $iPixelFormat, "ptr", $pScan0, "int*", 0)
    If @error Then Return SetError(5, @extended, 0)
    $hBitmap = $Ret[6]
    $hContext = _GDIPlus_ImageGetGraphicsContext($hBitmap)
    _GDIPlus_GraphicsDrawImageRect($hContext, $hImage, 0, 0, $iW, $iH)
    $hIcon = _GDIPlus_BitmapCreateDIBFromBitmap($hBitmap)
    _GDIPlus_GraphicsDispose($hContext)
    _GDIPlus_BitmapDispose($hBitmap)
    _GDIPlus_BitmapDispose($hImage)
    If Not $GDIp Then _GDIPlus_Shutdown()
    Return $hIcon
    Else
    Return SetError(1, 0, 0)
    EndIf
    EndFunc ;==>_GUICtrlMenu_CreateBitmap

    [/autoit] [autoit][/autoit] [autoit]

    Func _GDIPlus_BitmapCreateDIBFromBitmap($hBitmap)
    Local $tBIHDR, $Ret, $tData, $pBits, $hResult = 0
    $Ret = DllCall($ghGDIPDll, 'uint', 'GdipGetImageDimension', 'ptr', $hBitmap, 'float*', 0, 'float*', 0)
    If (@error) Or ($Ret[0]) Then Return 0
    $tData = _GDIPlus_BitmapLockBits($hBitmap, 0, 0, $Ret[2], $Ret[3], $GDIP_ILMREAD, $GDIP_PXF32ARGB)
    $pBits = DllStructGetData($tData, 'Scan0')
    If Not $pBits Then Return 0
    $tBIHDR = DllStructCreate('dword;long;long;ushort;ushort;dword;dword;long;long;dword;dword')
    DllStructSetData($tBIHDR, 1, DllStructGetSize($tBIHDR))
    DllStructSetData($tBIHDR, 2, $Ret[2])
    DllStructSetData($tBIHDR, 3, $Ret[3])
    DllStructSetData($tBIHDR, 4, 1)
    DllStructSetData($tBIHDR, 5, 32)
    DllStructSetData($tBIHDR, 6, 0)
    $hResult = DllCall('gdi32.dll', 'ptr', 'CreateDIBSection', 'hwnd', 0, 'ptr', DllStructGetPtr($tBIHDR), 'uint', 0, 'ptr*', 0, 'ptr', 0, 'dword', 0)
    If (Not @error) And ($hResult[0]) Then
    DllCall('gdi32.dll', 'dword', 'SetBitmapBits', 'ptr', $hResult[0], 'dword', $Ret[2] * $Ret[3] * 4, 'ptr', DllStructGetData($tData, 'Scan0'))
    $hResult = $hResult[0]
    Else
    $hResult = 0
    EndIf
    _GDIPlus_BitmapUnlockBits($hBitmap, $tData)
    Return $hResult
    EndFunc ;==>_GDIPlus_BitmapCreateDIBFromBitmap

    [/autoit]

    Ich werde bei Gelegenheit die UDF anpassen, damit sie auch Bilderdateien laden kann.

    Gruß,
    UEZ

  • Png, Jpg in Menü einfügen?

    • UEZ
    • 7. Januar 2012 um 17:27

    Hilft dir das hier vielleicht weiter? -> _GUICtrlMenu_CreateBitmap() v0.55 Build 2011-08-16 beta - Erstellt Icons für GUI Menüs

    Gruß,
    UEZ

  • Mp3 Datei im Script einbinden ohne Fileinstall?

    • UEZ
    • 6. Januar 2012 um 21:27

    Schaue mal hier nach -> File to Base64 String Code Generator v1.03 Build 2011-11-21

    Gruß,
    UEZ

  • Spalte aus einer CSV Datei ermitteln

    • UEZ
    • 5. Januar 2012 um 15:38

    Hilft dir das weiter:

    [autoit]


    #include <Array.au3>
    $CPUTemp_Log = FileRead("CT-Log 2011-12-27 12-10-50.csv")
    $aCPUTemp_Log = StringRegExp($CPUTemp_Log, "(\d+:\d+:\d+\s\d+/\d+/\d+),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),(.*),", 4)
    $Anzahl_Messungen = UBound($aCPUTemp_Log)

    [/autoit][autoit][/autoit][autoit]

    ;alle Messungen anzeigen
    For $i = 0 To $Anzahl_Messungen - 1
    _ArrayDisplay($aCPUTemp_Log[$i])
    Next

    [/autoit][autoit][/autoit][autoit]

    ;Core Load % der 8. Messung in Spalte 13 anzeigen
    $aTemp = $aCPUTemp_Log[8]
    MsgBox(0, "Test", "Core Load % der 8. Messung: " & $aTemp[13] & " %")

    [/autoit]

    Gruß,
    UEZ

  • Spalte aus einer CSV Datei ermitteln

    • UEZ
    • 4. Januar 2012 um 20:59

    Wo ist der CSV Anhang?

    Gruß,
    UEZ

  • GUI ruckelt

    • UEZ
    • 1. Januar 2012 um 23:18

    Es kommt darauf an, was du im Gesamten machen willst.

    Wenn du weißt, dass du viele GDI+ Funktionienen benutzt, macht es keinen Sinn in der Funktion _GDIPlus_Startup() und _GDIPlus_Shutdown() ständig zu benutzen, denn es kostet Zeit. Ein paar mal _GDIPlus_Startup() und _GDIPlus_Shutdown() aufrufen ist aber verkraftbar.

    _GDIPlus_Startup() am Anfang aufrufen und _GDIPlus_Shutdown() beim Beenden ist wohl die beste Lösung, denn ich sehe keinen Nachteil, auch wenn du keine GDI+ Funktionienen benutzt.

    Gruß,
    UEZ

  • GUI ruckelt

    • UEZ
    • 1. Januar 2012 um 16:49

    Ich habe den Code im Beitrag #6 modifiziert, so dass du das Bild in 90° Schritten drehen kannst.

    Gruß,
    UEZ

  • GUI ruckelt

    • UEZ
    • 31. Dezember 2011 um 13:17

    Natürlich muss man nicht 2x GuiCtrlCreatePic, aber ich hatte dich so verstanden.

    Gruß,
    UEZ

    PS: viele Wege führen nach Rom...

  • GUI ruckelt

    • UEZ
    • 31. Dezember 2011 um 11:08

    Probiere es mal damit:

    Spoiler anzeigen
    [autoit]


    #region ;************ Includes ************
    #include <GUIConstantsEx.au3>
    #include <WindowsConstants.au3>
    #include <GDIPlus.au3>
    #endregion ;************ Includes ************

    [/autoit] [autoit][/autoit] [autoit]

    Opt("GUIOnEventMode", 1) ; 0=ausgeschaltet, 1=OnEvent Modus aktiviert

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    Global Const $IMAGE_BITMAP = 0
    Global Const $STM_SETIMAGE = 0x0172
    Global $hPreviewBitmap

    [/autoit] [autoit][/autoit] [autoit]

    Global $datei1 = "C:\Windows\Web\Wallpaper\Windows\img0.jpg"

    [/autoit] [autoit][/autoit] [autoit]

    _GDIPlus_Startup() ;Vorschau

    [/autoit] [autoit][/autoit] [autoit]

    Global $hPreviewGui = GUICreate("Foto", 710, 350)
    Global $idPreviewPic = GUICtrlCreatePic("", 10, 10, 300, 200)
    GUICtrlSetState(-1, $GUI_DISABLE)
    Global $idPreviewPic2 = GUICtrlCreatePic("", 400, 10, 200, 300)
    GUICtrlSetState(-1, $GUI_DISABLE)
    Global $idButtonLoad = GUICtrlCreateButton("Laden", 300, 250, 60, 40)
    GUICtrlSetOnEvent(-1, "Load")
    GUISetOnEvent($GUI_EVENT_CLOSE, "_beenden")
    _PreviewLoadImage($datei1, $idPreviewPic, 300, 200)
    GUISetState()

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    While 1
    Sleep(10)
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    Func _beenden()
    _GDIPlus_Shutdown()
    Exit
    EndFunc ;==>_beenden

    [/autoit] [autoit][/autoit] [autoit]

    Func Load()
    Local $file = FileOpenDialog("Suche ein Bild aus", "", "Bilder (*.jpg;*png;*.bmp;*.gif)")
    If @error Then Return
    _PreviewLoadImage($file, $idPreviewPic2, 300, 200, 7, 1, 1)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    ; $iRotateFlipType - Type of rotation and flip:
    ; |0 - No rotation and no flipping (A 180-degree rotation, a horizontal flip and then a vertical flip)
    ; |1 - A 90-degree rotation without flipping (A 270-degree rotation, a horizontal flip and then a vertical flip)
    ; |2 - A 180-degree rotation without flipping (No rotation, a horizontal flip folow by a vertical flip)
    ; |3 - A 270-degree rotation without flipping (A 90-degree rotation, a horizontal flip and then a vertical flip)
    ; |4 - No rotation and a horizontal flip (A 180-degree rotation followed by a vertical flip)
    ; |5 - A 90-degree rotation followed by a horizontal flip (A 270-degree rotation followed by a vertical flip)
    ; |6 - A 180-degree rotation followed by a horizontal flip (No rotation and a vertical flip)
    ; |7 - A 270-degree rotation followed by a horizontal flip (A 90-degree rotation followed by a vertical flip)

    [/autoit] [autoit][/autoit] [autoit]

    Func _PreviewLoadImage($sImgFile, $CtrlID, $iW, $iH, $iInterpolationMode = 7, $iRotateFlipType = 0, $clear = 0)
    If $clear Then GUICtrlSendMsg($CtrlID, $STM_SETIMAGE, $IMAGE_BITMAP, 0)
    Local $hImage = _GDIPlus_ImageLoadFromFile($sImgFile)
    Local $aResult = DllCall($ghGDIPDll, "uint", "GdipCreateBitmapFromScan0", "int", $iW, "int", $iH, "int", 0, "int", 0x0026200A, "ptr", 0, "int*", 0)
    Local $hBitmap = $aResult[6]
    Local $hGfxCtxt = _GDIPlus_ImageGetGraphicsContext($hBitmap)
    DllCall($ghGDIPDll, "uint", "GdipSetInterpolationMode", "handle", $hGfxCtxt, "int", $iInterpolationMode)
    _GDIPlus_GraphicsDrawImageRect($hGfxCtxt, $hImage, 0, 0, $iW, $iH)
    If $iRotateFlipType Then DllCall($ghGDIPDll, "uint", "GdipImageRotateFlip", "hwnd", $hBitmap, "int", $iRotateFlipType)
    Local $hHBitmap = _GDIPlus_BitmapCreateDIBFromBitmap($hBitmap)
    _GDIPlus_ImageDispose($hImage)
    _GDIPlus_BitmapDispose($hBitmap)
    _GDIPlus_GraphicsDispose($hGfxCtxt)
    _WinAPI_DeleteObject(GUICtrlSendMsg($CtrlID, $STM_SETIMAGE, $IMAGE_BITMAP, $hHBitmap))
    EndFunc ;==>_PreviewLoadImage

    [/autoit] [autoit][/autoit] [autoit]

    Func _GDIPlus_BitmapCreateDIBFromBitmap($hBitmap)
    Local $tBIHDR, $Ret, $tData, $pBits, $hResult = 0
    $Ret = DllCall($ghGDIPDll, 'uint', 'GdipGetImageDimension', 'ptr', $hBitmap, 'float*', 0, 'float*', 0)
    If (@error) Or ($Ret[0]) Then Return 0
    $tData = _GDIPlus_BitmapLockBits($hBitmap, 0, 0, $Ret[2], $Ret[3], $GDIP_ILMREAD, $GDIP_PXF32ARGB)
    $pBits = DllStructGetData($tData, 'Scan0')
    If Not $pBits Then Return 0
    $tBIHDR = DllStructCreate('dword;long;long;ushort;ushort;dword;dword;long;long;dword;dword')
    DllStructSetData($tBIHDR, 1, DllStructGetSize($tBIHDR))
    DllStructSetData($tBIHDR, 2, $Ret[2])
    DllStructSetData($tBIHDR, 3, $Ret[3])
    DllStructSetData($tBIHDR, 4, 1)
    DllStructSetData($tBIHDR, 5, 32)
    DllStructSetData($tBIHDR, 6, 0)
    $hResult = DllCall('gdi32.dll', 'ptr', 'CreateDIBSection', 'hwnd', 0, 'ptr', DllStructGetPtr($tBIHDR), 'uint', 0, 'ptr*', 0, 'ptr', 0, 'dword', 0)
    If (Not @error) And ($hResult[0]) Then
    DllCall('gdi32.dll', 'dword', 'SetBitmapBits', 'ptr', $hResult[0], 'dword', $Ret[2] * $Ret[3] * 4, 'ptr', DllStructGetData($tData, 'Scan0'))
    $hResult = $hResult[0]
    Else
    $hResult = 0
    EndIf
    _GDIPlus_BitmapUnlockBits($hBitmap, $tData)
    Return $hResult
    EndFunc ;==>_GDIPlus_BitmapCreateDIBFromBitmap

    [/autoit]

    Gruß,
    UEZ

  • GUI ruckelt

    • UEZ
    • 30. Dezember 2011 um 22:23

    Ich meinte eher eine Art Animation. Ansonsten kannst du mehrere Bilder in verschiedene Picture Controls reinkopieren und fertig.

    Gruß,
    UEZ

  • GUI ruckelt

    • UEZ
    • 30. Dezember 2011 um 21:20

    Wenn du "nur" die Grafik anzeigen möchtest, würde ich das Bild eher in einem Picture Control darstellen.

    Siehe hier: [ gelöst ] Png in GUI laden


    Gruß,
    UEZ

  • ISN AutoIt Studio

    • UEZ
    • 30. Dezember 2011 um 17:29

    Wenn ich dein Testprojekt öffne, rechts auf die _Testfunc doppelt klicke und anschließend den AutoIt Syntax Check ausführe, bekomme ich spätestens beim zweiten Aufruf eine Fehlermeldung:

    Error: Subscript used with non-Array variable.

    Habe die Exe nur getestet!

    Gruß,
    UEZ

  • Png in GUI laden

    • UEZ
    • 30. Dezember 2011 um 12:17

    Schaue mal hier rein: http://www.autoitscript.com/forum/topic/135989-png-in-gui/


    Gruß,
    UEZ

  • Spalte aus einer CSV Datei ermitteln

    • UEZ
    • 29. Dezember 2011 um 23:44

    Du kannst auch die GetCoreTempInfo.dll anzapfen, wenn Core Temp läuft!

    Spoiler anzeigen
    [autoit]


    #cs
    Shared memory implementation in Core Temp:

    [/autoit] [autoit][/autoit] [autoit]

    Core Temp shares the following structure:

    [/autoit] [autoit][/autoit] [autoit]

    typedef struct core_temp_shared_data
    {
    unsigned int uiLoad[256];
    unsigned int uiTjMax[128];
    unsigned int uiCoreCnt;
    unsigned int uiCPUCnt;
    float fTemp[256];
    float fVID;
    float fCPUSpeed;
    float fFSBSpeed;
    float fMultipier;
    char sCPUName[100];
    unsigned char ucFahrenheit;
    unsigned char ucDeltaToTjMax;
    }CORE_TEMP_SHARED_DATA,*PCORE_TEMP_SHARED_DATA,**PPCORE_TEMP_SHARED_DATA;

    [/autoit] [autoit][/autoit] [autoit]

    unsigned int is a 32bit unsigned integer.
    unsigned char is 8bit (1 byte) in size.

    [/autoit] [autoit][/autoit] [autoit]

    ucFahrenheit and ucDeltaToTjMax represent boolean values. 0 = false, 1 = true.
    If ucFahrenheit is set, the temperature is reported in Fahrenheit.
    If ucDeltaToTjMax is set, the temperature reported respresents the distance from TjMax.

    [/autoit] [autoit][/autoit] [autoit]

    Core Temp's shared area is named: "CoreTempMappingObject".

    [/autoit] [autoit][/autoit] [autoit]

    C++ Dynamic Link Library:

    [/autoit] [autoit][/autoit] [autoit]

    This DLL was written in C++, and it can be easily used with most programming languages.
    There is only a single function. Here is the internal function declaration:

    [/autoit] [autoit][/autoit] [autoit]

    bool __declspec(dllimport) fnGetCoreTempInfo(CORE_TEMP_SHARED_DATA *&pData);

    [/autoit] [autoit][/autoit] [autoit]

    You can declare it in your program in the following manner:

    [/autoit] [autoit][/autoit] [autoit]

    typedef bool (*fnGetCoreTempInfo)(CORE_TEMP_SHARED_DATA *&pData);
    fnGetCoreTempInfo GetCoreTempInfo;

    [/autoit] [autoit][/autoit] [autoit]

    For compatibility with some programming languages a function was added.
    It uses Win32 API calling convention and is declared as follows:

    [/autoit] [autoit][/autoit] [autoit]

    bool WINAPI fnGetCoreTempInfoAlt(CORE_TEMP_SHARED_DATA *pData);

    [/autoit] [autoit][/autoit] [autoit]

    typedef bool (*fnGetCoreTempInfoAlt)(CORE_TEMP_SHARED_DATA *pData);
    fnGetCoreTempInfoAlt GetCoreTempInfo;

    [/autoit] [autoit][/autoit] [autoit]

    Usage:

    [/autoit] [autoit][/autoit] [autoit]

    * Declare a pointer to CORE_TEMP_SHARED_DATA structure and allocate it.
    It is also recommended to fill the allocated memory with NULL to avoid possible problems.
    * Call the function using the pointer to CORE_TEMP_SHARED_DATA structure as an argument.
    The function will fill the structure if the shared memory was successfully read.
    * The function returns 'true' if succeeded and 'false' if it failed. You can use GetLastError() in case the function fails.
    * In case the function fails due to an exception GetLastError() returns UNKNOWN_EXCEPTION (0x20000000)
    #ce
    #AutoIt3Wrapper_Run_Obfuscator=y
    #Obfuscator_Parameters=/sf /sv /om /cs=0 /cn=0
    #AutoIt3Wrapper_UseUpx=n
    #AutoIt3Wrapper_Run_After=upx.exe --ultra-brute "%out%"
    #AutoIt3Wrapper_Run_After=del /f /q GetCoreTempInfo_Obfuscated.au3

    [/autoit] [autoit][/autoit] [autoit]

    If Not FileExists(@ScriptDir & "\GetCoreTempInfo.dll") Or Not ProcessExists("Core Temp.exe") Then
    MsgBox(16,"Error", "Core Temp.exe läuft und/oder GetCoreTempInfo.dll existiert nicht", 20)
    Exit
    EndIf
    $dll = DllOpen(@ScriptDir & "\GetCoreTempInfo.dll")

    [/autoit] [autoit][/autoit] [autoit]

    $CORE_TEMP_SHARED_DATA = DllStructCreate("uint uiLoad[256];" & _
    "uint uiTjMax[128];" & _
    "uint uiCoreCnt;" & _
    "uint uiCPUCnt;" & _
    "float fTemp[256];" & _
    "float fVID;" & _
    "float fCPUSpeed;" & _
    "float fFSBSpeed;" & _
    "float fMultipier;" & _
    "char sCPUName[100];" & _
    "ubyte ucFahrenheit;" & _
    "ubyte ucDeltaToTjMax")

    [/autoit] [autoit][/autoit] [autoit]

    $call = DllCall($dll, "int", "fnGetCoreTempInfoAlt", "ptr", DllStructGetPtr($CORE_TEMP_SHARED_DATA))

    [/autoit] [autoit][/autoit] [autoit]

    $CPU_Name = DllStructGetData($CORE_TEMP_SHARED_DATA, "sCPUName")
    $CPU_Speed = Round(DllStructGetData($CORE_TEMP_SHARED_DATA, "fCPUSpeed"),0)
    $CPU_Cores = DllStructGetData($CORE_TEMP_SHARED_DATA, "uiCoreCnt")
    $CPU_FSB_Speed = Round(DllStructGetData($CORE_TEMP_SHARED_DATA, "fFSBSpeed"), 0)
    $CPU_Multiplicator = DllStructGetData($CORE_TEMP_SHARED_DATA, "fMultipier")
    $CPU_Temp = ""
    For $i = 1 To DllStructGetData($CORE_TEMP_SHARED_DATA, 'uiCoreCnt')
    $CPU_Temp &= DllStructGetData($CORE_TEMP_SHARED_DATA, "fTemp", $i) & ","
    Next
    $CPU_Temp = StringMid($CPU_Temp, 1 , StringLen($CPU_Temp) - 1)

    [/autoit] [autoit][/autoit] [autoit]

    MsgBox(0,"Core Temp", _
    "CPU Name: " & $CPU_Name & @CRLF & _
    "CPU Speed: " & $CPU_Speed & " MHz" & @CRLF & _
    "CPU Cores: " & $CPU_Cores & @CRLF & _
    "CPU FSB Speed: " & $CPU_FSB_Speed & " MHz" & @CRLF & _
    "CPU Multiplicator: " & $CPU_Multiplicator & @CRLF & _
    "CPU Temp: " & $CPU_Temp & " C", 30)

    [/autoit] [autoit][/autoit] [autoit]

    $CORE_TEMP_SHARED_DATA = 0
    DllClose($dll)

    [/autoit]

    Gruß,
    UEZ

Spenden

Jeder Euro hilft uns, Euch zu helfen.

Download

AutoIt Tutorial
AutoIt Buch
Onlinehilfe
AutoIt Entwickler
  1. Datenschutzerklärung
  2. Impressum
  3. Shoutbox-Archiv
Community-Software: WoltLab Suite™