Jump to content

Zohran

Active Members
  • Posts

    32
  • Joined

  • Last visited

About Zohran

  • Birthday 11/07/1992

Recent Profile Visitors

205 profile views

Zohran's Achievements

Seeker

Seeker (1/7)

2

Reputation

  1. Excellent work,indeed hard work, 5 stars indeed.
  2. Hmmmm. Well i want this function because i am going to update my advanced icon displayer.Because if load icons of size 128x128 or greater size for items greater than 500 it consumes much memory.
  3. This is confusing.
  4. Yes. Your Right
  5. thank you. Not very accurate.Its a good effort.
  6. oops, sorry my mistake
  7. Dear Melba It is not working for icon view.
  8. Hi. How to get indices of items in a listview which are currently visible on the screen, not all items?
  9. Not So Easy but Works Nicely.
  10. Looks Like There is no soluton to it in autoit.
  11. still not working. ok . let me clarify more . when we use a fps (frames per second utilty) we can see the frames on our screen . it is displaying on top of every window. just like that i want my gui to be displayed on top of every window
  12. hey is there no one out there for the solution????
  13. high. the problem is that i have crated a gui window with attribute set to $WS_EX_TOPMOST. but when i start a game it remains on back.??? #include <WinAPI.au3> #include <GDIPlus.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <_PDH_PerformanceCounters.au3> Global Const $iRadius = 8 Global Const $iOpacity = 200 Global Const $AC_SRC_ALPHA = 0 Global $sString = "",$timer,$hGUI Global Enum $eScrDC = 0, $eMemDC, $eBitmap, $eWidth, $eHeight, $eGraphic, $eLast Global $hPDHQuery, $aCPUCounters, $iTotalCPUs _GDIPlus_Startup() $hCPU = GUICreate("786",$iRadius*110,$iRadius*2, 0,0,0, BitOR($WS_EX_TOOLWINDOW,$WS_EX_LAYERED, $WS_EX_TOPMOST)) GUISetState() $hGraphic = ResourceInit($iRadius*110,$iRadius*2) $hBrush = _GDIPlus_BrushCreateSolid(0xFFFFFF2F) $hFormat = _GDIPlus_StringFormatCreate() $hFamily = _GDIPlus_FontFamilyCreate("Arial") $hFont = _GDIPlus_FontCreate($hFamily,10,0) $tLayout = _GDIPlus_RectFCreate(0, 0, $iRadius * 110,$iRadius*2 ) _PDH_Init() $hPDHQuery = _PDH_GetNewQueryHandle() $aCPUCounters = _PDH_GetCPUCounters($hPDHQuery, "") $iTotalCPUs = @extended Func ResourceInit($iWidth, $iHeight) Local $aInfo[$eLast + 1] $aInfo[$eScrDC] = _WinAPI_GetDC(0) $aInfo[$eMemDC] = _WinAPI_CreateCompatibleDC($aInfo[$eScrDC]) $aInfo[$eBitmap] = _WinAPI_CreateCompatibleBitmap($aInfo[$eScrDC], $iWidth, $iHeight) _WinAPI_SelectObject($aInfo[$eMemDC], $aInfo[$eBitmap]) $aInfo[$eWidth] = $iWidth $aInfo[$eHeight] = $iHeight $aInfo[$eGraphic] = _GDIPlus_GraphicsCreateFromHDC($aInfo[$eMemDC]) _GDIPlus_GraphicsFillRect($aInfo[$eGraphic], 0, 0, $iRadius * 110, $iRadius * 2) Return $aInfo EndFunc ;==>ResourceInit Func ResourceSet($hGUI, ByRef $aInfo, $iAlpha = -1) Local $pSize, $tSize, $pSource, $tSource, $pBlend, $tBlend If $iAlpha = -1 Then $iAlpha = $iOpacity $tSize = DllStructCreate($tagSIZE) $pSize = DllStructGetPtr($tSize) DllStructSetData($tSize, "X", $aInfo[$eWidth]) DllStructSetData($tSize, "Y", $aInfo[$eHeight]) $tSource = DllStructCreate($tagPOINT) $pSource = DllStructGetPtr($tSource) $tBlend = DllStructCreate($tagBLENDFUNCTION) $pBlend = DllStructGetPtr($tBlend) DllStructSetData($tBlend, "Alpha", $iAlpha) DllStructSetData($tBlend, "Format", $AC_SRC_ALPHA) _WinAPI_UpdateLayeredWindow($hGUI, $aInfo[$eScrDC], 0, $pSize, $aInfo[$eMemDC], $pSource, 0, $pBlend, $ULW_ALPHA) EndFunc ;==>ResourceSet While 1 = 1 Sleep(1000) _PDH_CollectQueryData($hPDHQuery) $iCounterValue = _PDH_UpdateCounter($hPDHQuery, $aCPUCounters[$iTotalCPUs - 1][1], 0, True) $mem = MemGetStats() $sString = "CPU:" & $iCounterValue & "%" & " ,Memory Load: " & $mem[0] & "% ,GPU TEMP/LOAD:" & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static73") & "/ " & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static82") & ",GCC:" & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static67") & ",GMC:" & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static70") & ",Dedicated:" & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static88") & ",Dynamic:" & ControlGetText("TechPowerUp GPU-Z 0.6.2","","Static91") $aInfo = _GDIPlus_GraphicsMeasureString($hGraphic[$eGraphic], $sString, $hFont, $tLayout, $hFormat) _GDIPlus_GraphicsFillRect($hGraphic[$eGraphic], 0, 0, $iRadius * 110, $iRadius * 2) _GDIPlus_GraphicsDrawStringEx($hGraphic[$eGraphic], $sString, $hFont, $aInfo[0], $hFormat, $hBrush) ResourceSet($hCPU, $hGraphic) WEnd Func _PDH_GetCPUCounters($hPDHQuery, $sPCName = "") If $sPCName <> "" And StringLeft($sPCName, 2) = "" Then $sPCName = StringTrimLeft($sPCName, 1) Local $aCPUsList = _PDH_GetCounterList(":2386(*)" & $sPCName) If @error Then Return SetError(@error, @extended, "") Local $aCPUCounters = _PDH_AddCountersByArray($hPDHQuery, $aCPUsList, 1, -1) If @error Then Return SetError(@error, @extended, "") Return SetExtended($aCPUsList[0], $aCPUCounters) EndFunc ;==>_PDH_GetCPUCounters
×
×
  • Create New...