2025年8月26日 星期二

安裝 劍星 ue4ss mod

20250723 才知道有個叫做 UE4SS 的 mod, 這個 mod 很特別, 並不是提供遊戲功能, 而是提供一個修改界面, 讓開發人員可以用 UE4SS 來修改遊戲, 但我不知道這和原本的 mod 修改有什麼不同, 也許是可以提供更不同的修改內容。steam deck 一樣可以使用 ue4ss。

ue4ss 是很重要的底層 mod, 建議還是裝起來, 很多有趣的 mod 都會需要 ue4ss, 雖然有時候會造成遊戲不穩開不起來, 但是還是值得使用, 通常是更新才會遇到遊戲不穩開不起來的情形。

UE4SS 3.1.0 for StellarBlade 在 20250723 使用 UE4SS 需要使用 UE4SS_v3.1.0-6.zip 這個版本, 否則會遇到無法載入 UE4SS.dll 錯誤訊息, 應該是劍星更新的問題。UE4SS_v3.1.0-6 這是 fork UE4SS 專門針對劍星的修改。



Camera Control, 就是一個透過 ue4ss 修改的 mod, 可以調整相機視角, 但我覺得不太好用, 有點過頭, 會看到一些非遊戲場景的角度。

ue4ss mod 要放在 steam deck 路徑: /home/deck/.local/share/Steam/steamapps/common/StellarBlade/SB/Binaries/Win64/

list 2. ue4ss 目錄結構 (/home/deck/.local/share/Steam/steamapps/common/StellarBlade/SB/Binaries/Win64/)
 1 .
 2 ├── dwmapi.dll
 3 └── ue4ss
 4     ├── Default_UVTD_Configs
 5     ├── LICENSE
 6     ├── Mods
 7     ├── UE4SS.dll
 8     ├── UE4SS-settings.ini
 9     ├── UE4SS_Signatures
10     └── VTableLayout.ini
11
12 4 directories, 5 files

dwmapi.dll 是一個 dll hook, 遊戲會載入 dwmapi.dll, dwmapi.dll 會載入 UE4SS.dll, 載入成功會看到 UE4SS.log, 裡頭會紀錄一些載入的 mod 資訊。

list 3. UE4SS.log
  1 [2025-07-24 15:08:46.2759360] Console created
  2 [2025-07-24 15:08:46.2761107] UE4SS - v3.0.1 Beta #0 - Git SHA #d3d1004
  3 [2025-07-24 15:08:46.2761234] UE4SS Build Configuration: Game__Shipping__Win64 (MSVC)
  4 [2025-07-24 15:08:46.2868598] Creating save backup
  5 [2025-07-24 15:08:46.4882794] Setting up mods...
  6 [2025-07-24 15:08:46.4989272] Starting mods (from mods.txt load order)...
  7 [2025-07-24 15:08:46.4997833] Starting mods (from enabled.txt, no defined load order)...
  8 [2025-07-24 15:08:46.5026510] No specific game configuration found, using default configuration file
  9 [2025-07-24 15:08:46.5026787] Config: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss\UE4SS-settings.ini
 10 
 11 [2025-07-24 15:08:46.5026866] root directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss
 12 [2025-07-24 15:08:46.5026936] working directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss
 13 [2025-07-24 15:08:46.5027003] game executable directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64
 14 [2025-07-24 15:08:46.5027447] game executable: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\SB-Win64-Shipping.exe (324622336 bytes)
 15 
 16 
 17 [2025-07-24 15:08:46.5027521] mods directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss\Mods
 18 [2025-07-24 15:08:46.5027585] log directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss
 19 [2025-07-24 15:08:46.5027651] object dumper directory: Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss
 20 
 21 
 22 [2025-07-24 15:08:46.5131256] Getting ordered lists from ini file
 23 [2025-07-24 15:08:46.5131786] UObjectBase

949 
950 [2025-07-24 15:08:52.4567664] m_shared_functions: 0x1cebeb0
951 [2025-07-24 15:08:52.4583826] Input source set to: Win32Async
952 [2025-07-24 15:08:52.4938174] Enabling custom events
953 [2025-07-24 15:08:52.4944210] Starting mods (from mods.txt load order)...
954 [2025-07-24 15:08:52.4949094] Starting Lua mod 'JiggleUpdate'
955 [2025-07-24 15:08:52.4980764] [Lua] [Patch] Loaded tweaks from Z:\home\deck\.local\share\Steam\steamapps\common\StellarBlade\SB\Binaries\Win64\ue4ss\Mods\JiggleUpdate\scripts\SpringBoneTweaks.lua[2025-07-24 15:08:52.5099139] [Lua] [CDO] Total patched: 0[2025-07-24 15:08:52.5215790] [Lua] [CDO] Total patched: 0[2025-07-24 15:08:52.5291171] [Lua] [Patch] Live instance not found for 'CharacterMesh0.CH_P_EVE_01_AnimBP_New_C'[2025-07-24 15:08:52.5341072] [Lua] [Patch] Live instance not found for 'Mesh_Body.CH_P_EVE_01_AnimBP_Studio_C'[2025-07-24 15:08:52.5341845] Starting Lua mod 'CheatManagerEnablerMod'

