|
OCR Project
|
Complete application state passed to every GUI function. More...

Public Attributes | |
| SDL_Window * | window |
| SDL_Renderer * | renderer |
| TTF_Font * | font |
| TTF_Font * | font_sm |
| char | image_buf [512] |
| char | model_buf [512] |
| char | words_buf [2048] |
| int | focused |
| Image * | orig_img |
| SDL_Texture * | orig_tex |
| CNN * | net |
| BoundingBox * | cells |
| size_t | n_cells |
| int | grid_rows |
| int | grid_cols |
| int | cell_pitch |
| char | result_words [MAX_RESULTS][64] |
| WordResult | results [MAX_RESULTS] |
| int | n_results |
| int | disp_x |
| int | disp_y |
| float | disp_scale |
| char | status [256] |
| int | status_ok |
| int | hovered_btn |
| int | running |
| int | busy |
Complete application state passed to every GUI function.
All mutable state lives here so that every helper function receives only a single pointer instead of a growing parameter list.
| int GuiState::busy |
Non-zero while OCR pipeline is running.
| int GuiState::cell_pitch |
Average grid pitch in image pixels.
| BoundingBox* GuiState::cells |
Sorted letter bounding boxes (image coords).
| float GuiState::disp_scale |
Factor: image_pixel × disp_scale = screen_pixel.
| int GuiState::disp_x |
X pixel of the image top-left corner on screen.
| int GuiState::disp_y |
Y pixel of the image top-left corner on screen.
| int GuiState::focused |
Which field has keyboard focus (FOCUS_*).
| TTF_Font* GuiState::font |
Primary font (FONT_SIZE pt).
| TTF_Font* GuiState::font_sm |
Smaller font for labels/status (FONT_SIZE_SM pt).
| int GuiState::grid_cols |
Number of grid columns inferred by OCR.
| int GuiState::grid_rows |
Number of grid rows inferred by OCR.
| int GuiState::hovered_btn |
Button under the mouse: 0=none, 1–3=row index.
| char GuiState::image_buf[512] |
Editable image-path field content.
| char GuiState::model_buf[512] |
Editable model-path field content.
| size_t GuiState::n_cells |
Number of entries in cells.
| int GuiState::n_results |
Number of entries in results[].
| Image* GuiState::orig_img |
Original RGBA image — never modified.
| SDL_Texture* GuiState::orig_tex |
GPU texture built once from orig_img.
| SDL_Renderer* GuiState::renderer |
Hardware-accelerated renderer.
| char GuiState::result_words[MAX_RESULTS][64] |
Words that were searched.
| WordResult GuiState::results[MAX_RESULTS] |
Corresponding solver results.
| int GuiState::running |
Set to 0 to exit the event loop.
| char GuiState::status[256] |
Status-bar message.
| int GuiState::status_ok |
Colour hint: 1=green, 0=red, -1=neutral grey.
| SDL_Window* GuiState::window |
Main application window.
| char GuiState::words_buf[2048] |
Comma-separated words to search for.