Skip to content

Commit de54752

Browse files
committed
gltf animations + refactoring
1 parent d271040 commit de54752

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+4142
-7249
lines changed

CHANGELOG.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ ChangeLog
33

44
(f) fixed, (i) improved, (n) new feature
55

6+
- 4.1.0 (22/10/2024)
7+
- (n) Gltf Animations
8+
- (n) Android Preferences for Settings
9+
- (n) Loader: Integrated Khronos repository
10+
- (i) Android view using Fragments
11+
- (i) Android SDK and dependencies updated
612
- 4.0.0 (04/09/2022)
713
- (i) rebranding to org.the3deer
814
- (i) master branch renamed to main
@@ -24,7 +30,6 @@ ChangeLog
2430
- (n) New gui axis + gui info
2531
- (f) fixed FPS counter
2632
- (i) some user options are being saved (camera settings)
27-
2833
- 3.2.0 (02/02/2022)
2934
- (i) repository explorer improved - multiple index files
3035
- (f) smoothing fixed
@@ -57,7 +62,7 @@ ChangeLog
5762
- (f) Fixed overall bugs
5863
- 2.7.0 (13/11/2019)
5964
- (n) new blending force mode to 50%
60-
- (f) fixed light rendering issues on shaders #125 (diffuse + specular)
65+
- (f) fixed light rendering issues on renderers #125 (diffuse + specular)
6166
- (f) fixed bugs when DAE had multiple geometries #125
6267
- (f) fixed textures not being linked issue
6368
- (f) fixed performance issues: now rendering below 5% cpu & no ram allocation
@@ -71,7 +76,7 @@ ChangeLog
7176
- 2.5.0 (19/05/2019)
7277
- (n) new blending toggle
7378
- (n) new color toggle
74-
- (i) engine refactoring: externalized shaders
79+
- (i) engine refactoring: externalized renderers
7580
- (i) engine improved: fixed bugs and removed classes
7681
- 2.4.0 (16/05/2019)
7782
- (n) stereoscopic rendering: anaglyph + cardboard

README.md

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,14 @@ The purpose of this application is to learn and share how to draw using OpenGL l
1313
* GLTF format (gltf): https://www.khronos.org/gltf/
1414

1515

16-
News (04/10/2022)
16+
News (22/10/2024)
1717
=================
1818

19-
* Preparing version 4.0.0 for Google Play release...
20-
* New orthographic, isometric and free camera views
21-
* GLTF basic support :)
22-
* Rebranding to org.the3deer
19+
* Gltf Animations :D
20+
* Android view using Fragments
21+
* Android Preferences for Settings
22+
* Android SDK and dependencies updated
23+
* Loader: Integrated Khronos repository
2324

2425
Demo
2526
====
@@ -84,16 +85,16 @@ Features
8485
- [x] Multiple Rendering Modes
8586
- [x] triangles
8687
- [x] wireframe
87-
- [x] point cloud
88+
- [ ] point cloud
8889
- [x] skeleton
8990
- [x] camera support
9091
- [x] perspective
91-
- [x] orthographic
92-
- [x] isometric views
93-
- [x] free
94-
- [x] skeletal animations (collada dae)
92+
- [ ] orthographic
93+
- [ ] isometric views
94+
- [ ] free
95+
- [x] skeletal animations (collada dae, gltf)
9596
- [x] ray collision detection
96-
- [x] stereoscopic 3D: anaglyph + cardboard
97+
- [ ] stereoscopic 3D: anaglyph + cardboard
9798
- [x] other:
9899
- [x] Polygon with holes
99100
- [x] Smoothing
@@ -102,8 +103,7 @@ Features
102103
- [x] Object picking
103104
- [x] file explorer
104105
- [x] repository explorer
105-
- [x] texture loader
106-
- [x] lightweight: only 1.3 Megabyte (embedded models excluded)
106+
- [x] lightweight: only 8 Megabyte (3d models excluded)
107107

108108

109109
Try it
@@ -116,7 +116,7 @@ You can install the application in either of these ways:
116116
* Source code: clone the repository, compile with gradle and install with adb
117117