956 [2025-07-24 15:08:52.5371595] [RegisterHook] Registered native hook (1, 2) for Function /Script/Engine.PlayerController:ClientRestart
957 [2025-07-24 15:08:52.5372308] Mod 'ActorDumperMod' disabled in mods.txt.
958 [2025-07-24 15:08:52.5372393] Starting Lua mod 'ConsoleCommandsMod'
959 [2025-07-24 15:08:52.5459782] Starting Lua mod 'ConsoleEnablerMod'
960 [2025-07-24 15:08:52.5509616] [RegisterHook] Registered native hook (3, 4) for Function /Script/Engine.PlayerController:ClientRestart
961 [2025-07-24 15:08:52.5510278] Mod 'SplitScreenMod' disabled in mods.txt.
962 [2025-07-24 15:08:52.5510372] Starting Lua mod 'LineTraceMod'
963 [2025-07-24 15:08:52.5568042] [Lua] [LineTraceMod] KismetSystemLibrary: KismetSystemLibrary /Script/Engine.Default__KismetSystemLibrary
964 [2025-07-24 15:08:52.5589013] [Lua] [LineTraceMod] KismetMathLibrary: KismetMathLibrary /Script/Engine.Default__KismetMathLibrary
965 [2025-07-24 15:08:52.5589718] Starting Lua mod 'BPML_GenericFunctions'
966 [2025-07-24 15:08:52.5604039] Starting Lua mod 'BPModLoaderMod'
967 [2025-07-24 15:08:52.6100073] [Lua] [BPModLoaderMod] Mods/BPModLoaderMod/load_order.txt not present or no matching mods, loading all BP mods in random order.
968 [2025-07-24 15:08:52.6100615] [Lua] [BPModLoaderMod] SBGhostMOD_P == table: 000000002FF6A3E0
969 [2025-07-24 15:08:52.6100700] [Lua] [BPModLoaderMod]     AssetName == ModActor_C
970 [2025-07-24 15:08:52.6100843] [Lua] [BPModLoaderMod]     AssetPath == /Game/Mods/SBGhostMOD_P/ModActor
971 [2025-07-24 15:08:52.6100926] [Lua] [BPModLoaderMod]     AssetNameAsFName == FNameUserdata: 000000002FF358C8
972 [2025-07-24 15:08:52.6100989] [Lua] [BPModLoaderMod]     Name == SBGhostMOD_P
973 [2025-07-24 15:08:52.6102492] Mod 'jsbLuaProfilerMod' disabled in mods.txt.
974 [2025-07-24 15:08:52.6102653] Starting Lua mod 'Keybinds'
975 [2025-07-24 15:08:52.6121353] Starting mods (from enabled.txt, no defined load order)...
976 [2025-07-24 15:08:52.6139964] Event loop start
977 [2025-07-24 15:08:54.3751828] [Lua] ConsoleClass, GameViewport, or ViewportConsole is invalid
978 [2025-07-24 15:08:54.3845615] [Lua] [BPModLoaderMod] Loading mod: SBGhostMOD_P
979 [2025-07-24 15:08:54.4007457] [Lua] [BPModLoaderMod] Actor: ModActor_C /Temp/Untitled_0.Untitled:PersistentLevel.ModActor_C_2147482582
980 [2025-07-24 15:08:55.6963228] [Lua] [CheatManager Creator] Constructed CheatManager [0x88DB7100]
981 [2025-07-24 15:08:55.6963806] [Lua] [CheatManager Creator] Enabled CheatManager
982 [2025-07-24 15:08:55.6988661] [Lua] [ConsoleEnabler] ConsoleKey[1]: Tilde
983 [2025-07-24 15:08:55.6989257] [Lua] [ConsoleEnabler] ConsoleKey[2]: F10
984 [2025-07-24 15:08:55.7002445] Unregistering native pre-hook (3) for /Script/Engine.PlayerController:ClientRestart
985 [2025-07-24 15:08:55.7002824] Unregistering native post-hook (4) for /Script/Engine.PlayerController:ClientRestart
986 [2025-07-24 15:08:55.8420784] [Lua] [BPModLoaderMod] Loading mod: SBGhostMOD_P
987 [2025-07-24 15:08:55.8870605] [Lua] [BPModLoaderMod] Actor: ModActor_C /Game/Lobby/Lobby.LOBBY:PersistentLevel.ModActor_C_2147482471

用 ue4ss 做的 mod, 就是放在 ue4ss/Mods, Camera Control mod 就是放在這。

另外還有放在 /home/deck/.local/share/Steam/steamapps/common/StellarBladeDemo/SB/Content/Paks/LogicMods, CNS mod 就放在這。

ue4ss 裝好有個 JiggleUpdate mod, 成功啟用的話, 就可以在 list 3 L954 ~ L955 看到載入 JiggleUpdate, 這個是加強抖動效果。

2025年8月25日 星期一

劍星 跳極樂淨土舞蹈 mod

Garnidelia - Gokuraku Jodo Motion with Music mod 是一個很特別的 mod, 可以讓 Eve 跳極樂淨土舞蹈, 當然, 這時候無法進行遊戲, 單純看 eve 跳舞, 安裝過程複雜了一些, 不過是值得的。

Gokuraku Jodo Motion with Music mod 需要先安裝以下 mod:
  1. MyAnimsJiggleMod
  2. toggledev.vbs
  3. ue4ss
ue4ss 是很重要的底層 mod, 就算不用這個 mod, 建議還是裝起來, 很多有趣的 mod 都會需要 ue4ss, 雖然有時候會造成遊戲不穩開不起來, 但是還是值得使用, 通常是更新才會遇到遊戲不穩開不起來的情形。

參考: 安裝劍星 ue4ss mod

toggledev.vbs (這是一個 vb script, 看起來只是修改 UE4SS-settings.ini) 放到 StellarBlade\SB\Binaries\Win64\ue4ss\

AnimJiggleAdd_P (MyAnimsJiggleMod 作者提供的抖動效果 mod, 不一定要安裝, 抖動效果不同而已) 放到 StellarBlade\SB\Content\Paks\~mods

Adictional activation key F1-1802-2025-1755124067.rar (Gokuraku Jodo Motion with Music mod) 解開放到 StellarBlade\SB\Content\Paks\LogicMods\Gokurakujodo_P

adictional file-1802-2025-1754979161.rar 這是作者未來會用到的檔案, 我目前沒裝這個檔案。

照著 list 1. L15 ~ L37 ue4sssettings.ini 的設定, 修改 ue4sssettings.ini。

toggledev.vbs
 1 Dim fso, file, lines, path, line, out, i
 2 Set fso = CreateObject("Scripting.FileSystemObject")
 3 
 4 path = "UE4SS-settings.ini"
 5 Set file = fso.OpenTextFile(path, 1, False)
 6 lines = Split(file.ReadAll, vbCrLf)
 7 file.Close
 8 
 9 For i = 0 To UBound(lines)
10     line = lines(i)
11     If InStr(line, "ConsoleEnabled = 0") Then
12         lines(i) = Replace(line, "0", "1")
13     ElseIf InStr(line, "ConsoleEnabled = 1") Then
14         lines(i) = Replace(line, "1", "0")
15     ElseIf InStr(line, "GuiConsoleEnabled = 0") Then
16         lines(i) = Replace(line, "0", "1")
17     ElseIf InStr(line, "GuiConsoleEnabled = 1") Then
18         lines(i) = Replace(line, "1", "0")
19     ElseIf InStr(line, "GuiConsoleVisible = 0") Then
20         lines(i) = Replace(line, "0", "1")
21     ElseIf InStr(line, "GuiConsoleVisible = 1") Then
22         lines(i) = Replace(line, "1", "0")
23     ElseIf InStr(line, "bUseUObjectArrayCache = false") Then
24         lines(i) = Replace(line, "false", "true")
25     ElseIf InStr(line, "bUseUObjectArrayCache = true") Then
26         lines(i) = Replace(line, "true", "false")
27     End If
28 Next
29 
30 Set out = fso.OpenTextFile(path, 2, False)
31 For i = 0 To UBound(lines)
32     out.WriteLine lines(i)
33 Next
34 out.Close
35 
36 MsgBox "Settings toggled", 64, "Done"


