skia-python / skia-python/skia-python

Refactor code organization

Open
#130 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Jupyter Notebook
Stars
323
Forks
52
Avg merge
2h 29m
Merged PRs (30d)
1

Description

Is your feature request related to a problem? Please describe.
Re-organize binding codes according to Skia header structure. Also rename stub class name in a consistent manner; e.g., from:

py::class_<SkColorFilter, sk_sp<SkColorFilter>, SkFlattenable> colorfilter(m, "ColorFilter");

to:

py::class_<SkColorFilter, sk_sp<SkColorFilter>, SkFlattenable> ColorFilter(m, "ColorFilter");

This is to improve code maintenance over skia version upgrades.

Describe the solution you'd like
In Skia, header files are organized under different directories by categories, such as include/core/*.h or include/gpu/*.h. Presumably, the python package should be also split according to this structure.

Describe alternatives you've considered
n/a

Additional context
n/a

Contributor guide

No contributing guide indexed for this repository

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 by mapping the existing binding code against Skia's include/core/.h and include/gpu/.h header categories. Review the current stub class naming, including the ColorFilter example, and define the package layout and naming scope before changing it. Done means bindings follow the header structure and stub class names are consistent.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, python
Domain
computer-graphics
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.