«
Previous
|
Next
»
Revision 71c1df95
Added by Leszek Koltunski about 3 hours ago
- ID 71c1df95f3617e8aa6d1d5f1900dc5a94764f022
- Parent 7fd5a84a
| src/main/java/org/distorted/library/main/DistortedLibrary.kt | ||
|---|---|---|
| 1020 | 1020 |
* @param user The Code which will be using this library, which must implement the LibraryUser interface. |
| 1021 | 1021 |
* @param queueSize the size of the FBO queue, a workaround for the bug on Mali drivers. Use a small integer - 1,...,4 |
| 1022 | 1022 |
*/ |
| 1023 |
fun onSurfaceCreated(user: LibraryUser, queueSize: Int = 4)
|
|
| 1023 |
fun onSurfaceCreated(user: LibraryUser, queueSize: Int) |
|
| 1024 | 1024 |
{
|
| 1025 | 1025 |
mUser = user |
| 1026 | 1026 |
val version = version |
| ... | ... | |
| 1085 | 1085 |
mUser.distortedException(ex) |
| 1086 | 1086 |
} |
| 1087 | 1087 |
} |
| 1088 |
fun onSurfaceCreated(user: LibraryUser) = onSurfaceCreated(user,4) |
|
| 1088 | 1089 |
|
| 1089 | 1090 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 1090 | 1091 |
/** |
| ... | ... | |
| 1111 | 1112 |
* @param id id of an Activity that is using the library; anything unique so that the Library can |
| 1112 | 1113 |
* tell between Activities in case you're going to be using it from more than one. |
| 1113 | 1114 |
*/ |
| 1114 |
fun onCreate(id: Long = 0)
|
|
| 1115 |
fun onCreate(id: Long) |
|
| 1115 | 1116 |
{
|
| 1116 | 1117 |
InternalStackFrameList.onCreate(id) |
| 1117 | 1118 |
} |
| 1119 |
fun onCreate() = onCreate(0) |
|
| 1118 | 1120 |
|
| 1119 | 1121 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 1120 | 1122 |
/** |
| ... | ... | |
| 1124 | 1126 |
* @param id id of an Activity that is using the library; anything unique so that the Library can |
| 1125 | 1127 |
* tell between Activities in case you're going to be using it from more than one. |
| 1126 | 1128 |
*/ |
| 1127 |
fun onResume(id: Long = 0)
|
|
| 1129 |
fun onResume(id: Long) |
|
| 1128 | 1130 |
{
|
| 1129 | 1131 |
InternalStackFrameList.onResume(id) |
| 1130 | 1132 |
} |
| 1133 |
fun onResume() = onResume(0) |
|
| 1131 | 1134 |
|
| 1132 | 1135 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 1133 | 1136 |
/** |
| ... | ... | |
| 1137 | 1140 |
* @param id id of an Activity that is using the library; anything unique so that the Library can |
| 1138 | 1141 |
* tell between Activities in case you're going to be using it from more than one. |
| 1139 | 1142 |
*/ |
| 1140 |
fun onPause(id: Long = 0)
|
|
| 1143 |
fun onPause(id: Long) |
|
| 1141 | 1144 |
{
|
| 1142 | 1145 |
InternalStackFrameList.onPause(id) |
| 1143 | 1146 |
|
| ... | ... | |
| 1163 | 1166 |
mBlitDepthProgram = null |
| 1164 | 1167 |
mBlitProgram = null |
| 1165 | 1168 |
} |
| 1169 |
fun onPause() = onPause(0) |
|
| 1166 | 1170 |
|
| 1167 | 1171 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 1168 | 1172 |
/** |
| ... | ... | |
| 1172 | 1176 |
* @param id id of an Activity that is using the library; anything unique so that the Library can |
| 1173 | 1177 |
* tell between Activities in case you're going to be using it from more than one. |
| 1174 | 1178 |
*/ |
| 1175 |
fun onDestroy(id: Long = 0)
|
|
| 1179 |
fun onDestroy(id: Long) |
|
| 1176 | 1180 |
{
|
| 1177 | 1181 |
if (isInitialized) |
| 1178 | 1182 |
{
|
| 1179 | 1183 |
InternalStackFrameList.onDestroy(id) |
| 1180 | 1184 |
} |
| 1181 | 1185 |
} |
| 1186 |
fun onDestroy() = onDestroy(0) |
|
| 1182 | 1187 |
|
| 1183 | 1188 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 1184 | 1189 |
/** |
Also available in: Unified diff
fixes to be able to compile multiplatform branch.