list 1. 節錄 Garnidelia - Gokuraku Jodo Motion with Music mod 安裝說明
 1 Motion mod that makes Eve dances Gokuraku Jodo from Garnidelia requires UE4SS
 2 
 3 Motion actvation by keyboard Num.5
 4 
 5 Added a file version with F1 key activation for those who don't have numeric keyboard
 6 
 7 Installation folder >>> LogicMods
 8 
 9 how installation path have to look be : StellarBlade\SB\Content\Paks\LogicMods\Gokurakujodo_P
10 
11 
12 For jiggle physics use my jiggle mod: https://www.nexusmods.com/stellarblade/mods/1871
13 
14 In your ue4sssettings.ini have sure these parameters are this way:
15 [Debug]
16 ; Whether to enable the external UE4SS debug console.
17 ConsoleEnabled = 1
18 GuiConsoleEnabled = 1
19 GuiConsoleVisible = 1
20 
21 ; The API that will be used to render the GUI debug window.
22 ; Valid values (case-insensitive): dx11, d3d11, opengl
23 ; Default: opengl
24 GraphicsAPI = dx11
25 
26 [Hooks]
27 HookProcessInternal = 1
28 HookProcessLocalScriptFunction = 1
29 HookInitGameState = 1
30 HookLoadMap = 1
31 HookCallFunctionByNameWithArguments = 1
32 HookBeginPlay  = 0
33 HookLocalPlayerExec = 1
34 HookAActorTick = 1
35 HookEngineTick = 1
36 HookGameViewportClientTick = 1
37 FExecVTableOffsetInLocalPlayer = 0x28
38 
39 Download the toggledev.vbs and place it on your eu4ss folder this way : StellarBlade\SB\Binaries\Win64\ue4ss
40 
41 The mod have the music so let it play till the end :v cause it dont stop if you stops the dance(idk how to make a control to music stops, only to play XD)
42 
43 link of the ue4ss version that i using:
44 
45 Ue4Ss that i using
46 
47 https://github.com/Chrisr0/RE-UE4SS/releases


裝好之後按下最右邊的數字按鍵 5, 就可以發動跳舞功能, 如果沒有數字按鍵的鍵盤, 也可以按下 F1 觸發。



由於可以搭配 cns 使用, 弄了蕾雯的版本, 蕾雯飄逸的長髮還蠻特別。



按下 F1 開始跳舞, 再次按下 F1 會停止, 但是極樂淨土音樂會持續播放到結束, 作者還不知道怎麼中斷音樂, 也許之後的版本會改善。跳舞期間可以移動視角, 看看不同的角度。



在跳舞的狀態下, 如果被怪物襲擊, 也是會被打死的, 另外操作人物摔下懸崖一樣會死。



2025年8月20日 星期三

pc9801 rusty 中文化

Reputation is currency. Relationships are long-term leverage.
pc9801 的日文編碼是「Shift-JIS」, 找出「ゲームスタート」的「Shift-JIS」編碼, 在 JO.EXE 執行檔內尋找, 再把「遊戲開始」的「Shift-JIS」編碼找出, 改成這個「遊戲開始」的「Shift-JIS」編碼, 剩下的部份用 0x00 覆蓋。

list 1. ゲームスタート
1descent@deb64:hdi$ echo "ゲームスタート" | iconv -f UTF-8 -t SHIFT-JIS > s2.jis
2 descent@deb64:hdi$ hexdump -C s2.jis
3 00000000  83 51 81 5b 83 80 83 58  83 5e 81 5b 83 67 0a
4 0000000f

...

7 descent@u64:bjd$ echo "遊戲開始" | iconv -f UTF-8 -t SHIFT-JIS > s2.jis
8 descent@u64:bjd$ hexdump -C s2.jis
9 00000000  97 56 9d 45 8a 4a 8e 6e  0a


把 list 2 的藍色換成紅色部份的數字, 就完成了「ゲームスタート」的中文化, 使用的是日文漢字, 並不是 big5/unicode 的中文編碼。

list 2. JO.EXE
00006C30  00 00 00 83  51 81 7C 83   80 83 58 83  5E 81 7C 83
00006C40  67 00 83 52  83 93 83 65   83 42 83 6A  83 85 81 7C 

...

00006C30  00 00 00 97  56 9D 45 8A   4A 8E 6E 00  00 00 00 00
00006C40  00 00 E3 8B  E3 94 97 56   9D 45 00 00  00 00 00 00
fig 1. dos/v 日文版
fig 2. pc9801 日文版本改為中文
另外還有遊戲劇情的部份, 這邊我就沒有任何想法, 不知道怎麼下手, 一堆檔案根本不知道怎麼分析。看了「夜行侦探 EVE burst error 中文化分析」這系列, 還是沒什麼頭緒, 好難。

2025年8月7日 星期四

讀取 jpeg 圖片, 本來以為是透明效果, 不過這個好像是漸層效果顯示, 另外實做了透明效果。

fig 1. 棄捐勿復道, 努力加餐飯。
這是我在 2002 寫的程式, 對透明色處理有興趣, 想自己寫出來, 找了很久, 忘記在哪本書看到這個演算法, 透過 linux/sgvalib 實做出來, 寫出來時還蠻開心的, 那時候用的版本控制軟體是 rcs。

對於電腦繪圖方式有興趣, 研究了 vga 模式和圖形顯示的原理, 如果用 qt 之類的, 很容易就可以完成秀出一張圖片的功能, 甚至還可以作到縮放, 但我想多知道一些, 就研究了這些技術, 大部分是從 dos 時代的繪圖相關書籍學習。

2002 沒有 chatgpt, 光是使用 jpeg lib 就難倒我, 啃著英文文件, 也不知道有沒看懂, 硬是讓我成功解出 jpeg 內容, 現在有 chatgpt, 應該秒會用吧!

在 20250804 想到 pc9801 遊戲 16 色時突然想到這個, 把這程式以 framebuffer 重新改寫, 沒辦法, svgalib 可能沒辦法在現今的平台執行, 呈現的效果看起來還蠻像一回事。

重新檢視演算法, 並沒有和背景色做運算, 我傻眼, 這好像不是透明演算法。問了 chatgpt 這個演算法, 還真的不是, chatgpt 說這是漸層演算法, 整整搞錯 23 年。



