News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: StarOcean SNES Kanji recognition  (Read 4723 times)

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
StarOcean SNES Kanji recognition
« on: August 20, 2016, 02:47:31 pm »
Hi everybody!

I began to mess with the japanese version of this great game a month ago and decided to start an spanish translation from the japanese version instead using Dejap's. The way Dejap handled the compressed script was a bit difficult and I found easier to merge the Huffman compression with the game's LZ decompressor and after this first step, use the dictionary method to get the final word.
My scheme compresses about a 7% more than Dejap's although this is a bit tricky: I also re-compress all event LZ data and get an extra 3Kb for text.
I already proved my compression scheme in the game and it works, so the next step is to dump the japanese script and translate it into spanish. But here I get a huge problem... Is there any way to make a kanji table automatically? Or it has to be done manually, kanji per kanji? My japanese is not as good as to know all 1400 kanjis and even if it was, it is a really pain in the a** to dump each kanji to a text file.













These are all the kanji as seen on Tilemolester.

Any help?

Thanks!

tvtoon

  • Sr. Member
  • ****
  • Posts: 360
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #1 on: August 20, 2016, 10:16:39 pm »
The way to go is for stuff like pixmap and maybe optical recognition, however I don't know a good (if any exists) free tool to do this work on roman characters, let alone vicious kanjis. There is also some work to do before, dumping and tracing these characters, like you did in the images.

I always had some interest to map a table for this game, if you don't want that trouble. :)

yugisokubodai

  • Full Member
  • ***
  • Posts: 144
    • View Profile
    • Assembly
Re: StarOcean SNES Kanji recognition
« Reply #2 on: August 20, 2016, 10:42:41 pm »

手入覚双破斬空衝
裂霊雷鳴剣紅蓮閃
光蒼龍醍朱雀翔撃
七星流戟襲爪天吼
竜黒緋招訃虎来玄
武白気功掌練拳蹴
投旋風覇王弾桜花
八卦裏炸棍飛疾霧
氷凍神水月両断伸
無頼乱舞敵単体火
球攻味方人少回復
%()特技戦術装
備隊形店名前力選
択中取引指示出清
算消説明切替数減

増買売行不別作線
一体正修得度成失
敗生物学構造知識
薬草精秘的鉱宝石
道具様々信心深対
料理音楽紋章法妖
論命起源美感愛熟
合目利良質食材眼
機能強立遊世界外
存在想像許容広危
険周囲変化殺敏察
研澄未呼声超常勢
標向日進意志根性
何忍耐苦悲細業先
包丁言腕演奏器口
笛息吹状確把握再

現文筆創活動図書
究労働段科蒸留実
験勢長時間走続調
教訓定仕事従波率
真大瞬背後避場自
必複祖田挑専用闘
国騎士団伝独島幻
操肉扱格棒端地片
槍父親習族我込MUSICAL SIGN
彼女爆工類飾品鑑
付与果改芸絵画彫
刻執魔奥義製曲壊
元戻経値錬金妄属
森一携冶哀移速使
索更隠刀万唸判思

通才種分野程仲縦
列並況応好直接型
重個散聞集番守下
岩巨腐り醜悪老奇妙
持年秋赤冠貴価高
照枯珍小青香印象
紙描殊欲議要槌須
久富承認遮結晶偽
隕師達涯色加央見
透緑柱般純粋炭素
最硬輝銀鉄管鋭徴
木枚慣振箱浄瑠璃
伴弦猫三己皮糸六
字差縮肩当四馬代
表待病染私配患者
肌触潜伏期約~完

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
Re: StarOcean SNES Kanji recognition
« Reply #3 on: August 21, 2016, 05:03:08 am »

手入覚双破斬空衝
裂霊雷鳴剣紅蓮閃
光蒼龍醍朱雀翔撃
七星流戟襲爪天吼
竜黒緋招訃虎来玄
.........

 :o :o :o :o

Oh, my god! How did you do it so FAST???


Thank you very much!!!!

BlackDog61

  • Hero Member
  • *****
  • Posts: 784
    • View Profile
    • Super Robot Wars A Portable translation thread
Re: StarOcean SNES Kanji recognition
« Reply #4 on: August 21, 2016, 05:18:55 pm »
How did you do it so FAST???
8) I'd like to know that too - in case there's a nice method for this, which I could use in the future? Please?

