Skip to main content

Draw to the screen?

Setup

There's quite a bit going on in the setup, but it thankfully is mostly boilerplate.

The functions you want, in order, are:

  • VIDEO_Init(): This needs to be called before any other VIDEO functions. Documentation says it should be done "in the early stages of your main(), but we've had success in moving it to a different function that is called from main.
  • VIDEO_GetPreferredMode(): This returns you your GXRModeObj struct pointer defining the screen layout and mode. What you get from this depends on the console settings, and if it's PAL or NTSC, things like that. The parameter also takes a GRXModeObj and seems to overwrite it if present? Not sure why you'd want that, just pass NULL.