framebuffer 繪圖則是問 chatgpt, 節省不少時間。

由於在螢幕上顯示圖形非常複雜, 需要理解 vga 顯示模式和影像格式, 我挑了最簡單的方式做, 在 640x480 24bit color 上顯示 24bit jpeg 圖檔, 可以避開 Quantization + Dithering 的問題, 現在有 chatgpt, 比較容易找到這 2 個演算法, 23 年科技進步的太大了。

在 2025 年, 這些技術也不需要, 2025 年應該不會有 256 色的顯示模式了。



透明色公式是:
final = src_color * alpha + background_color * (1 - alpha);

重新挑戰透明色, 麻煩的是要怎麼取得背景圖, 就先不處理這個, 直接拿2張圖做透明計算。

list 1. fb-jpeg.cpp
  1 /*
  2  *
  3  * $Author: descent $
  4  * $Date: 2002/06/20 02:55:23 $
  5  * $Id: jpeg.cpp,v 1.2 2002/06/20 02:55:23 descent Exp descent $
  6  * $Revision: 1.2 $
  7  * 程式功能:用 jpeg library 來讀取 jpeg 圖檔,改用 framebuffer 來秀圖
  8  * 	     並加入XX效果。
  9  */
 10 
 11 #include <stdio.h>
 12 #include <stdlib.h>
 13 #include <fcntl.h>
 14 #include <linux/fb.h>
 15 #include <sys/mman.h>
 16 #include <sys/ioctl.h>
 17 #include <unistd.h>
 18 #include <string.h>
 19 #include <stdint.h>
 20 
 21 #include <vector>
 22 #include <iostream>
 23 #include <string>
 24 
 25 #include <jpeglib.h>
 26 #include <jerror.h>
 27 
 28 using namespace std;
 29 
 30 uint8_t *fbp;
 31 struct fb_var_screeninfo vinfo;
 32 struct fb_fix_screeninfo finfo;
 33 
 34 struct Color
 35 {
 36   Color (unsigned char r, unsigned char g, unsigned char b):r_ (r), g_ (g),
 37     b_ (b)
 38   {
 39   }
 40   unsigned char r () const
 41   {
 42     return r_;
 43   }
 44   unsigned char g () const
 45   {
 46     return g_;
 47   }
 48   unsigned char b () const
 49   {
 50     return b_;
 51   }
 52 private:
 53   unsigned char r_, g_, b_;
 54 };
 55 
 56 class Bitmap
 57 {
 58 public:
 59   Bitmap (int width, int height):width_ (width), height_ (height)
 60   {
 61   }
 62   void set_color (const std::vector < Color > &color)
 63   {
 64     color_ = color;
 65   }
 66   const std::vector < Color > &color_pixel () const
 67   {
 68     return color_;
 69   }
 70   int w () const
 71   {
 72     return width_;
 73   }
 74   int h () const
 75   {
 76     return height_;
 77   }
 78 private:
 79   int width_, height_;
 80   std::vector < Color > color_;
 81 };
 82 
 83 int r = 127;
 84 int g = 78;
 85 int b = 50;
 86 int color_value;
 87 
 88 void show(const Bitmap & bitmap, int x, int y, int level = 256)
 89 {
 90   //bitmap.color_pixel();
 91   std::vector < Color >::const_iterator it = bitmap.color_pixel ().begin ();
 92   //gl_getpalettecolor(color_value,&r,&g,&b);
 93   
 94   for (int i = 0; i < bitmap.h (); ++i)
 95   {
 96     usleep(1000);
 97     for (int j = 0; j < bitmap.w (); ++j)
 98     {
 99       //gl_setpixelrgb(x+j,y+i,(*it).r()*level/256,(*it).g()*level/256,(*it).b()*level/256);
100       int pix_r = (*it).r ();
101       int pix_g = (*it).g ();
102       int pix_b = (*it).b ();
103       //gl_setpixelrgb(x+j,y+i,r +(pix_r - r)*level/256, g +(pix_g - g)*level/256, b + (pix_b - b)*level/256);
104       //gl_setpixelrgb(x+j,y+i,pix_r*level+r*(1-level),pix_g*level+g*(1-level),pix_b*level+b*(level));
105       long location = (y+i)*finfo.line_length + (x+j) * 4; // 4 bytes per pixel
106       uint32_t *pixel = (uint32_t *)(fbp + location);
107       //printf("i: %d, j: %d, pixel: %p, fbp: %p\n", i, j, pixel, fbp);
108       #if 1
109       if (i <= 120)
110       {
111 	//gl_setpixelrgb (x + j, y + i, (*it).r (), (*it).g (), (*it).b ());
112             // 32-bit ARGB,alpha=0xFF (不透明),紅色R=0xFF, G=0x00, B=0x00
113             // 寫法是 0xAARRGGBB
114         unsigned int val = 0xff000000;
115         val |= ((*it).r() << 16);
116         val |= ((*it).g() << 8);
117         val |= (*it).b();
118 	*pixel = val;
119             //*pixel = 0xFFFF0000;
120       }
121       else
122       {
123         unsigned int val = 0xff000000;
124         val |= (((*it).r () + (r - (*it).r ()) * level / 256) << 16);
125         val |= (((*it).g () + (g - (*it).g ()) * level / 256) << 8);
126         val |= ((*it).b () + (b - (*it).b ()) * level / 256);
127 	*pixel = val;
128             //*pixel = 0xFFFF0000;
129         #if 0
130 	gl_setpixelrgb (x + j, y + i,
131 			(*it).r () + (r - (*it).r ()) * level / 256,
132 			(*it).g () + (g - (*it).g ()) * level / 256,
133 			(*it).b () + (b - (*it).b ()) * level / 256);
134         #endif
135       }
136       #endif
137       ++it;
138     }
139   }
140   //for ( ; it !=bitmap.color_pixel().end() ; ++it)
141 
142 }
143 
144 void get_hex (char c, char hex[])
145 {
146   char ascii[] = "0123456789abcdef";
147   int low = (c & 0x0f);
148   int high = ((c >> 4) & 0x0f);
149   hex[0] = ascii[high];
150   hex[1] = ascii[low];
151 }
152 
153 int main(int argc, char *argv[])
154 {
155   struct jpeg_decompress_struct cinfo;
156   struct jpeg_error_mgr jerr;
157 
158   cinfo.err = jpeg_std_error (&jerr);
159   jpeg_create_decompress (&cinfo);
160 
161   if (argc < 2)
162   {
163     cout << "Enter a file name" << endl;
164     return -1;
165   }
166 
167   string filename = argv[1];
168   FILE *infile;
169   if ((infile = fopen (filename.c_str (), "rb")) == NULL)
170   {
171     fprintf (stderr, "cann't open file");
172     return -1;
173   }
174   //int level=255;
175   //if (argc>=3)
176   //level=atoi(argv[2]);
177   jpeg_stdio_src (&cinfo, infile);
178   jpeg_read_header (&cinfo, true);
179   // set parameters fro decompress
180   //cinfo.scale_num=1;
181   //cinfo.scale_denom=2;
182   //cinfo.output_width=640;
183   //cinfo.output_height=480;
184   //cinfo.image_height=480;
185   jpeg_start_decompress (&cinfo);
186 
187   JSAMPARRAY buffer;
188   int row_stride = cinfo.output_width * cinfo.output_components;
189   int jpeg_width = cinfo.output_width;
190   buffer =
191     (*cinfo.mem->alloc_sarray) ((j_common_ptr) & cinfo, JPOOL_IMAGE,
192 				row_stride, 1);
193   JSAMPROW ptr = NULL;
194   int i = 0;
195 
196   std::vector < Color > color;
197   Bitmap bitmap (cinfo.output_width, cinfo.output_height);
198   while (cinfo.output_scanline < cinfo.output_height)
199   {
200     jpeg_read_scanlines (&cinfo, buffer, 1);
201     ptr = buffer[0];
202     //cout << "line " << ++i << " : " << endl;
203     int index = 0;
204     // scanline 是圖檔的寬度 * 顏色的數目,在 full color 一個 pixel 要三個 byte
205     //for (int col=0 ; col < cinfo.image_width * cinfo.output_components ; col++)
206     for (int col = 0; col < cinfo.image_width; col++)
207     {
208       //cout << index++ << " : GETJSAMPLE(*ptr++) : " << GETJSAMPLE(*ptr++) << endl;
209       //bitmap.push_back(GETJSAMPLE(*ptr++));
210       //gl_setpixelrgb(x+dx,y,GETJSAMPLE(*ptr)*level/256,GETJSAMPLE(*(ptr+1))*level/256,GETJSAMPLE(*(ptr+2))*level/256);
211       color.
212 	push_back (Color
213 		   (GETJSAMPLE (*ptr), GETJSAMPLE (*(ptr + 1)),
214 		    GETJSAMPLE (*(ptr + 2))));
215 
216 #ifdef DUMP_BITMAP_DATA
217       char h[2];
218       get_hex(GETJSAMPLE(*ptr), h);
219       cout << h[0] << h[1] << " ";
220       get_hex(GETJSAMPLE(*(ptr+1)), h);
221       cout << h[0] << h[1] << " ";
222       get_hex(GETJSAMPLE(*(ptr+2)), h);
223       cout << h[0] << h[1] << " ";
224     cout << endl;
225 #endif
226       //gl_setpixelrgb(x+dx,y,GETJSAMPLE(*ptr),GETJSAMPLE(*(ptr+1)),GETJSAMPLE(*(ptr+2)));
227       //dx++;
228       ptr += 3;
229     }
230     //dx=0;
231     //y++;
232 #ifdef DUMP_BITMAP_DATA
233     cout << endl;
234 #endif
235   }
236   bitmap.set_color (color);
237   //vga_setmode(TEXT);
238   int color_components = cinfo.output_components;
239   //cout << "cinfo.output_components : " << cinfo.output_components << endl;
240   jpeg_finish_decompress (&cinfo);
241   jpeg_destroy_decompress (&cinfo);
242 
243   fclose (infile);
244 
245 
246 
247 
248     int fb_fd = open("/dev/fb0", O_RDWR);
249     if (fb_fd == -1) {
250         perror("open fail");
251         return 1;
252     }
253 
254 
255     if (ioctl(fb_fd, FBIOGET_FSCREENINFO, &finfo) == -1) {
256         perror("FBIOGET_FSCREENINFO");
257         close(fb_fd);
258         return 1;
259     }
260 
261     if (ioctl(fb_fd, FBIOGET_VSCREENINFO, &vinfo) == -1) {
262         perror("FBIOGET_VSCREENINFO");
263         close(fb_fd);
264         return 1;
265     }
266 
267     printf("Resolution: %dx%d, %dbpp\n", vinfo.xres, vinfo.yres, vinfo.bits_per_pixel);
268 
269     if (vinfo.bits_per_pixel != 32) {
270         fprintf(stderr, "This program only supports 32-bit framebuffer.\n");
271         close(fb_fd);
272         return 1;
273     }
274 
275     long screensize = vinfo.yres * finfo.line_length;
276     fbp = (uint8_t *)mmap(0, screensize, PROT_READ | PROT_WRITE, MAP_SHARED, fb_fd, 0);
277     if (fbp == MAP_FAILED) {
278         perror("mmap");
279         close(fb_fd);
280         return 1;
281     }
282 
283     printf("load jpg\n");
284 
285     int square_x = 300;
286     int square_y = 300;
287     int size = 80;
288     show(bitmap, 300, 200, 100);
289 
290 
291 #if 0
292     for (int y = 0; y < size; y++) {
293         for (int x = 0; x < size; x++) {
294             int px = square_x + x;
295             int py = square_y + y;
296 
297             long location = py * finfo.line_length + px * 4; // 4 bytes per pixel
298 
299             // 32-bit ARGB,alpha=0xFF (不透明),紅色R=0xFF, G=0x00, B=0x00
300             // 寫法是 0xAARRGGBB
301             uint32_t *pixel = (uint32_t *)(fbp + location);
302             *pixel = 0xFFFF0000;
303         }
304     }
305     #endif
306 
307     munmap(fbp, screensize);
308     close(fb_fd);
309 
310     return 0;
311 }

