|
本帖最后由 2013kyj 于 2021-4-29 16:34 编辑
感谢大侠支招, 但是我尝试加上后不起作用, 我不知道将代码放在哪里, 我放在了48-57行, 刚进入系统的时候分辨率应该是1024*768, 全加载完后才会变成1920*1080, 另外,这个问题, 是同一个PE, 一个是MBR引导时,是正常的,1024*768的分辨率, 但是UEFI引导时, 分辨就变成了1920*1080, 然后壁纸就不正常了, 感觉能强制分辨率显示1024*768,问题就完美解决了, 找了很多办法都不灵
- // Pecmd launched from : RegWrite,HKLM,0x1,Tmp_System\Setup,CmdLine,"Pecmd.exe Main #$pWindir#$p\System32\Pecmd.ini"
- LOGS %WinDir%\System32\Pecmd.%USERNAME%.log
- CALL OSInit
- CALL PreShell
- CALL LoadShell
- CALL PostShell
- TIPS The system configuration is finished.,,1,#1
- WAIT 3000
- EXIT
- ////////////////////////////////////////////////////////////////////////////////////////////////
- _SUB OSInit
- // winpeshl.ini with [LaunchApps] wpeinit.exe
- IFEX %WinDir%\System32\winpeshl.log,!EXEC %WinDir%\System32\winpeshl.exe
- // EXEC %WinDir%\System32\wpeinit.exe
- // Load Display drivers
- // EXEC =@!%WinDir%\System32\Drvload.exe %WinDir%\inf\basicdisplay.inf %WinDir%\inf\basicrender.inf %WinDir%\inf\c_display.inf %WinDir%\inf\display.inf %WinDir%\inf\displayoverride.inf
- DISP W1024 H768 B32
- //TEAM DISP W1024 H768 B32|DISP W1280 720 B32|DISP W1280 H1024 B32|DISP W1366 H768 B32|DISP W1920 H1080 B32
- LOGO %WinDir%\web\wallpaper\Windows\img0.jpg
- NUMK 1
- TEXT System configuration, Please Wait...#0xFFFFFF L59 T39 $20*
- // TIPS System configuration, Please Wait..,,1,#1
- _END
- ////////////////////////////////////////////////////////////////////////////////////////////////
- _SUB PreShell
- EXEC =!"X:\PEMaterial\Autoruns\PEStartupMain.bat" OSInit
- INIT IU,3000
- _END
- ////////////////////////////////////////////////////////////////////////////////////////////////
- _SUB DaemonShell
- // FIND %~1=explorer.exe,SET shell_cmd=PECMD EXEC -HOOK explorer.exe,!SET shell_cmd=%~1 %~2 %~3
- FIND $%USERNAME%<>SYSTEM,EXEC %ProgramFiles%\WinXShell\WinXShell.exe -luacode "shel([[%~1 %~2 %~3]])"!SHEL %~1 %~2 %~3
- _END
- ////////////////////////////////////////////////////////////////////////////////////////////////
- _SUB LoadShell
- DISP ? &a
- MSTR* * &b,&c=<1*>&a
- IFEX [ $%&a%=1024 & $%&b%=768 ],
- {*
- WALL %WinDir%\web\wallpaper\Windows\img0.jpg
- }
- IFEX [ $%&a%=1920 & $%&b%=1080 ],
- {*
- WALL %WinDir%\web\wallpaper\Windows\img1.jpg
- }
- IFEX %WinDir%\System32\ctfmon.exe, EXEC PECMD.exe EXEC -su %WinDir%\System32\ctfmon.exe
- EXEC =!"X:\PEMaterial\Autoruns\PEStartupMain.bat" BeforeShell
- DaemonShell explorer.exe
- //WXS_DaemonShell "%ProgramFiles%\WinXShell\WinXShell.exe" -regist -winpe
- EXEC !%ProgramFiles%\WinXShell\WinXShell.exe -regist -daemon
- _END
- ////////////////////////////////////////////////////////////////////////////////////////////////
- _SUB PostShell
- // Dism can't mount in SYSTEM without workgroup
- // CALL $Netapi32.dll,NetJoinDomain,,WORKGROUP,,,,1
- LOGO
- // EXEC = Wait, @background, ! Hide. ex: EXEC =WaitNoHide.cmd, EXEC @!=WaitHide.cmd, EXEC NoWaitNoHide.cmd, EXEC @!NoWaitHide.cmd
- EXEC =%ProgramFiles%\WinXShell\WinXShell.exe -luacode Taskbar:WaitForReady()
- EXEC !"X:\PEMaterial\Autoruns\PEStartupMain.bat" PostShell
- // Load drivers
- //DEVI %WinDir%\inf\battery.inf
- //DEVI %WinDir%\inf\usbport.inf
- _END
- ////////////////////////////////////////////////////////////////////////////////////////////////
复制代码 |
|