diff --git a/bin/lang/english.json b/bin/lang/english.json index da791c6..1b269dd 100644 --- a/bin/lang/english.json +++ b/bin/lang/english.json @@ -92,5 +92,6 @@ "OK":"OK", "Cancel":"Cancel", "IDC_STATIC_USE_GPU_NO":"Use GPU No", -"IDC_RADIO_MODEL_UPCONV_RGB":"2-D illust (UpRGB Model)" +"IDC_RADIO_MODEL_UPCONV_RGB":"2-D illust (UpRGB Model)", +"IDC_RADIO_MODEL_UPCONV_PHOTO":"Photo (UpPhoto Model)" } diff --git a/bin/lang/japanese.json b/bin/lang/japanese.json index 9c01897..5df1344 100644 --- a/bin/lang/japanese.json +++ b/bin/lang/japanese.json @@ -92,5 +92,6 @@ "OK":"OK", "Cancel":"キャンセル", "IDC_STATIC_USE_GPU_NO":"使用GPU No", -"IDC_RADIO_MODEL_UPCONV_RGB":"2次元イラスト (UpRGBモデル)" +"IDC_RADIO_MODEL_UPCONV_RGB":"2次元イラスト (UpRGBモデル)", +"IDC_RADIO_MODEL_UPCONV_PHOTO":"写真・アニメ (UpPhotoモデル)" } diff --git a/waifu2x-caffe-gui/MainDialog.cpp b/waifu2x-caffe-gui/MainDialog.cpp index 68322a3..732436d 100644 --- a/waifu2x-caffe-gui/MainDialog.cpp +++ b/waifu2x-caffe-gui/MainDialog.cpp @@ -301,8 +301,8 @@ bool DialogEvent::SyncMember(const bool NotSyncCropSize, const bool silent) switch (cur) { case 0: - model_dir = TEXT("models/anime_style_art_rgb"); - modelType = eModelTypeRGB; + model_dir = TEXT("models/anime_style_art_rgb"); + modelType = eModelTypeRGB; break; case 1: @@ -316,8 +316,13 @@ bool DialogEvent::SyncMember(const bool NotSyncCropSize, const bool silent) break; case 3: - model_dir = TEXT("models/anime_style_art"); - modelType = eModelTypeY; + model_dir = TEXT("models/upconv_7_photo"); + modelType = eModelTypeUpConvPhoto; + break; + + case 4: + model_dir = TEXT("models/anime_style_art"); + modelType = eModelTypeY; break; default: @@ -1469,6 +1474,7 @@ void DialogEvent::SetWindowTextLang() SendMessage(hwndCombo, CB_ADDSTRING, 0, (LPARAM)langStringList.GetString(L"IDC_RADIO_MODEL_RGB").c_str()); SendMessage(hwndCombo, CB_ADDSTRING, 0, (LPARAM)langStringList.GetString(L"IDC_RADIO_MODEL_PHOTO").c_str()); SendMessage(hwndCombo, CB_ADDSTRING, 0, (LPARAM)langStringList.GetString(L"IDC_RADIO_MODEL_UPCONV_RGB").c_str()); + SendMessage(hwndCombo, CB_ADDSTRING, 0, (LPARAM)langStringList.GetString(L"IDC_RADIO_MODEL_UPCONV_PHOTO").c_str()); SendMessage(hwndCombo, CB_ADDSTRING, 0, (LPARAM)langStringList.GetString(L"IDC_RADIO_MODEL_Y").c_str()); SendMessage(GetDlgItem(dh, IDC_COMBO_MODEL), CB_SETCURSEL, cur, 0); @@ -1871,8 +1877,10 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData) index = 1; else if (modelType == eModelTypeUpConvRGB) index = 2; - else + else if (modelType == eModelTypeUpConvPhoto) index = 3; + else + index = 4; SendMessage(GetDlgItem(dh, IDC_COMBO_MODEL), CB_SETCURSEL, index, 0); @@ -2026,6 +2034,7 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData) cmdModelTypeConstraintV.push_back(L"anime_style_art_rgb"); cmdModelTypeConstraintV.push_back(L"photo"); cmdModelTypeConstraintV.push_back(L"upconv_7_anime_style_art_rgb"); + cmdModelTypeConstraintV.push_back(L"upconv_7_photo"); cmdModelTypeConstraintV.push_back(L"anime_style_art_y"); TCLAP::ValuesConstraint cmdModelTypeConstraint(cmdModelTypeConstraintV); TCLAP::ValueArg cmdModelType(L"y", L"model_type", L"model type", @@ -2251,10 +2260,14 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData) index = 0; else if (cmdModelType.getValue() == L"photo") index = 1; - else if (cmdModelType.getValue() == L"anime_style_art_y") + else if (cmdModelType.getValue() == L"upconv_7_anime_style_art_rgb") index = 2; - else + else if (cmdModelType.getValue() == L"upconv_7_photo") index = 3; + else if (cmdModelType.getValue() == L"anime_style_art_y") + index = 4; + else + index = 4; SendMessage(GetDlgItem(dh, IDC_COMBO_MODEL), CB_SETCURSEL, index, 0); diff --git a/waifu2x-caffe-gui/MainDialog.h b/waifu2x-caffe-gui/MainDialog.h index 98c558b..549e1cb 100644 --- a/waifu2x-caffe-gui/MainDialog.h +++ b/waifu2x-caffe-gui/MainDialog.h @@ -88,6 +88,7 @@ private: eModelTypePhoto, eModelTypeY, eModelTypeUpConvRGB, + eModelTypeUpConvPhoto, eModelTypeEnd, };