拜 chatgpt 之強大, 透明效果沒花太多時間就完成, 這次應該就是透明效果了, 需要用底圖來計算。



list 2. fb-tran.cpp
  1 /*
  2  *
  3  * $Author: descent $
  4  * $Date: 2002/06/20 02:55:23 $
  5  * $Id: jpeg.cpp,v 1.2 2002/06/20 02:55:23 descent Exp descent $
  6  * $Revision: 1.2 $
  7  * 程式功能:用 jpeg library 來讀取 jpeg 圖檔,改用 framebuffer 來秀圖
  8  * 	     並加入透明效果。
  9  */
 10 
 11 #include <stdio.h>
 12 #include <stdlib.h>
 13 #include <fcntl.h>
 14 #include <linux/fb.h>
 15 #include <sys/mman.h>
 16 #include <sys/ioctl.h>
 17 #include <unistd.h>
 18 #include <string.h>
 19 #include <stdint.h>
 20 
 21 #include <vector>
 22 #include <iostream>
 23 #include <string>
 24 
 25 #include <jpeglib.h>
 26 #include <jerror.h>
 27 
 28 using namespace std;
 29 
 30 uint8_t *fbp;
 31 struct fb_var_screeninfo vinfo;
 32 struct fb_fix_screeninfo finfo;
 33 
 34 struct Color
 35 {
 36   Color (unsigned char r, unsigned char g, unsigned char b):r_ (r), g_ (g),
 37     b_ (b)
 38   {
 39   }
 40   unsigned char r () const
 41   {
 42     return r_;
 43   }
 44   unsigned char g () const
 45   {
 46     return g_;
 47   }
 48   unsigned char b () const
 49   {
 50     return b_;
 51   }
 52 private:
 53   unsigned char r_, g_, b_;
 54 };
 55 
 56 class Bitmap
 57 {
 58 public:
 59   Bitmap(int width, int height):width_ (width), height_ (height)
 60   {
 61   }
 62   Bitmap():width_ (0), height_ (0)
 63   {
 64   }
 65   void set_w_h(int w, int h)
 66   {
 67     width_ = w;
 68     height_ = h;
 69   }
 70   void set_color (const std::vector < Color > &color)
 71   {
 72     color_ = color;
 73   }
 74   const std::vector < Color > &color_pixel () const
 75   {
 76     return color_;
 77   }
 78   int w () const
 79   {
 80     return width_;
 81   }
 82   int h () const
 83   {
 84     return height_;
 85   }
 86 private:
 87   int width_, height_;
 88   std::vector < Color > color_;
 89 };
 90 
 91 int r = 127;
 92 int g = 78;
 93 int b = 50;
 94 int color_value;
 95 
 96 //final = src_color * alpha + background_color * (1 - alpha);
 97 
 98 uint8_t alpha_blend(uint8_t fg, uint8_t bg, uint8_t alpha) {
 99     // alpha: 0~255, fg 前景, bg 背景
100     return (fg * alpha + bg * (255 - alpha)) / 255;
101 }
102 
103 void show(const Bitmap& bitmap, int x, int y, int level, const Bitmap& bg_bitmap)
104 {
105   //bitmap.color_pixel();
106   std::vector < Color >::const_iterator it = bitmap.color_pixel ().begin ();
107 
108   std::vector < Color >::const_iterator bg_it = bg_bitmap.color_pixel ().begin ();
109   printf("bitmap.h(): %d, bitmap.w(): %d\n", bitmap.h(), bitmap.w());
110   printf("bg_bitmap.h(): %d, bg_bitmap.w(): %d\n", bg_bitmap.h(), bg_bitmap.w());
111 
112   //gl_getpalettecolor(color_value,&r,&g,&b);
113   
114   for (int i = 0; i < bitmap.h (); ++i)
115   {
116     //usleep(1000);
117     for (int j = 0; j < bitmap.w (); ++j)
118     {
119       //gl_setpixelrgb(x+j,y+i,(*it).r()*level/256,(*it).g()*level/256,(*it).b()*level/256);
120       int pix_r = (*it).r ();
121       int pix_g = (*it).g ();
122       int pix_b = (*it).b ();
123 
124 
125       
126 
127       //gl_setpixelrgb(x+j,y+i,r +(pix_r - r)*level/256, g +(pix_g - g)*level/256, b + (pix_b - b)*level/256);
128       //gl_setpixelrgb(x+j,y+i,pix_r*level+r*(1-level),pix_g*level+g*(1-level),pix_b*level+b*(level));
129       long location = (y+i)*finfo.line_length + (x+j) * 4; // 4 bytes per pixel
130       uint32_t *pixel = (uint32_t *)(fbp + location);
131       //printf("i: %d, j: %d, pixel: %p, fbp: %p\n", i, j, pixel, fbp);
132 	//gl_setpixelrgb (x + j, y + i, (*it).r (), (*it).g (), (*it).b ());
133             // 32-bit ARGB,alpha=0xFF (不透明),紅色R=0xFF, G=0x00, B=0x00
134             // 寫法是 0xAARRGGBB
135         unsigned int val = 0x00000000;
136         unsigned char new_r, new_g, new_b;
137 
138         //double alpha = 0.8;
139         unsigned char alpha = 100;
140         #if 0
141         new_r = (unsigned char)((*it).r() * alpha + (*bg_it).r() *(255-alpha))/255;
142         new_b = (unsigned char)((*it).b() * alpha + (*bg_it).b() *(255-alpha))/255;
143         new_g = (unsigned char)((*it).g() * alpha + (*bg_it).g() *(255-alpha))/255;
144         #endif
145 
146         new_r = alpha_blend((*it).r(), (*bg_it).r(), alpha);
147         new_g = alpha_blend((*it).g(), (*bg_it).g(), alpha);
148         new_b = alpha_blend((*it).b(), (*bg_it).b(), alpha);
149 
150 
151         #if 0
152         new_r =  (*bg_it).r();
153         new_g =  (*bg_it).g();
154         new_b =  (*bg_it).b();
155         #endif
156 
157 
158         val |= ((*it).r() << 16);
159         val |= ((*it).g() << 8);
160         val |= (*it).b();
161 
162         unsigned int bg_val = 0x00000000;
163         bg_val |= ((*bg_it).r() << 16);
164         bg_val |= ((*bg_it).g() << 8);
165         bg_val |= (*bg_it).b();
166 
167         unsigned int final_val = 0xff000000;
168 
169         //final_val |= 0xff << 24;
170         final_val |= new_r << 16;
171         final_val |= new_g << 8;
172         final_val |= new_b;
173 
174 	*pixel = final_val;
175       #if 0
176       if (i <= 120)
177       {
178 	//gl_setpixelrgb (x + j, y + i, (*it).r (), (*it).g (), (*it).b ());
179             // 32-bit ARGB,alpha=0xFF (不透明),紅色R=0xFF, G=0x00, B=0x00
180             // 寫法是 0xAARRGGBB
181         unsigned int val = 0xff000000;
182         val |= ((*it).r() << 16);
183         val |= ((*it).g() << 8);
184         val |= (*it).b();
185 	*pixel = val;
186             //*pixel = 0xFFFF0000;
187       }
188       else
189       {
190         unsigned int val = 0xff000000;
191         val |= (((*it).r () + (r - (*it).r ()) * level / 256) << 16);
192         val |= (((*it).g () + (g - (*it).g ()) * level / 256) << 8);
193         val |= ((*it).b () + (b - (*it).b ()) * level / 256);
194 	*pixel = val;
195             //*pixel = 0xFFFF0000;
196         #if 0
197 	gl_setpixelrgb (x + j, y + i,
198 			(*it).r () + (r - (*it).r ()) * level / 256,
199 			(*it).g () + (g - (*it).g ()) * level / 256,
200 			(*it).b () + (b - (*it).b ()) * level / 256);
201         #endif
202       }
203       #endif
204       ++it;
205       if (i < bg_bitmap.h ())
206         ++bg_it;
207     }
208   }
209   //for ( ; it !=bitmap.color_pixel().end() ; ++it)
210 
211 }
212 
213 void get_hex (char c, char hex[])
214 {
215   char ascii[] = "0123456789abcdef";
216   int low = (c & 0x0f);
217   int high = ((c >> 4) & 0x0f);
218   hex[0] = ascii[high];
219   hex[1] = ascii[low];
220 }
221 
222 int jpeg_to_bitmap(const string &filename, Bitmap &bitmap)
223 {
224   struct jpeg_decompress_struct cinfo;
225   struct jpeg_error_mgr jerr;
226 
227   cinfo.err = jpeg_std_error (&jerr);
228   jpeg_create_decompress (&cinfo);
229 
230   FILE *infile;
231   if ((infile = fopen (filename.c_str (), "rb")) == NULL)
232   {
233     fprintf (stderr, "cann't open file");
234     return -1;
235   }
236   //int level=255;
237   //if (argc>=3)
238   //level=atoi(argv[2]);
239   jpeg_stdio_src (&cinfo, infile);
240   jpeg_read_header (&cinfo, true);
241   // set parameters fro decompress
242   //cinfo.scale_num=1;
243   //cinfo.scale_denom=2;
244   //cinfo.output_width=640;
245   //cinfo.output_height=480;
246   //cinfo.image_height=480;
247   jpeg_start_decompress (&cinfo);
248 
249   JSAMPARRAY buffer;
250   int row_stride = cinfo.output_width * cinfo.output_components;
251   int jpeg_width = cinfo.output_width;
252   buffer =
253     (*cinfo.mem->alloc_sarray) ((j_common_ptr) & cinfo, JPOOL_IMAGE,
254 				row_stride, 1);
255   JSAMPROW ptr = NULL;
256   int i = 0;
257 
258   std::vector < Color > color;
259   bitmap.set_w_h(cinfo.output_width, cinfo.output_height);
260   while (cinfo.output_scanline < cinfo.output_height)
261   {
262     jpeg_read_scanlines (&cinfo, buffer, 1);
263     ptr = buffer[0];
264     //cout << "line " << ++i << " : " << endl;
265     int index = 0;
266     // scanline 是圖檔的寬度 * 顏色的數目,在 full color 一個 pixel 要三個 byte
267     //for (int col=0 ; col < cinfo.image_width * cinfo.output_components ; col++)
268     for (int col = 0; col < cinfo.image_width; col++)
269     {
270       //cout << index++ << " : GETJSAMPLE(*ptr++) : " << GETJSAMPLE(*ptr++) << endl;
271       //bitmap.push_back(GETJSAMPLE(*ptr++));
272       //gl_setpixelrgb(x+dx,y,GETJSAMPLE(*ptr)*level/256,GETJSAMPLE(*(ptr+1))*level/256,GETJSAMPLE(*(ptr+2))*level/256);
273       color.
274 	push_back (Color
275 		   (GETJSAMPLE (*ptr), GETJSAMPLE (*(ptr + 1)),
276 		    GETJSAMPLE (*(ptr + 2))));
277 
278 #ifdef DUMP_BITMAP_DATA
279       char h[2];
280       get_hex(GETJSAMPLE(*ptr), h);
281       cout << h[0] << h[1] << " ";
282       get_hex(GETJSAMPLE(*(ptr+1)), h);
283       cout << h[0] << h[1] << " ";
284       get_hex(GETJSAMPLE(*(ptr+2)), h);
285       cout << h[0] << h[1] << " ";
286     cout << endl;
287 #endif
288       //gl_setpixelrgb(x+dx,y,GETJSAMPLE(*ptr),GETJSAMPLE(*(ptr+1)),GETJSAMPLE(*(ptr+2)));
289       //dx++;
290       ptr += 3;
291     }
292     //dx=0;
293     //y++;
294 #ifdef DUMP_BITMAP_DATA
295     cout << endl;
296 #endif
297   }
298   bitmap.set_color (color);
299   //vga_setmode(TEXT);
300   int color_components = cinfo.output_components;
301   //cout << "cinfo.output_components : " << cinfo.output_components << endl;
302   jpeg_finish_decompress (&cinfo);
303   jpeg_destroy_decompress (&cinfo);
304 
305   fclose (infile);
306   return 0;
307 }
308 
309 int main(int argc, char *argv[])
310 {
311   if (argc < 2)
312   {
313     cout << "Enter 2 file name" << endl;
314     return -1;
315   }
316 
317   //string filename = argv[1];
318 
319   Bitmap fg_bitmap;
320   jpeg_to_bitmap(argv[1], fg_bitmap);
321 
322   Bitmap bg_bitmap;
323   jpeg_to_bitmap(argv[2], bg_bitmap);
324 
325 
326 
327     int fb_fd = open("/dev/fb0", O_RDWR);
328     if (fb_fd == -1) {
329         perror("open fail");
330         return 1;
331     }
332 
333 
334     if (ioctl(fb_fd, FBIOGET_FSCREENINFO, &finfo) == -1) {
335         perror("FBIOGET_FSCREENINFO");
336         close(fb_fd);
337         return 1;
338     }
339 
340     if (ioctl(fb_fd, FBIOGET_VSCREENINFO, &vinfo) == -1) {
341         perror("FBIOGET_VSCREENINFO");
342         close(fb_fd);
343         return 1;
344     }
345 
346     printf("Resolution: %dx%d, %dbpp\n", vinfo.xres, vinfo.yres, vinfo.bits_per_pixel);
347 
348     if (vinfo.bits_per_pixel != 32) {
349         fprintf(stderr, "This program only supports 32-bit framebuffer.\n");
350         close(fb_fd);
351         return 1;
352     }
353 
354     long screensize = vinfo.yres * finfo.line_length;
355     fbp = (uint8_t *)mmap(0, screensize, PROT_READ | PROT_WRITE, MAP_SHARED, fb_fd, 0);
356     if (fbp == MAP_FAILED) {
357         perror("mmap");
358         close(fb_fd);
359         return 1;
360     }
361 
362     printf("load jpg\n");
363 
364     int square_x = 300;
365     int square_y = 300;
366     int size = 80;
367 
368     #if 0
369     show(bg_bitmap, 300, 200, 100, );
370     sleep(2);
371     #endif
372 
373     show(fg_bitmap, 300, 200, 100, bg_bitmap);
374     sleep(2);
375 
376 
377 #if 0
378     for (int y = 0; y < size; y++) {
379         for (int x = 0; x < size; x++) {
380             int px = square_x + x;
381             int py = square_y + y;
382 
383             long location = py * finfo.line_length + px * 4; // 4 bytes per pixel
384 
385             // 32-bit ARGB,alpha=0xFF (不透明),紅色R=0xFF, G=0x00, B=0x00
386             // 寫法是 0xAARRGGBB
387             uint32_t *pixel = (uint32_t *)(fbp + location);
388             *pixel = 0xFFFF0000;
389         }
390     }
391     #endif
392 
393     munmap(fbp, screensize);
394     close(fb_fd);
395 
396     return 0;
397 }

