Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Programmatic Frame Generator Library #105

Open
JakeWharton opened this issue Feb 6, 2015 · 0 comments
Open

Programmatic Frame Generator Library #105

JakeWharton opened this issue Feb 6, 2015 · 0 comments

Comments

@JakeWharton
Copy link

I would like to automate the process through which screenshots are wrapped by interacting with the core of this app through a library.

The way I see it there's two approaches to accomplish this:

  • Write a small, embeddable library which interacts with the application over intents, binder, et. al. in order to control it from within another application. This would require images be saved somewhere shareable and DFG would write the image back to the filesystem also in a shareable location.
  • Extract the image manipulation core in to a library module. The main application and as well as a new library module would depend on this library. In this new library module a service would be included which runs in its own process (probably with largeHeap=true) for the processing. There would also be a lightweight API to interact with this service for enqueuing images and receiving callbacks when they were done processing.

I think there's value to doing it both ways but the former is probably the more reasonable approach.

There's some things to consider when interacting programmatically:

  • What frame do you use? If not specified, the exact make should be used otherwise a generic frame that can be adjusted to the current device's specifications. Also an enum or string constants would be provided of shortnames for all the provided frames.
  • Where do you write the images to? Instead of using the normal directory, the caller should be able to specify a target folder.
  • What size is the generated image? Similar to Images scale #98, being able to reduce the size would be helpful for programmatic interaction.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant