Render health ECG (electrocardiogram) animation

HealthECG

Render health ECG (electrocardiogram) animation

screenshot

About

This program shows how the health ECG animation was implemented in the original Resident Evil 2 code. This animation always renders when the player opens up the inventory screen in the top part of the screen.

The animation is rendered by drawing a contiguous subset of the ECG on each frame. Each subset of the ECG forms a curve, but the curve is composed of multiple vertical lines instead of one single curved line. The position (yOffset from the top left corner) and height of the vertical lines is hardcoded in an array, which depends on the player's status, e.g. fine, caution, danger, etc. The color and gradient is also defined for each player status in RGB form, where the minimum value is 0 and the maximum value is 255. For example, when the player's status is fine, the color will be green. The gradient is used to blend in the ECG line with a black background.

When the player opens up the inventory, the ECG starts drawing the first vertical line at position x = 0. The code will try to draw multiple vertical lines to the left, where each successive line to the left is darker than the previous line. The color of the left vertical lines is defined by subtracting the gradient from the adjacent line on the right. For example, if the current line color is (20, 255, 20) and the gradient is (1, 8, 1), the first line on the left will have color (19, 247, 19), the second line will have color (18, 239, 18), the third line will have color (17, 231, 17) and so on. The code can draw up to 32 vertical lines at most to the left of the initial vertical line. If any vertical line goes to the left side of the ECG at x = 0, the line won't be rendered.

For each frame, the current vertical line position will be incremented by 1, starting from x = 0 and going all the way up to x = 127. This increment makes the animation smooth, since you gradually see the ECG line move to the right per frame.

Similar Resources

Programatic document generation as a HTTP service. Render PDFs using LaTeX templates and JSON.

Programatic document generation as a HTTP service. Render PDFs using LaTeX templates and JSON.

LaTTe Generate PDFs using LaTeX templates and JSON. Try out the demo! Find LaTTe on Docker Hub Table of Contents About Obtaining LaTTe Running & Using

Dec 29, 2022

⚙️ Concept of Golang HTML render engine with frontend components and dynamic behavior

⚙️ Concept of Golang HTML render engine with frontend components and dynamic behavior

An HTML render engine concept that brings frontend-like components experience to the server side with native html/template on steroids. Supports any s

Nov 25, 2022

Render helm values-files from others

helm-plugin-render-values The Helm downloader plugin with rendering templated values files Install Use helm CLI to install this plugin: $ helm plugin

Aug 1, 2022

⚙️ Concept of Golang HTML render engine with frontend components and dynamic behavior

SSC Engine An HTML render engine concept that brings frontend-like components experience to the server side with native html/template on steroids. Sup

Nov 25, 2022

Golang writen 3D render library and some game-relative concepts

Golang writen 3D render library and some game-relative concepts.

Jun 6, 2022

Golang project for looking up geo from an IP. Meant to be deployed on Render.

geoip-render-go Golang project for looking up geo from an IP. Meant to be deployed on Render. Dependencies In order to use this project, you'll need a

Dec 6, 2021

A Simple Anonym FileSharing Service which is able to be render in the Browser and in an Terminal-Client

FileSharingService A Simple Anonym FileSharing Service which is able to be render in the Browser and in an Terminal-Client How to use Take a look in t

Dec 25, 2022

Ooldim is a blender render program.

ooldim Ooldim is a blender render program. It provides a little more comforts in rendering and server configurations. Features You can pick any machin

Dec 25, 2022

Terminal based wordle clone. Uses the amazing charm.sh libraries to render and expose the game over SSH

Terminal based wordle clone. Uses the amazing charm.sh libraries to render and expose the game over SSH

Nov 17, 2022

Render minecraft: bedrock worlds using dragonfly

Render minecraft: bedrock worlds using dragonfly

worldrenderer render minecraft: bedrock worlds using dragonfly

Dec 25, 2022

The Cloud Aviator: TUI client for cloud services (AWS, Vultr, Heroku, Render.com, ...)

The Cloud Aviator: TUI client for cloud services (AWS, Vultr, Heroku, Render.com, ...)

=== T H E C L O U D A V I A T O R === ⠀⠀⠀⠀⠀⠀⠀⠀⢶⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⢿⣷⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀

Dec 17, 2022

Library for enabling asynchronous health checks in your service

go-health A library that enables async dependency health checking for services running on an orchestrated container platform such as kubernetes or mes

Jan 4, 2023

⛑ Gatus - Automated service health dashboard

⛑ Gatus - Automated service health dashboard

A service health dashboard in Go that is meant to be used as a docker image with a custom configuration file. I personally deploy it in my Kubernetes

Dec 31, 2022

An easy to use, extensible health check library for Go applications.

Try browsing the code on Sourcegraph! Go Health Check An easy to use, extensible health check library for Go applications. Table of Contents Example M

Dec 30, 2022

An simple, easily extensible and concurrent health-check library for Go services

An simple, easily extensible and concurrent health-check library for Go services

Healthcheck A simple and extensible RESTful Healthcheck API implementation for Go services. Health provides an http.Handlefunc for use as a healthchec

Dec 30, 2022

Distributed, lock-free, self-hosted health checks and status pages

Distributed, lock-free, self-hosted health checks and status pages

Checkup is distributed, lock-free, self-hosted health checks and status pages, written in Go. It features an elegant, minimalistic CLI and an idiomati

Dec 30, 2022

A fast and easy to use URL health checker ⛑️ Keep your links healthy during tough times

A fast and easy to use URL health checker ⛑️ Keep your links healthy during tough times

AreYouOK? A minimal, fast & easy to use URL health checker Who is AreYouOk made for ? OSS Package Maintainers 📦️

Oct 7, 2022

Tiny service health dashboard written in Go

Tiny service health dashboard written in Go

GreenWall Status: Done (waiting for feedback) Description GreenWall is a tiny service health dashboard written in Go (with frontend prepared in Bootst

Nov 29, 2022

go-sundheit:A library built to provide support for defining service health for golang services

go-sundheit:A library built to provide support for defining service health for golang services

A library built to provide support for defining service health for golang services. It allows you to register async health checks for your dependencies and the service itself, and provides a health endpoint that exposes their status.

Dec 27, 2022
An easy to use, extensible health check library for Go applications.

Try browsing the code on Sourcegraph! Go Health Check An easy to use, extensible health check library for Go applications. Table of Contents Example M

Dec 30, 2022
An simple, easily extensible and concurrent health-check library for Go services
An simple, easily extensible and concurrent health-check library for Go services

Healthcheck A simple and extensible RESTful Healthcheck API implementation for Go services. Health provides an http.Handlefunc for use as a healthchec

Dec 30, 2022
Track health of various dependencies - golang

Background This package helps setup health check based on status of external dependencies. The idea is to add all external dependencies like database,

Dec 17, 2021
A Simple HTTP health checker for golang

patsch Permanently Assert Target Succeeds Check Health use cases used by kubernetes cluster admins to quickly identify faulty ingresses used by kubern

Feb 22, 2022
Dec 27, 2022
K8s-ingress-health-bot - A K8s Ingress Health Bot is a lightweight application to check the health of the ingress endpoints for a given kubernetes namespace.

k8s-ingress-health-bot A K8s Ingress Health Bot is a lightweight application to check the health of qualified ingress endpoints for a given kubernetes

Jan 2, 2022
Health-go - Web based app for health tracking and monitoring (Go port)

Health Web based app for health tracking and monitoring. Work in progress. Installation Clone the repository: git clone [email protected]:jonathantorr

Dec 31, 2021
A simple, efficient spring animation library for smooth, natural motion🎼
A simple, efficient spring animation library for smooth, natural motion🎼

Harmonica A simple, efficient spring animation library for smooth, natural motion. It even works well on the command line.

Jan 1, 2023
A go library to render progress bars in terminal applications
A go library to render progress bars in terminal applications

uiprogress A Go library to render progress bars in terminal applications. It provides a set of flexible features with a customizable API. Progress bar

Dec 29, 2022
Go library to parse and render Remarkable lines files
Go library to parse and render Remarkable lines files

go-remarkable2pdf Go library to parse and render Remarkable lines files as PDF.

Nov 7, 2022