List 2 L98 是透明演算法。
g++ fb-tran.cpp -o fb-tran  -ljpeg



現在應該都是透過顯示卡來做透明效果, 很少會用 cpu 計算了。

2025年8月5日 星期二

20250621 台灣 - 名古屋 (1/7)

日期: 20250621 (6)
地點: 台灣 - 名古屋

本篇文章提到的時間均為日本時間, 沒寫單位的金額為日圓。

我不會日文, 英文也不好: 文章中有關問路或是其他問人的資訊, 都是用很克難的方式完成 (簡單英文、簡單日文、比手畫腳)。
富邦旅遊平安險

2024 遇到無法開通台灣大哥大上網卡的問題在我換了 samsung a55 之後就解決了, 果然換新手機就可以正常撥號開通, 後來到, 如果無法撥號開通, 也可以用簡訊方式來開通, 舊手機也可以正常開通。在名古屋機場就有網路可用, 不需要用機場的無線 wify。

從名古屋機場到名鐵名古屋車站已經很晚了, 先找「相鐵FRESA INN 名古屋站新幹線口」旅館。
果然如預期一般, 花了點時間找路, 找到之後到附近的「すき家」吃飯, 是 24 小時營業, 這時大約 23:00, 真的是搞很晚了, 想吃的燒肉口味沒了, 奶昔也沒了, 只吃了一般口味的燒肉丼飯, 味道很普通。



