make it work!

This commit is contained in:
nek0 2017-11-16 19:48:11 +01:00
parent c833fc847c
commit 467449f374
6 changed files with 499 additions and 477 deletions

View file

@ -1,4 +1,4 @@
# Blender v2.78 (sub 0) OBJ File: 'jaeger.blend'
# Blender v2.79 (sub 0) OBJ File: 'jaeger.blend'
# www.blender.org
o jaeger
v 0.900000 0.300000 -3.000000
@ -263,458 +263,458 @@ v 0.389376 0.465623 1.170086
v 0.517157 0.517373 1.117157
v -1.500000 -0.150000 2.600000
v 0.000000 -0.300000 0.900000
vt 0.2789 0.7032
vt 0.2538 0.7165
vt 0.1795 0.7018
vt 0.2288 0.7255
vt 0.2039 0.7311
vt 0.1790 0.7346
vt 0.1541 0.7304
vt 0.1294 0.7240
vt 0.1046 0.7143
vt 0.0799 0.7002
vt 0.4319 0.7172
vt 0.5348 0.7158
vt 0.4579 0.7310
vt 0.4837 0.7403
vt 0.5096 0.7462
vt 0.5354 0.7497
vt 0.5611 0.7454
vt 0.5868 0.7388
vt 0.6124 0.7287
vt 0.6379 0.7142
vt 0.4364 0.2636
vt 0.4528 0.2566
vt 0.4542 0.2634
vt 0.2573 0.2649
vt 0.2588 0.2584
vt 0.2746 0.2652
vt 0.2626 0.2529
vt 0.4488 0.2509
vt 0.4429 0.2472
vt 0.2675 0.2493
vt 0.2740 0.2481
vt 0.4361 0.2459
vt 0.4293 0.2474
vt 0.2802 0.2495
vt 0.2870 0.2532
vt 0.4235 0.2513
vt 0.4198 0.2571
vt 0.2906 0.2588
vt 0.2918 0.2654
vt 0.4185 0.2639
vt 0.1838 0.4171
vt 0.1858 0.2747
vt 0.2009 0.2639
vt 0.2407 0.2646
vt 0.2254 0.2644
vt 0.2120 0.2641
vt 0.5304 0.4210
vt 0.5127 0.2624
vt 0.5283 0.2735
vt 0.5012 0.2626
vt 0.4873 0.2628
vt 0.4714 0.2631
vt 0.2251 0.8302
vt 0.2126 0.8355
vt 0.2108 0.8205
vt 0.2108 0.8495
vt 0.4830 0.8482
vt 0.5225 0.8373
vt 0.5081 0.8375
vt 0.5620 0.8484
vt 0.5369 0.8376
vt 0.2381 0.8302
vt 0.2506 0.8355
vt 0.2525 0.8495
vt 0.2525 0.8205
vt 0.2662 0.4511
vt 0.3485 0.4852
vt 0.4451 0.4562
vt 0.3598 0.4915
vt 0.3370 0.2660
vt 0.3480 0.2661
vt 0.9910 0.2545
vt 0.9933 0.5041
vt 0.9807 0.5045
vt 0.9670 0.5048
vt 0.9528 0.5049
vt 0.3084 0.2656
vt 0.3237 0.2658
vt 0.3717 0.2645
vt 0.3855 0.2643
vt 0.4013 0.2641
vt 0.9130 0.2547
vt 0.9386 0.5049
vt 0.9249 0.5047
vt 0.9124 0.5044
vt 0.3604 0.2646
vt 0.1001 0.0871
vt 0.1335 0.0712
vt 0.1401 0.0779
vt 0.1443 0.0878
vt 0.0340 0.0697
vt 0.0670 0.0867
vt 0.0262 0.0762
vt 0.0227 0.0860
vt 0.6170 0.0793
vt 0.5757 0.0697
vt 0.5824 0.0628
vt 0.5712 0.0800
vt 0.6971 0.0781
vt 0.6514 0.0788
vt 0.6936 0.0680
vt 0.6854 0.0613
vt 0.6157 0.8080
vt 0.6080 0.8452
vt 0.6078 0.7708
vt 0.6156 0.7708
vt 0.6158 0.8451
vt 0.0888 0.1814
vt 0.6288 0.1769
vt 0.1749 0.2636
vt 0.1793 0.2702
vt 0.5351 0.2688
vt 0.5395 0.2620
vt 0.1004 0.4487
vt 0.0169 0.4803
vt 0.6168 0.4537
vt 0.7032 0.4864
vt 0.0989 0.3987
vt 0.6183 0.4019
vt 0.0860 0.7722
vt 0.0860 0.7849
vt 0.0776 0.7810
vt 0.0943 0.7814
vt 0.3733 0.7978
vt 0.3732 0.8094
vt 0.3647 0.8057
vt 0.3817 0.8057
vt 0.0860 0.7723
vt 0.0859 0.7850
vt 0.0776 0.7811
vt 0.0944 0.7811
vt 0.0860 0.7725
vt 0.0860 0.7853
vt 0.0776 0.7813
vt 0.0944 0.7816
vt 0.1736 0.7894
vt 0.1540 0.8080
vt 0.1542 0.7708
vt 0.1735 0.8080
vt 0.1737 0.7709
vt 0.1736 0.8390
vt 0.1543 0.8576
vt 0.1541 0.8205
vt 0.1737 0.8576
vt 0.1735 0.8204
vt 0.2850 0.8080
vt 0.3045 0.8167
vt 0.2655 0.8166
vt 0.3045 0.8081
vt 0.2655 0.8080
vt 0.1214 0.7783
vt 0.1019 0.7709
vt 0.1409 0.7708
vt 0.1019 0.7783
vt 0.1409 0.7782
vt 0.1169 0.0710
vt 0.1004 0.0707
vt 0.0672 0.0702
vt 0.0506 0.0700
vt 0.6168 0.0623
vt 0.5996 0.0625
vt 0.6683 0.0615
vt 0.6511 0.0618
vt 0.0860 0.7724
vt 0.0944 0.7815
vt 0.0860 0.7852
vt 0.0776 0.7812
vt 0.0859 0.7723
vt 0.0943 0.7811
vt 0.0860 0.7850
vt 0.0776 0.7808
vt 0.0625 0.7818
vt 0.0709 0.7905
vt 0.0624 0.7943
vt 0.0539 0.7905
vt 0.0860 0.7723
vt 0.0944 0.7815
vt 0.0860 0.7850
vt 0.0776 0.7811
vt 0.7676 0.7708
vt 0.7838 0.7987
vt 0.7676 0.8823
vt 0.7677 0.9938
vt 0.7839 0.9659
vt 0.8066 0.8824
vt 0.8020 0.8545
vt 0.8021 0.9102
vt 0.7949 0.8266
vt 0.7949 0.9381
vt 0.4521 0.7708
vt 0.4520 0.8823
vt 0.4358 0.7987
vt 0.4520 0.9938
vt 0.4357 0.9659
vt 0.4130 0.8824
vt 0.4176 0.8545
vt 0.4176 0.9102
vt 0.4248 0.8266
vt 0.4247 0.9381
vt 0.9240 0.6031
vt 0.9786 0.6030
vt 0.9789 0.6810
vt 0.9243 0.6812
vt 0.9793 0.7925
vt 0.9246 0.7927
vt 0.9244 0.7146
vt 0.9790 0.7145
vt 0.9907 0.6977
vt 0.9126 0.6979
vt 0.7547 0.8655
vt 0.7546 0.7875
vt 0.4650 0.7875
vt 0.4650 0.8655
vt 0.9910 0.8092
vt 0.9130 0.8094
vt 0.7547 0.9770
vt 0.7547 0.8990
vt 0.4649 0.9770
vt 0.4650 0.8990
vt 0.9123 0.5864
vt 0.9903 0.5862
vt 0.7904 0.4763
vt 0.7913 0.7215
vt 0.7133 0.7218
vt 0.7124 0.4765
vt 0.9903 0.0062
vt 0.9123 0.0064
vt 0.1123 0.7877
vt 0.1215 0.7840
vt 0.1020 0.7969
vt 0.1085 0.7965
vt 0.1307 0.7876
vt 0.1410 0.7968
vt 0.1345 0.7964
vt 0.1020 0.8155
vt 0.1124 0.8052
vt 0.1215 0.8155
vt 0.1216 0.8088
vt 0.1410 0.8154
vt 0.1307 0.8052
vt 0.2657 0.7708
vt 0.2852 0.7709
vt 0.2760 0.7802
vt 0.2852 0.7766
vt 0.2656 0.7894
vt 0.2722 0.7890
vt 0.3047 0.7709
vt 0.2944 0.7803
vt 0.3046 0.7895
vt 0.2982 0.7890
vt 0.2759 0.7977
vt 0.2851 0.8014
vt 0.2943 0.7978
vt 0.0122 0.7673
vt 0.0128 0.9629
vt 0.0220 0.9543
vt 0.0214 0.7673
vt 0.0311 0.9455
vt 0.0306 0.7673
vt 0.0539 0.9677
vt 0.0623 0.9677
vt 0.0708 0.9677
vt 0.0305 0.7672
vt 0.0311 0.9456
vt 0.0214 0.7672
vt 0.0219 0.9547
vt 0.0121 0.7673
vt 0.0127 0.9631
vt 0.6304 0.9686
vt 0.6303 0.7722
vt 0.6389 0.9686
vt 0.6388 0.7684
vt 0.6472 0.7722
vt 0.6473 0.9686
vt 0.5833 0.9685
vt 0.5832 0.7683
vt 0.5916 0.7720
vt 0.5917 0.9685
vt 0.5748 0.9685
vt 0.5747 0.7721
vt 0.3323 0.7674
vt 0.3317 0.9544
vt 0.3415 0.7675
vt 0.3409 0.9627
vt 0.3231 0.7674
vt 0.3226 0.9454
vt 0.3731 0.9825
vt 0.3816 0.9825
vt 0.3647 0.9825
vt 0.3323 0.7674
vt 0.3317 0.9543
vt 0.3226 0.9455
vt 0.3231 0.7674
vt 0.3415 0.7674
vt 0.3409 0.9629
vt 0.5544 0.1780
vt 0.6227 0.2707
vt 0.7058 0.2793
vt 0.7032 0.1759
vt 0.7062 0.3829
vt 0.0144 0.2803
vt 0.0169 0.1804
vt 0.0947 0.2720
vt 0.0140 0.3803
vt 0.1606 0.1825
vt 0.7305 0.0271
vt 0.7695 0.0270
vt 0.7742 0.1327
vt 0.7266 0.1329
vt 0.7835 0.2450
vt 0.7179 0.2452
vt 0.7905 0.3576
vt 0.7116 0.3578
vt 0.8821 0.8254
vt 0.8775 0.9313
vt 0.8385 0.9312
vt 0.8345 0.8252
vt 0.8976 0.7347
vt 0.8196 0.7345
vt 0.8196 0.7273
vt 0.8976 0.7275
vt 0.8775 0.9422
vt 0.8385 0.9421
vt 0.7305 0.0164
vt 0.7695 0.0162
vt 0.2135 0.8081
vt 0.2134 0.7709
vt 0.2524 0.7708
vt 0.2525 0.8080
vt 0.4038 0.2508
vt 0.3891 0.2450
vt 0.3763 0.2399
vt 0.3657 0.2357
vt 0.9125 0.5356
vt 0.9251 0.5394
vt 0.9387 0.5418
vt 0.9529 0.5425
vt 0.9671 0.5417
vt 0.9808 0.5393
vt 0.9934 0.5354
vt 0.3428 0.2382
vt 0.3326 0.2422
vt 0.3202 0.2472
vt 0.3060 0.2528
vt 0.2989 0.2418
vt 0.3098 0.2312
vt 0.3194 0.2219
vt 0.3272 0.2143
vt 0.9796 0.5727
vt 0.9922 0.5727
vt 0.9660 0.5727
vt 0.9517 0.5727
vt 0.9375 0.5727
vt 0.9239 0.5727
vt 0.9113 0.5727
vt 0.3900 0.2189
vt 0.3819 0.2110
vt 0.3999 0.2285
vt 0.4112 0.2394
vt 0.4225 0.2317
vt 0.4162 0.2173
vt 0.4108 0.2047
vt 0.4063 0.1943
vt 0.6604 0.8043
vt 0.6603 0.7768
vt 0.6729 0.7768
vt 0.6730 0.8029
vt 0.6865 0.7768
vt 0.6866 0.8020
vt 0.7007 0.7768
vt 0.7009 0.8017
vt 0.7151 0.8020
vt 0.7150 0.7768
vt 0.7286 0.7768
vt 0.7287 0.8028
vt 0.7413 0.7768
vt 0.7413 0.8057
vt 0.3026 0.1982
vt 0.2980 0.2082
vt 0.2928 0.2204
vt 0.2867 0.2344
vt 0.2740 0.2316
vt 0.2740 0.2164
vt 0.2740 0.2031
vt 0.2740 0.1922
vt 0.7288 0.8408
vt 0.7414 0.8408
vt 0.7152 0.8408
vt 0.7010 0.8409
vt 0.6868 0.8409
vt 0.6731 0.8410
vt 0.6605 0.8410
vt 0.4355 0.1994
vt 0.4354 0.1881
vt 0.4357 0.2132
vt 0.4359 0.2289
vt 0.4493 0.2313
vt 0.4552 0.2167
vt 0.4603 0.2039
vt 0.4646 0.1934
vt 0.6606 0.8759
vt 0.6732 0.8773
vt 0.6869 0.8782
vt 0.7011 0.8784
vt 0.7153 0.8781
vt 0.7290 0.8772
vt 0.7415 0.8743
vt 0.2466 0.1973
vt 0.2507 0.2075
vt 0.2557 0.2199
vt 0.2614 0.2340
vt 0.2510 0.2411
vt 0.2403 0.2302
vt 0.2309 0.2206
vt 0.2232 0.2128
vt 0.7291 0.9050
vt 0.7416 0.9050
vt 0.7154 0.9050
vt 0.7012 0.9050
vt 0.6870 0.9050
vt 0.6733 0.9050
vt 0.6607 0.9050
vt 0.4816 0.2175
vt 0.4896 0.2094
vt 0.4719 0.2274
vt 0.4608 0.2387
vt 0.4686 0.2499
vt 0.4831 0.2436
vt 0.4959 0.2381
vt 0.5064 0.2336
vt 0.5591 0.8084
vt 0.5591 0.7696
vt 0.5508 0.8041
vt 0.5509 0.7696
vt 0.5371 0.7696
vt 0.5370 0.8013
vt 0.5227 0.7696
vt 0.5226 0.8004
vt 0.5083 0.7696
vt 0.5082 0.8012
vt 0.4944 0.7696
vt 0.4944 0.8039
vt 0.4833 0.7696
vt 0.4832 0.8082
vt 0.2069 0.2362
vt 0.2171 0.2405
vt 0.2294 0.2458
vt 0.2435 0.2518
vt 0.4943 0.8380
vt 0.4832 0.8389
vt 0.5507 0.8382
vt 0.5590 0.8392
vt 0.278878 0.703178
vt 0.253819 0.716511
vt 0.179532 0.701810
vt 0.228832 0.725468
vt 0.203884 0.731133
vt 0.178964 0.734604
vt 0.154145 0.730399
vt 0.129353 0.723999
vt 0.104601 0.714308
vt 0.079920 0.700241
vt 0.431919 0.717207
vt 0.534793 0.715791
vt 0.457868 0.731013
vt 0.483743 0.740288
vt 0.509576 0.746155
vt 0.535381 0.749749
vt 0.561081 0.745394
vt 0.586754 0.738768
vt 0.612384 0.728732
vt 0.637941 0.714166
vt 0.436351 0.263634
vt 0.452760 0.256613
vt 0.454221 0.263365
vt 0.257340 0.264895
vt 0.258752 0.258374
vt 0.274599 0.265155
vt 0.262575 0.252885
vt 0.448801 0.250929
vt 0.442948 0.247179
vt 0.267522 0.249263
vt 0.274027 0.248060
vt 0.436091 0.245932
vt 0.429276 0.247380
vt 0.280192 0.249458
vt 0.286972 0.253245
vt 0.423538 0.251302
vt 0.419752 0.257100
vt 0.290628 0.258845
vt 0.291842 0.265404
vt 0.418495 0.263892
vt 0.183823 0.417116
vt 0.185835 0.274669
vt 0.200910 0.263945
vt 0.240731 0.264634
vt 0.225409 0.264382
vt 0.211963 0.264150
vt 0.530350 0.420990
vt 0.512656 0.262381
vt 0.528266 0.273486
vt 0.501210 0.262593
vt 0.487287 0.262834
vt 0.471420 0.263095
vt 0.225133 0.830153
vt 0.212644 0.835454
vt 0.210774 0.820467
vt 0.210789 0.849529
vt 0.482964 0.848157
vt 0.522503 0.837339
vt 0.508115 0.837493
vt 0.561965 0.848385
vt 0.536885 0.837576
vt 0.238139 0.830153
vt 0.250628 0.835454
vt 0.252483 0.849529
vt 0.252498 0.820467
vt 0.266160 0.451139
vt 0.348498 0.485162
vt 0.445089 0.456221
vt 0.359828 0.491452
vt 0.337016 0.265996
vt 0.347957 0.266116
vt 0.991022 0.254517
vt 0.993282 0.504132
vt 0.980681 0.504526
vt 0.967012 0.504786
vt 0.952802 0.504901
vt 0.308409 0.265633
vt 0.323663 0.265833
vt 0.371717 0.264505
vt 0.385545 0.264336
vt 0.401340 0.264129
vt 0.912990 0.254745
vt 0.938595 0.504869
vt 0.924939 0.504689
vt 0.912357 0.504368
vt 0.360388 0.264629
vt 0.100115 0.087143
vt 0.133523 0.071208
vt 0.140055 0.077876
vt 0.144328 0.087796
vt 0.034043 0.069739
vt 0.066956 0.086654
vt 0.026207 0.076195
vt 0.022743 0.086001
vt 0.617029 0.079302
vt 0.575671 0.069706
vt 0.582436 0.062801
vt 0.571247 0.079978
vt 0.697149 0.078119
vt 0.651366 0.078795
vt 0.693561 0.067965
vt 0.685447 0.061280
vt 0.615719 0.807963
vt 0.608035 0.845155
vt 0.607796 0.770817
vt 0.615599 0.770794
vt 0.615839 0.845132
vt 0.088766 0.181427
vt 0.628781 0.176933
vt 0.174947 0.263556
vt 0.179269 0.270191
vt 0.535065 0.268849
vt 0.539541 0.261978
vt 0.100362 0.448691
vt 0.016901 0.480267
vt 0.616773 0.453686
vt 0.703197 0.486382
vt 0.098908 0.398703
vt 0.618279 0.401923
vt 0.085984 0.772244
vt 0.086018 0.784942
vt 0.077586 0.781005
vt 0.094347 0.781441
vt 0.373264 0.797780
vt 0.373186 0.809445
vt 0.364748 0.805708
vt 0.381669 0.805715
vt 0.085993 0.772336
vt 0.085941 0.785034
vt 0.077574 0.781081
vt 0.094399 0.781097
vt 0.086039 0.772537
vt 0.086044 0.785291
vt 0.077615 0.781299
vt 0.094364 0.781632
vt 0.173598 0.789435
vt 0.154045 0.807963
vt 0.154165 0.770794
vt 0.173538 0.808019
vt 0.173658 0.770850
vt 0.173598 0.838994
vt 0.154253 0.857633
vt 0.154134 0.820464
vt 0.173658 0.857578
vt 0.173539 0.820409
vt 0.285040 0.808020
vt 0.304520 0.816750
vt 0.265503 0.816636
vt 0.304548 0.808077
vt 0.265531 0.807963
vt 0.121412 0.778285
vt 0.101880 0.770908
vt 0.140896 0.770794
vt 0.101904 0.778342
vt 0.140920 0.778228
vt 0.116943 0.070963
vt 0.100363 0.070718
vt 0.067203 0.070229
vt 0.050623 0.069984
vt 0.616773 0.062294
vt 0.599604 0.062548
vt 0.668278 0.061534
vt 0.651110 0.061787
vt 0.086020 0.772448
vt 0.094405 0.781544
vt 0.085980 0.785203
vt 0.077595 0.781211
vt 0.085936 0.772300
vt 0.094341 0.781061
vt 0.085960 0.784998
vt 0.077644 0.780837
vt 0.062457 0.781824
vt 0.070863 0.790539
vt 0.062379 0.794269
vt 0.053942 0.790532
vt 0.085980 0.772322
vt 0.094391 0.781518
vt 0.086038 0.785019
vt 0.077609 0.781083
vt 0.767577 0.770794
vt 0.783831 0.798683
vt 0.767628 0.882299
vt 0.767679 0.993805
vt 0.783908 0.965941
vt 0.806592 0.882352
vt 0.802033 0.854469
vt 0.802059 0.910222
vt 0.794879 0.826580
vt 0.794931 0.938086
vt 0.452065 0.770794
vt 0.452014 0.882299
vt 0.435810 0.798683
vt 0.451962 0.993805
vt 0.435733 0.965941
vt 0.413050 0.882352
vt 0.417608 0.854469
vt 0.417583 0.910222
vt 0.424762 0.826580
vt 0.424711 0.938086
vt 0.924018 0.603112
vt 0.978641 0.602953
vt 0.978892 0.681008
vt 0.924269 0.681167
vt 0.979251 0.792515
vt 0.924628 0.792675
vt 0.924377 0.714620
vt 0.979000 0.714460
vt 0.990651 0.697700
vt 0.912618 0.697928
vt 0.754667 0.865511
vt 0.754631 0.787457
vt 0.465010 0.787457
vt 0.464974 0.865511
vt 0.991010 0.809207
vt 0.912977 0.809435
vt 0.754719 0.977017
vt 0.754683 0.898963
vt 0.464923 0.977016
vt 0.464959 0.898962
vt 0.912259 0.586421
vt 0.990292 0.586192
vt 0.790420 0.476299
vt 0.791299 0.721545
vt 0.713266 0.721773
vt 0.712388 0.476527
vt 0.990292 0.006195
vt 0.912259 0.006423
vt 0.112300 0.787704
vt 0.121485 0.784048
vt 0.101964 0.796926
vt 0.108519 0.796476
vt 0.130693 0.787650
vt 0.140980 0.796812
vt 0.134530 0.796400
vt 0.102023 0.815511
vt 0.112357 0.805226
vt 0.121532 0.815454
vt 0.121565 0.808828
vt 0.141040 0.815397
vt 0.130749 0.805172
vt 0.265651 0.770794
vt 0.285159 0.770851
vt 0.275987 0.780217
vt 0.285195 0.776615
vt 0.265591 0.789379
vt 0.272150 0.788967
vt 0.304667 0.770908
vt 0.294379 0.780271
vt 0.304608 0.789493
vt 0.298160 0.789043
vt 0.275931 0.797739
vt 0.285115 0.801394
vt 0.294323 0.797792
vt 0.012190 0.767332
vt 0.012807 0.962877
vt 0.021981 0.954325
vt 0.021391 0.767328
vt 0.031145 0.945491
vt 0.030583 0.767278
vt 0.053872 0.967703
vt 0.062311 0.967723
vt 0.070792 0.967711
vt 0.030543 0.767204
vt 0.031088 0.945576
vt 0.021352 0.767207
vt 0.021924 0.954732
vt 0.012150 0.767258
vt 0.012749 0.963133
vt 0.630380 0.968589
vt 0.630303 0.772166
vt 0.638862 0.968602
vt 0.638783 0.768425
vt 0.647224 0.772158
vt 0.647301 0.968582
vt 0.583265 0.968531
vt 0.583187 0.768315
vt 0.591627 0.772049
vt 0.591705 0.968511
vt 0.574784 0.968519
vt 0.574706 0.772056
vt 0.332301 0.767413
vt 0.331729 0.954403
vt 0.341503 0.767466
vt 0.340904 0.962684
vt 0.323110 0.767412
vt 0.322565 0.945376
vt 0.373117 0.982521
vt 0.381599 0.982509
vt 0.364678 0.982501
vt 0.332308 0.767388
vt 0.331718 0.954342
vt 0.322554 0.945508
vt 0.323116 0.767359
vt 0.341509 0.767413
vt 0.340892 0.962894
vt 0.554384 0.178003
vt 0.622676 0.270671
vt 0.705834 0.279346
vt 0.703178 0.175863
vt 0.706214 0.382853
vt 0.014354 0.280328
vt 0.016920 0.180394
vt 0.094662 0.271951
vt 0.013988 0.380287
vt 0.160613 0.182460
vt 0.730524 0.027073
vt 0.769540 0.026959
vt 0.774153 0.132734
vt 0.726553 0.132873
vt 0.783472 0.245039
vt 0.717925 0.245231
vt 0.790455 0.357605
vt 0.711642 0.357836
vt 0.882146 0.825363
vt 0.877541 0.931296
vt 0.838525 0.931182
vt 0.834546 0.825224
vt 0.897630 0.734717
vt 0.819597 0.734489
vt 0.819614 0.727254
vt 0.897647 0.727482
vt 0.877513 0.942245
vt 0.838496 0.942131
vt 0.730495 0.016363
vt 0.769511 0.016249
vt 0.213482 0.808077
vt 0.213362 0.770908
vt 0.252378 0.770794
vt 0.252498 0.807963
vt 0.403807 0.250806
vt 0.389126 0.244994
vt 0.376276 0.239887
vt 0.365749 0.235681
vt 0.912466 0.535638
vt 0.925060 0.539433
vt 0.938724 0.541754
vt 0.952933 0.542509
vt 0.967141 0.541671
vt 0.980802 0.539271
vt 0.993391 0.535401
vt 0.342780 0.238161
vt 0.332614 0.242222
vt 0.320204 0.247154
vt 0.306027 0.252767
vt 0.298855 0.241783
vt 0.309792 0.231208
vt 0.319363 0.221927
vt 0.327199 0.214296
vt 0.979609 0.572736
vt 0.992187 0.572736
vt 0.965956 0.572736
vt 0.951750 0.572736
vt 0.937539 0.572736
vt 0.923868 0.572736
vt 0.911262 0.572736
vt 0.389997 0.218871
vt 0.381884 0.210969
vt 0.399907 0.228482
vt 0.411233 0.239432
vt 0.422487 0.231740
vt 0.416246 0.217314
vt 0.410793 0.204657
vt 0.406337 0.194255
vt 0.660412 0.804290
vt 0.660326 0.776759
vt 0.672896 0.776759
vt 0.672992 0.802873
vt 0.686546 0.776759
vt 0.686648 0.801994
vt 0.700750 0.776759
vt 0.700854 0.801686
vt 0.715065 0.801961
vt 0.714963 0.776759
vt 0.728638 0.776759
vt 0.728734 0.802808
vt 0.741251 0.776759
vt 0.741337 0.805685
vt 0.302573 0.198155
vt 0.298041 0.208200
vt 0.292774 0.220423
vt 0.286747 0.234354
vt 0.274027 0.231611
vt 0.274027 0.216441
vt 0.274027 0.203132
vt 0.274027 0.192195
vt 0.728847 0.840799
vt 0.741438 0.840762
vt 0.715184 0.840839
vt 0.700976 0.840880
vt 0.686767 0.840922
vt 0.673105 0.840962
vt 0.660513 0.840999
vt 0.435497 0.199409
vt 0.435385 0.188084
vt 0.435656 0.213191
vt 0.435857 0.228900
vt 0.449306 0.231344
vt 0.455181 0.216739
vt 0.460348 0.203925
vt 0.464607 0.193395
vt 0.660615 0.875927
vt 0.673218 0.877314
vt 0.686887 0.878162
vt 0.701098 0.878437
vt 0.715304 0.878128
vt 0.728960 0.877249
vt 0.741540 0.874343
vt 0.246606 0.197324
vt 0.250719 0.207493
vt 0.255708 0.219868
vt 0.261382 0.233972
vt 0.251000 0.241076
vt 0.240317 0.230182
vt 0.230937 0.220621
vt 0.223221 0.212761
vt 0.729055 0.905002
vt 0.741626 0.905002
vt 0.715406 0.905002
vt 0.701202 0.905002
vt 0.686989 0.905002
vt 0.673313 0.905002
vt 0.660701 0.905002
vt 0.481563 0.217519
vt 0.489553 0.209380
vt 0.471850 0.227420
vt 0.460787 0.238701
vt 0.468553 0.249850
vt 0.483124 0.243606
vt 0.495911 0.238121
vt 0.506425 0.233604
vt 0.559079 0.808445
vt 0.559132 0.769612
vt 0.550830 0.804052
vt 0.550892 0.769612
vt 0.537054 0.769612
vt 0.536989 0.801330
vt 0.522676 0.769612
vt 0.522610 0.800383
vt 0.508285 0.769612
vt 0.508219 0.801247
vt 0.494434 0.769612
vt 0.494372 0.803890
vt 0.483291 0.769612
vt 0.483238 0.808208
vt 0.206927 0.236155
vt 0.217080 0.240516
vt 0.229429 0.245814
vt 0.243500 0.251844
vt 0.494274 0.838032
vt 0.483154 0.838936
vt 0.550732 0.838195
vt 0.558994 0.839172
s off
f 1/1 2/2 3/3
f 2/2 4/4 3/3
@ -1230,3 +1230,8 @@ f 52/52 248/427 249/428
f 52/52 249/428 51/51
f 23/23 22/22 248/427
f 23/23 248/427 52/52
l 262 92
l 87 261
l 261 89
l 42 93
l 49 262