118118
```
119-
   export ANDROID_HOME=/home/$USER/Android/Sdk
119+
export ANDROID_HOME=/home/$USER/Android/Sdk
120120
./gradlew assembleDebug
121121
adb install -r app/build/outputs/apk/app-debug.apk
122122
adb shell am start -n org.andresoviedo.dddmodel2/org.the3deer.app.model3D.MainActivity
@@ -164,8 +164,9 @@ You may need one of this glasses to view models in 3D virtual reality.
164164
Dependencies
165165
============
166166

167-
* git submodule add https://github.com/the3deer/android-3D-engine.git engine (3d engine)
168-
* implementation 'com.fasterxml.jackson.core:jackson-databind:2.13.4' (gltf json parser)
167+
In order to compile the application you must include this git submodule
168+
169+
git submodule add https://github.com/the3deer/android-3D-engine.git engine
169170

170171

171172
Documentation
@@ -180,7 +181,7 @@ Acknowledgement
180181
* For teaching how animation engine works: https://github.com/TheThinMatrix/OpenGL-Animation
181182
* To the lot of user's feedback: https://github.com/the3deer/android-3D-model-viewer/issues
182183
* For the GLTF parser https://github.com/javagl/JglTF
183-
* To the many infinite educational resources found in Internet for free :)
184+
* To the many infinite educational resources found on Internet for free, thank you ! :)
184185

185186

186187
Licenses
@@ -199,9 +200,10 @@ copies or substantial portions of the Software.
199200
Assets
200201

201202
* cowboy : Unlicense License - https://github.com/TheThinMatrix/OpenGL-Animation
203+
* fox : CC0: Low poly fox by PixelMannen, CC-BY 4.0: Rigging and animation by @tomkranis on Sketchfab
202204
* stormtrooper : MIT License - https://github.com/hujiulong/vue-3d-model
203205
* toyplane : Editorial Uses Only - https://blog.turbosquid.com/turbosquid-3d-model-license/#Editorial-Usage
204206
* skybox sea : https://learnopengl.com/Advanced-OpenGL/Cubemaps
205207
* skybox sand : Copyright 2012 Mobialia - https://github.com/mobialia/jmini3d
206-
* repository (parts) : Community contribution (Professsor S)
208+
* models (parts) : Community contribution (Professor S)
207209

app/build.gradle

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ plugins {
33
}
44

55
android {
6-
compileSdk 33
6+
compileSdk 34
77

88
defaultConfig {
99
applicationId "org.andresoviedo.dddmodel2"
10-
minSdk 16
11-
targetSdk 33
10+
minSdk 21
11+
targetSdk 34
1212

1313
multiDexEnabled true
1414
}
@@ -36,14 +36,17 @@ android {
3636
buildFeatures {
3737
viewBinding true
3838
}
39+
namespace 'org.andresoviedo.dddmodel2'
3940
}
4041

4142
dependencies {
42-
implementation 'androidx.core:core:1.8.0'
43-
implementation 'androidx.navigation:navigation-fragment:2.5.1'
43+
implementation 'javax.inject:javax.inject:1'
44+
implementation 'androidx.core:core:1.13.1'
45+
implementation 'androidx.fragment:fragment:1.8.3'
46+
implementation 'androidx.lifecycle:lifecycle-viewmodel-android:2.8.6'
47+
implementation 'androidx.preference:preference:1.2.1'
4448
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
4549
implementation 'androidx.coordinatorlayout:coordinatorlayout:1.2.0'
46-
implementation 'com.google.android.material:material:1.6.1'
47-
implementation 'com.google.code.gson:gson:2.9.1'
50+
implementation 'com.google.android.material:material:1.12.0'
4851
implementation project(':engine')
4952
}

app/debug/output-metadata.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"version": 3,
3+
"artifactType": {
4+
"type": "APK",
5+
"kind": "Directory"
6+
},
7+
"applicationId": "org.the3deer.dddmodel2",
8+
"variantName": "debug",
9+
"elements": [
10+
{
11+
"type": "SINGLE",
12+
"filters": [],
13+
"attributes": [],
14+
"versionCode": 30,
15+
"versionName": "3.1.1",
16+
"outputFile": "app-debug.apk"
17+
}
18+
],
19+
"elementType": "File"
20+
}

app/release/output-metadata.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"version": 3,
3+
"artifactType": {
4+
"type": "APK",
5+
"kind": "Directory"
6+
},
7+
"applicationId": "org.the3deer.dddmodel2",
8+
"variantName": "release",
9+
"elements": [
10+
{
11+
"type": "SINGLE",
12+
"filters": [],
13+
"attributes": [],
14+
"versionCode": 30,
15+
"versionName": "3.1.1",
16+
"outputFile": "app-release.apk"
17+
}
18+
],
19+
"elementType": "File"
20+
}

app/src/main/AndroidManifest.xml

Lines changed: 3 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:tools="http://schemas.android.com/tools"
4-
package="org.andresoviedo.dddmodel2"
5-
android:versionCode="33"
6-
android:versionName="4.0.0">
4+
android:versionCode="34"
5+
android:versionName="5.0.0">
76

87
<uses-sdk
98
tools:overrideLibrary="android.support.compat, android.arch.lifecycle" />
109

1110
<uses-feature
12-
android:glEsVersion="0x00020000"
11+
android:glEsVersion="0x00030002"
1312
android:required="true" />
1413

1514
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
@@ -28,49 +27,14 @@
2827
android:label="@string/app_name">
2928
<intent-filter>
3029
<action android:name="android.intent.action.MAIN" />
31-
3230
<category android:name="android.intent.category.LAUNCHER" />
3331
</intent-filter>
3432
</activity>
35-
<activity
36-
android:name="org.the3deer.app.model3D.view.MenuActivity"
37-
android:label="@string/title_activity_menu"
38-
android:parentActivityName="org.the3deer.app.model3D.MainActivity" >
39-
</activity>
4033
<activity
4134
android:name="org.the3deer.util.view.TextActivity"
4235
android:label="@string/title_activity_text"
4336
android:parentActivityName="org.the3deer.app.model3D.MainActivity" >
4437
</activity>
45-
<activity
46-
android:name="org.the3deer.app.model3D.view.ModelActivity"
47-
android:label="@string/title_activity_model"
48-
android:parentActivityName="org.the3deer.app.model3D.MainActivity" >
49-
50-
<!-- android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" -->
51-
</activity>
52-
53-
54-
<!-- Demos -->
55-
<activity
56-
android:name="org.the3deer.app.model3D.demo.GlyphsDemoActivity"
57-
android:label="@string/title_activity_model"
58-
android:parentActivityName="org.the3deer.app.model3D.MainActivity" >
59-
</activity>
60-
<activity
61-
android:name="org.the3deer.app.model3D.demo.EarCutDemoActivity"
62-
android:label="@string/title_activity_model"
63-
android:parentActivityName="org.the3deer.app.model3D.MainActivity" >
64-
</activity>
65-
66-
67-
<!-- polybool -->
68-
<activity
69-
android:name="org.the3deer.polybool.demo.WebActivity"
70-
android:label="@string/app_name"
71-
android:theme="@style/Theme.AppCompat.NoActionBar">
72-
73-
</activity>
7438

7539
</application>
7640

app/src/main/assets/models/Fox.glb

159 KB
Binary file not shown.

0 commit comments

Comments
 (0)