yugisokubodai

  • Full Member
  • ***
  • Posts: 144
    • View Profile
    • Assembly
Re: StarOcean SNES Kanji recognition
« Reply #5 on: August 21, 2016, 07:03:41 pm »
I just looked at the screen and type the Kanji with Windows' native Japanese keyboard. No secret here. I was jus so busy so I couldn't type all the Kanji tables. I'll finish when I have more free time in this week.

BlackDog61

  • Hero Member
  • *****
  • Posts: 784
    • View Profile
    • Super Robot Wars A Portable translation thread
Re: StarOcean SNES Kanji recognition
« Reply #6 on: August 22, 2016, 07:26:26 pm »
I just looked at the screen and type the Kanji with Windows' native Japanese keyboard. No secret here. I was jus so busy so I couldn't type all the Kanji tables. I'll finish when I have more free time in this week.
Oh OK - sheer human skill then. Thank you for letting me know!

DougRPG

  • Full Member
  • ***
  • Posts: 146
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #7 on: August 22, 2016, 10:50:20 pm »
Quote
The way Dejap handled the compressed script was a bit difficult and I found easier to merge the Huffman compression with the game's LZ decompressor and after this first step, use the dictionary method to get the final word.

Hi, I hacked Dejap's compression and it was a pain in the ass. I have the script dumped and a tool to assist the dialog translation, if you want. I'll release the inserter after finishing my portuguese translation (I'm about 80%).
I'm also improving Dejap's translation, like adding subtitles in the intro and fixing some menu stuff.

If you can retranslate this game from the japanese this would be a greate thing. This way I could improve my translation.

For more details about my translation see this video:

https://www.youtube.com/watch?v=IxUM_yzR2GA

RedScorpion

  • Full Member
  • ***
  • Posts: 102
    • View Profile
    • Snes-Projects
Re: StarOcean SNES Kanji recognition
« Reply #8 on: August 23, 2016, 02:06:41 am »
Hi Guys,

maybe for the next time:

http://capture2text.sourceforge.net/

Thanks

red

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
Re: StarOcean SNES Kanji recognition
« Reply #9 on: August 23, 2016, 03:41:04 am »
Hi, I hacked Dejap's compression and it was a pain in the ass. I have the script dumped and a tool to assist the dialog translation, if you want. I'll release the inserter after finishing my portuguese translation (I'm about 80%).
I'm also improving Dejap's translation, like adding subtitles in the intro and fixing some menu stuff.

If you can retranslate this game from the japanese this would be a greate thing. This way I could improve my translation.

For more details about my translation see this video:

https://www.youtube.com/watch?v=IxUM_yzR2GA

Dejap's compression scheme is not difficult at all, it is the same scheme they used in Tales of Phantasia; I hacked it in 1 week to dump the english script. 
But anyway, I started the project from scratch form the japanese version, it is easier for me. I already have my inserter and all english script has been succesfully inserted with my new compressor (in some way, similar to Dejap's, adapted from my Romancing Saga 3 version). I plan to translate the intro subs, change the menu and recompress S-DD1 graphics, although for the moment I'm using the 96 meg japanese version as a base.
Thanks for your offering, if I could serve of any help to you, please don't hesitate to ask.

Hi Guys,

maybe for the next time:

http://capture2text.sourceforge.net/

Thanks

Does this tool work fine? It could be useful, however, I'd rather a high-skilled human, as yugisokubodai could do it manually, when he has the spare time to do it, of course. Less error-prone XD


EDIT: Ummm, I have read again my answer to DougRPG and I realize it can sound a bit arrogant. I meant that I found easy to hack Dejap's compression because I already had done the same with Tales of Phantasia, but that I found easier to start from scratch using the japanese version. Besides, Dejap's did a great work and for the respect I owe to them, I prefer not to dishonour its work  :)
« Last Edit: August 24, 2016, 07:01:08 am by magno »

tvtoon

  • Sr. Member
  • ****
  • Posts: 360
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #10 on: August 25, 2016, 06:09:38 pm »
Hi Guys,

maybe for the next time:

http://capture2text.sourceforge.net/

Thanks

red
Thanks for the heads-up! I didn't know that tesseract improved so much trough the years, with this leptonica engine. :D

I have been testing this package and it works good enough for simple tasks, still got some problem with handwriting and weird fonts, but nothing out of ordinary. It is perfect for these tasks. :)

Magil

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #11 on: August 26, 2016, 09:55:39 am »
Well maybe you can try a handwriting inputing method, for example mazec for android (if there's a better one, please let me know).
I wrote these on my phone. Not a pleasant thing to to though, because the touch screen is too small for my like. :banghead:

全駄絶近町盗賊早
追情二僧俺警員助
男勤北門丈夫今暑
娘平和治血相緒子
供眠母家屋駐屯所
連絡遅休頑張菜主
安勉怠継新鮮諦
友忠告誰話暇困昨
渡棚妹辛考僕探関
係艦服暗腑古句濡
村支聞落憩捜帰若
君婆稼妻送届半山
頂厄介卵態鳩始査
協怖急解住惑   保
護条展途決聖域宇
宙夜授違同兵蔓延

奴療訪突拍既医施
設運会夢語済永遠
残悔以磨十遺跡影
採顔嫌痛第茶勝鍵
  症故郷航障異部
転交官宿求報舵海
内侵橋左側驚段反
案原菌癒嬢非逆限
然初液免疫可簡疑
問益繰返身他蔵筋
基面酸銅由例納幾
退屈篤願準添任死
骸寸狂幼頃崖仇忘
圧倒彩楯勘瞳殿翼
掛縁勇敢換賢迷馴

土着軸封葉響族普
....

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
Re: StarOcean SNES Kanji recognition
« Reply #12 on: August 26, 2016, 05:22:13 pm »
Thank you all for your help!
I merged the information about you three (Magil, yugisokubodai and BahaBulle) and got an ALMOST complete kanji table for the game. You can download it here.

The hexadecimal values are AFTER normalization: the japanes in-game's text engine reads a byte and if its MSBit is '1', then the kanji is represented in two bytes (the one with MSBit '1' and the next byte). The normalization is as follow:

Code: [Select]
Byte 0 -> XXXXXXXX
Byte 1 -> YYYYYYYYY

Before normalization:
 1XXX XXXX YYYY YYYY

Shift left byte 0:
 XXXX XXX0

Shift right the whole word (16 bits):
 0YYY YYYY YXXX XXXX

The 16 bit word you get at the end is the word used in my table.


But there are 4 kanjis which I'm not sure about:


Can you guys help me? Maybe it could be useful to you the dumped japanese script so you can check if those kanjis make sense in the sentences their appear?

A million thanks!

Magil

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #13 on: August 26, 2016, 07:47:22 pm »
悟凄砂勲
Not a problem.

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
Re: StarOcean SNES Kanji recognition
« Reply #14 on: August 27, 2016, 05:43:32 am »
悟凄砂勲
Not a problem.

I made all the changes to the table I uploaded yesterday, you can now download the corrected one, the final version. I'll post the japanese script as soon as I can.

Thank you all!

August 28, 2016, 01:53:12 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
Here's the complete japanese script:

http://magno.romhackhispano.org/archivos/SO_jap.txt

Feel free to share wherever you want.
Thank you all!
« Last Edit: August 28, 2016, 01:53:44 pm by magno »

ckrit

  • Jr. Member
  • **
  • Posts: 20
    • View Profile
Re: StarOcean SNES Kanji recognition
« Reply #15 on: August 29, 2016, 08:28:21 pm »
Seems like there are five tables left to be transcribed, do you still need a hand with these?

Hi Guys,

maybe for the next time:

http://capture2text.sourceforge.net/

Thanks

red


I've tried using OCR software like this before, but the accuracy is so ridiculously low, it's best to do this manually still.

magno

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 157
    • View Profile
    • Traducciones Magno
Re: StarOcean SNES Kanji recognition
« Reply #16 on: August 30, 2016, 12:56:00 am »
Seems like there are five tables left to be transcribed, do you still need a hand with these?
 
I've tried using OCR software like this before, but the accuracy is so ridiculously low, it's best to do this manually still.

No, thanks! I already completed the kanji tables and dumped the script. You can get the link to both the table and the script in my previous messages.

 ;)