View file

@ -72,7 +72,7 @@ load = do
fragmentShader = foldl BS.append BS.empty
[ "varying vec2 f_texcoord;"
, "void main(void) {"
, " gl_FragColor = vec4(1,1,1,0.5);"
, " gl_FragColor = vec4(0,0,0,0.5);"
, "}"
]
p <- GLU.simpleShaderProgramBS vertexShader fragmentShader

View file

@ -24,15 +24,17 @@ import Foreign
import Util
import Types
import Debug.Trace
load :: IO StateData
load = do
_ <- SDL.setMouseLocationMode SDL.RelativeLocation
GL.depthFunc $= Just GL.Less
svao <- GL.genObjectName
GL.bindVertexArrayObject $= Just svao
(shipBO, sobj, stl) <- genVertBufObject "assets/ships/jaeger/jaeger.obj"
(vectHandleBO, hobj, vhtl) <- genVertBufObject "assets/spheres/vertHandle.obj"
texture <- GL.genObjectName
GL.bindBuffer GL.ArrayBuffer $= Just texture
maybe (return ()) (\a -> withArray a $ \ptr ->
@ -46,12 +48,20 @@ load = do
, GL.VertexArrayDescriptor 2 GL.Float 0 (plusPtr nullPtr 0)
)
GL.vertexAttribArray (GL.AttribLocation 1) $= GL.Enabled
GL.bindBuffer GL.ArrayBuffer $= Nothing
GL.texture GL.Texture2D $= GL.Enabled
GL.activeTexture $= GL.TextureUnit 0
t <- loadTex "assets/ships/jaeger/jaeger.texture.tga"
GL.textureBinding GL.Texture2D $= Just t
GL.bindVertexArrayObject $= Nothing
hvao <- GL.genObjectName
GL.bindVertexArrayObject $= Just hvao
(vectHandleBO, hobj, vhtl) <- genVertBufObject "assets/spheres/vertHandle.obj"
GL.bindVertexArrayObject $= Nothing
let vertexShader = foldl BS.append BS.empty
[ "attribute vec3 coord3d;"
, "attribute vec2 texcoord;"
@ -73,26 +83,29 @@ load = do
fragmentShaderHandle = foldl BS.append BS.empty
[ "varying vec2 f_texcoord;"
, "void main(void) {"
, " gl_FragColor = vec4(0,0,0,0.5);"
, " gl_FragColor = vec4(1.0,0.0,1.0,0.5);"
, "}"
]
handleProgram <- GLU.simpleShaderProgramBS vertexShader fragmentShaderHandle
shipProgram <- GLU.simpleShaderProgramBS vertexShader fragmentShaderShip
hProgram <- GLU.simpleShaderProgramBS vertexShader fragmentShaderHandle
sProgram <- GLU.simpleShaderProgramBS vertexShader fragmentShaderShip
phys <- initPhysics
po <- initPhysicsObjects
-- traceIO $ show $ loLines sobj
-- mapM_ (addRigidBody (pWorld phys)) (map bodyRigidBody (poBalls po))
addRigidBody (pWorld phys) (bodyRigidBody $ poBall po)
return StateData
{ ship = Ship shipBO stl
{ ship = (Ship svao stl
(V3 0 0 0)
(Quaternion 1 (V3 0 0 0))
(Just t)
, vertHandles = createHandles vectHandleBO vhtl (loPoints sobj)
(Just texture))
, vertHandles = createHandles hvao vhtl (loTriangles sobj)
, proj = perspective (pi/2) (1600 / 900) 1 (-1)
, camera = Camera
{ cameraFocus = V3 0 0 0
@ -101,8 +114,8 @@ load = do
}
, physics = phys
, physicsObjects = po
, shipProgram = shipProgram
, handleProgram = handleProgram
, shipProgram = sProgram
, handleProgram = hProgram
}
initPhysics :: IO Physics
@ -136,7 +149,7 @@ initPhysicsObjects = do
{ poBall = PhysBody ball ballMotionState ballBody
}
genVertBufObject :: FilePath -> IO (GL.VertexArrayObject, LoadedObject, Int)
genVertBufObject :: FilePath -> IO (GL.BufferObject, LoadedObject, Int)
genVertBufObject path = do
eobj <- fromFile path
let obj = case eobj of
@ -144,11 +157,8 @@ genVertBufObject path = do
Left err -> error err
lobj = loadObj obj
shipBO <- GL.genObjectName
GL.bindVertexArrayObject $= Just shipBO
verts <- GL.genObjectName
GL.bindBuffer GL.ArrayBuffer $= Just verts
vbo <- GL.genObjectName
GL.bindBuffer GL.ArrayBuffer $= Just vbo
withArray (loTriangles lobj) $ \ptr ->
GL.bufferData GL.ArrayBuffer $=
( fromIntegral $ length (loTriangles lobj) * 3 * sizeOf (0 :: Double)
@ -160,11 +170,11 @@ genVertBufObject path = do
, GL.VertexArrayDescriptor 4 GL.Float 0 (plusPtr nullPtr 0)
)
GL.vertexAttribArray (GL.AttribLocation 0) $= GL.Enabled
return (shipBO, lobj, length (loTriangles lobj))
return (vbo, lobj, length (loTriangles lobj))
createHandles :: GL.VertexArrayObject -> Int -> [Float] -> [Ship]
createHandles bo len ps =
map (\p -> Ship bo len (toPos p) (Quaternion 1 (V3 0 0 0)) Nothing) tris
map (\p -> Ship bo len (toPos p) (Quaternion 1 (V3 0 0 0)) Nothing Nothing) tris
where
tris = chunksOf 3 ps
toPos [x, y, z] = V3 x y z

View file

@ -81,18 +81,21 @@ draw =
(V3 0 0 (-cameraDist camera)))
(cameraFocus camera)
(V3 0 1 0)
GL.currentProgram $= (Just . GLU.program $ shipProgram)
drawShip shipProgram view ship
GL.currentProgram $= (Just . GLU.program $ handleProgram)
mapM_ (drawShip shipProgram view) vertHandles
mapM_ (drawShip handleProgram view) vertHandles
where
drawShip program view (Ship{..}) = do
StateData{..} <- getAffection
GL.currentProgram $= (Just . GLU.program $ program)
let model = mkTransformation shipRot shipPos
pvm = proj !*! view !*! model
liftIO $ GLU.setUniform program "mvp" pvm
GL.bindVertexArrayObject $= Just shipVao
GL.bindBuffer GL.ArrayBuffer $= shipUVs
liftIO $ GL.drawArrays GL.Triangles 0 (fromIntegral shipVaoLen)
GL.currentProgram $= Nothing
GL.bindBuffer GL.ArrayBuffer $= Nothing
GL.bindVertexArrayObject $= Nothing
handle :: SDL.EventPayload -> Affection StateData ()
handle (SDL.WindowClosedEvent _) = quit

View file

@ -26,6 +26,7 @@ data Ship = Ship
, shipPos :: V3 Float
, shipRot :: Quaternion Float
, shipTexture :: Maybe GL.TextureObject
, shipUVs :: Maybe GL.BufferObject
}
data Camera = Camera