之後到「aeon MaxValu 超市」晃晃, 看了最近爭議的鮮奶議題, 來看看日本的鮮奶價格。



沒訂旅館早餐, 買了一罐低溫殺菌的當早餐喝, 332 日幣, 味道蠻濃的, 另外再去附近便利商店買麵包。附近有 lawson, 7-11, 蠻便利的。

2025年8月2日 星期六

20250726 大罷免 X 20250729 超大豪雨停班停課

20250726 是大罷免投票日, 開票結果沒有人被罷免。

有些人會為了政治立場和家人鬧翻, 這是最得不償失的事情, 在你有危難時, 家人是最後一道防線, 也是真心會幫助你度過難關的人。你所支持的政治人物是不會幫你的。千萬別為了陌生的政治人物與家人搞壞關係, 太不值得。

大罷免, 民進黨沒失敗是對的, 民進黨又沒有被罷的提案, 只有贏, 沒有輸的選項, 最差就是維持現狀, 還可以了解目前的民意, 做出應變, 不算沒收穫。

現在比較期待 2026 的選舉如何? 這個輸了才是真的輸。賴清德定調第二波罷免與公民同行 王世堅當場反對, 823 國民黨應該會感受到不小的壓力。823 的壓力一樣是在國民黨那邊, 雖然現在大多人覺得 823 可能也沒人被罷免, 但民意的變換是很難說的, 誰知道到當天又怎麼了?

