openframeworks / openframeworks/openFrameworks

ofGLUtils function naming inconsistencies: "Gl" versus "GL"

Open
#2,282 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

code-review section-2D
Dominant language
C++
Stars
10.4k
Forks
2.6k
Avg merge
1d 21h
Merged PRs (30d)
9

Description

Maybe this is something we missed in Maine, but there are two OpenGL camel case abbreviations in the functions in ofGLUtils.h. AFAICT all the newer stuff uses "GL", while these use "Gl":

int ofGetGlInternalFormat(const ofPixels& pix);
int ofGetGlInternalFormat(const ofShortPixels& pix);
int ofGetGlInternalFormat(const ofFloatPixels& pix);

string ofGetGlInternalFormatName(int glInternalFormat);
int ofGetGLFormatFromInternal(int glInternalFormat);    
int ofGetGlType(const ofPixels & pixels);
int ofGetGlType(const ofShortPixels & pixels);
int ofGetGlType(const ofFloatPixels & pixels);

If we've made the other api-breaking changes already, these should be updated before the 0.8.0 release IMO.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in ofGLUtils.h with the listed ofGetGlInternalFormat, ofGetGlInternalFormatName, ofGetGLFormatFromInternal, and ofGetGlType declarations. Search the repository for their call sites and update the inconsistent "Gl" capitalization to match the newer "GL" naming. Done means the declarations and references use one consistent API spelling before the 0.8.0 release.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
computer-graphics
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.