Prerequisites
- A working Android quickstart
- A downloaded
.nosmaipackage and its required resources
Add the package resources
Use the exact case-sensitive production layout:
app/src/main/assets/Nosmai_Filters/heart_face/ heart_face.nosmai heart_face_manifest.json heart_face_preview.png
Nosmai_Filters is case-sensitive on Android devices.
Discover and apply it
List<NosmaiFilterInfo> filters = NosmaiEffects.getFilters();
NosmaiFilterInfo filter = filters.get(0);
NosmaiEffects.applyEffect(
filter.getPath(),
new NosmaiEffects.EffectCallback() {
@Override public void onSuccess() {}
@Override public void onError(String message) {
Log.e("Nosmai", message);
}
}
);
Do not use debug discovery as the production catalog.
Verify it worked
After license verification, disable network access and apply the filter again. The bundled package should remain available.
Common errors
| Symptom | Fix |
|---|---|
| Catalog is empty on device | Correct Nosmai_Filters capitalization and filenames |
| Works in Debug but not Release | Inspect merged assets and R8 configuration in the release APK or App Bundle |
| Apply callback fails | Use the discovered path and a package built for the current SDK |