Skip to content

Latest commit

 

History

History
194 lines (132 loc) · 9.48 KB

Hello_Graphics.md

File metadata and controls

194 lines (132 loc) · 9.48 KB

AppID

Hello Graphics

Check samples with Hello_something.py for sample code on how to do stuff

  • The code did a functional approach (no classes) ... dont add classes or I might refactor lmao

API Documentation Generator

Public API

Internal API

References

Functional Progamming in Python: https://machinelearningmastery.com/functional-programming-in-python/

Details on the windows bitmap format: https://docs.microsoft.com/en-us/windows/win32/gdi/bitmap-storage

Ground up 2D graphics:

3D entities to onscreen 2D: https://www.evl.uic.edu/luc/488/slides/class7.pdf

  • predefined 3D entities

Math in Computer Graphics: https://faculty.cc.gatech.edu/~turk/math_gr.html

Colors

If there is demand for it I could in theory write a book based on this project lmao.

Books:

  • Roger T. Stevens. Graphics Programming in C (1993). 1st Indian Edition, M & T Publishing Inc
  • Bernard Kolman. Elementary Linear Algebra (1991). 5th Edition, Macmillan Publishing Company
  • Gerald L. Bradley, Karl J. Smith. Multivariable Calculus (1999). 2nd Edition, Prentice Hall

Fully commented sample code list below

Named colors

  • Named Colors
  • X11 Colors
  • XKCD Colors

Full Gradient Background

  • Linear Gradient
  • Circular Gradient
  • Radial Gradient
  • Non Linear Radial Gradient
  • Radial Multichannel Gradient
  • Non Linear Radial Multichannel Gradient

Line

  • Line
  • Vector
  • Thick Rounded Line
  • Thick Rounded Gradient Line

Rectangle (images are links to sample code)

Rectangle

Filled Rectangle

Filled Vertical Gradient Rectangle

Filled Smoothstep Vertical Gradient Rectangle

Filled Smootherstep Vertical Gradient Rectangle

Filled Smootheststep Vertical Gradient Rectangle

Filled Horizontal Gradient Rectangle

Filled Smoothstep Horizontal Gradient Rectangle

Filled Smootherstep Horizontal Gradient Rectangle

Filled Smootheststep Horizontal Gradient Rectangle

Filled Vertical Dichromatic Gradient Rectangle

Filled Vertical Dichromatic Smoothstep Gradient Rectangle

Filled Vertical Dichromatic Smootherstep Gradient Rectangle

Filled Vertical Dichromatic Smootheststep Gradient Rectangle

Filled Horizontal Dichromatic Gradient Rectangle

Filled Horizontal Dichromatic Smoothstep Gradient Rectangle

Filled Horizontal Dichromatic Smootherstep Gradient Rectangle

Filled Horizontal Dichromatic Smootheststep Gradient Rectangle

Regular Polygons Regular Polygon Thick Regular Polygon Gradient Thick Regular Polygon

Circle (images are links to sample code)

Circle

Filled Circle

Thick Circle

Thick Gradient Circle

Ellipse

  • Ellipse
  • Filled Ellipse
  • Ellipical Gardient
  • Thick Rotated Gradient Ellipse

Curves and Spirals

  • Bezier Curve
  • Bspline
  • Involute of a Circle
  • Cornu Spiral
  • Square Spiral
  • Thick Expponential Gradient Spiral

3D and 3D shading effects (Images are links to sample code)

Sphere

Sphere smoothstep

Sphere smootherstep

Sphere smootheststep

Sphere-dichroma

Sphere-dichroma smoothstep

Sphere-dichroma smootherstep

Sphere-dichroma smootheststep

Icosahedron

  • 3D
  • Surface Plot
  • Orb
  • Benzene
  • Globe
  • Discoball
  • Coin
  • Cone
  • Tetrahedron
  • Cube
  • Octahedron
  • Decahedron
  • Icosahedron Outline

Parametric Curve Equations (images are links to sample code)

Flower

  • Cardioid
  • Epicycloid
  • Octopetala
  • Gear Curve
  • Heart Curve
  • Egg Curve
  • Lissajous Curve
  • Hypotrochoid
  • Superellipse
  • Squircles

Spirographs

  • Hello_Spirograph.py
  • Hello_Spirograph_1.py
  • Hello_Spirograph_2.py
  • Hello_Spirograph_Record.py

Graphs

  • XY Scatterplot