NCC:網購國外藍牙產品自用 750元審查費研議免收或減收」這個費用目前是暫緩, 不知道之後是不是會繼續下去?

20250728/29 受到低壓帶與西南風影響,中南部地區28日出現明顯降雨,且入夜後西南風進一步增強為西南氣流,雨勢還會加劇。高雄市政府、台南市政府和屏東縣政府、嘉義縣政府28日晚間先後宣布,依據中央氣象署預報資料,29日雨量已達停班停課標準,高雄市、台南市、屏東縣、嘉義縣周二(29日)停止上班、停止上課。

2025/7/29停班停課全台最新通知:高雄市、台南市、屏東縣、嘉義縣停止上班上課

雖然 2025/7/29 當天風雨不大, 但這樣的決策還是鼓勵, 畢竟人民的安全是絕對最重要的, 又加上之前颱風的災害還沒完全復原。

2025年7月26日 星期六

20250727 名古屋 - 台灣 (7/7)

前一天先繞去名鐵名古屋車站, 熟悉路線, 順便把機場電車時刻表拍下來, 網路上實在不好查這資料, 拍下來仔細看, 也在前一天研究該搭那一個班次的電車。



今天行程比較趕, 13:45 飛機, 預計搭乘 10:31 名鐵名古屋往名古屋機場的電車。特級列車 1,2 車廂是指定席, 所以沒指定席票要從第3車廂坐起。另外如果這台沒搭到, 還有 11:01, 11:20 可以補救, 但後續搭機行程可能會很趕。我們到機場閘門時是 13:00, 13:20 開始登機, 大概只有 20~30 分鐘時間可以吃午餐。

經過長時間的 check-in 以及海關檢查 (檢查事項蠻繁瑣, 難怪需要那麼長時間), 終於進入機場, 搭接駁車到第二航廈之後, 便買了咖哩豬排飯, 還真的蠻好吃。





也沒什麼時間到免稅店採購, 在附近的店家做了最後的採買, 看到不錯的餅乾就買了幾包。

到桃園機場之後便是一連串的搭車惡夢, 蠻多人也是要搭捷運到桃園高鐵, 所以捷運一堆人, 然後大部分人也都是大型理箱, 造成整個車廂很擠, 到桃園高鐵之後, 也是類似現象, 能擠上車就不錯了, 完全沒有座位的票, 大行李箱在車道中佔據不少位置, 擋到一般人的搭乘, 真的很不好意思。