View file

@ -11,12 +11,14 @@ import qualified Graphics.GLUtil as GLU
import qualified Data.Vector as V
import Debug.Trace
data LoadedObject = LoadedObject
{ loTriangles :: [Float]
, loLines :: [Float]
, loPoints :: [Float]
, loTexTri :: Maybe [Float]
}
} deriving (Show)
loadObj :: WavefrontOBJ -> LoadedObject
loadObj obj =
@ -26,7 +28,8 @@ loadObj obj =
interTex = objTexCoords obj
faces = map elValue (V.toList $ objFaces obj)
lns = map elValue (V.toList $ objLines obj)
points = map elValue (V.toList $ objPoints obj)
points = trace (show $ map elValue (V.toList $ objPoints obj))
(map elValue (V.toList $ objPoints obj))
deface (Face a b c []) =
map (\i -> inter V.! (faceLocIndex i -1)) [a, b, c]
deface _ =
@ -36,7 +39,7 @@ loadObj obj =
depoint (Point i) = inter V.! (i - 1)
tsLocs = concatMap deface faces
lsLocs = concatMap deline lns
psLocs = map depoint points
psLocs = map depoint (trace (show points) points)
deLoc (Location x y z w) = [x, y, z, w]
deTex (TexCoord r s _) = [r, s]
ts = concatMap deLoc tsLocs