Users browsing this thread: 1 Guest(s)
Zelda64 Models
#42
(06-18-2013, 09:31 PM)RodLima Wrote:
Quote:btw RodLima, I forgot to mention that you can make the animations import a lot faster if you buffer segment 7. that's how the model itself imports so fast.

Um, but the normal models that don't use the segment_07 took same time to import, I think it take some time because blender uses only one core to do the python Transforms

that shouldn't be a problem at all. if the script can convert / export 20+ textures and locate / import 21 + display lists, texture / position / and skin all of them instantaneously, there's no reason why a few matrix instructions should cause it to lag out so badly. All modern games execute hundreds of matrix instructions a second.

The only thing that should cause such a bad lag is if you're using file operations. Aside from segment_07, are you using the already buffered data for segment_05/06, or are you using a file handle?

EDIT:
As far as arrays in python go, its simple.

Code:
myarray = []   # initialize an empty array
myarray = [0, 2, 3]  #initialize an array
myarray[0] = 1   # assign an element
myarray[1:]   # this is a slice of just [2, 3]
myarray[:1]   # this is a slice of just [1, 2]
myarray[:-1]  # this is a slice of just [1, 2]
myarray.append(4)   # add 1 item to an array
myarray.extend([4])  # add items from another array to this array
offset = 0
val = unpack_from(">L", myarray, offset)[0]   # read a big endian unsigned long value (long = 32 bit) from the array

# unpack_from returns a tuple. the first argument is the format specifier where:
#    > = big endian,    < = little endian
#    capital letter = unsigned, lowercase letter = signed
#    B = byte,   H = halfword (16-bit, 2 bytes)  L = long (32-bit, 4 bytes)
# if you did unpack_from(">LLL", myarray, offset), it would return a tuple with 3 items because 3 L's

# how to buffer a file
file = open(filename, 'rb')
myarray = file.read()
file.close()
Thanked by:


Messages In This Thread
Zelda64 Models - by SoulofDeity - 03-14-2013, 01:07 AM
RE: Zelda64 Models - by Ton - 03-14-2013, 01:14 AM
RE: Zelda64 Models - by SoulofDeity - 03-14-2013, 01:19 AM
RE: Zelda64 Models - by Previous - 03-14-2013, 05:45 AM
RE: Zelda64 Models - by SoulofDeity - 03-14-2013, 08:45 AM
RE: Zelda64 Models - by Garamonde - 03-14-2013, 07:47 AM
RE: Zelda64 Models - by Garamonde - 03-14-2013, 09:02 AM
RE: Zelda64 Models - by SoulofDeity - 03-14-2013, 10:09 AM
RE: Zelda64 Models - by Garamonde - 03-14-2013, 11:18 AM
RE: Zelda64 Models - by SoulofDeity - 03-14-2013, 11:47 AM
RE: Zelda64 Models - by Ton - 03-14-2013, 12:24 PM
RE: Zelda64 Models - by Garamonde - 03-14-2013, 02:01 PM
RE: Zelda64 Models - by wat - 03-14-2013, 04:05 PM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 12:19 AM
RE: Zelda64 Models - by Friedslick6 - 03-15-2013, 01:58 AM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 05:59 AM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 02:37 PM
RE: Zelda64 Models - by Friedslick6 - 03-15-2013, 07:16 AM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 09:03 AM
RE: Zelda64 Models - by o0DemonBoy0o - 03-15-2013, 11:01 AM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 12:15 PM
RE: Zelda64 Models - by Random Talking Bush - 03-15-2013, 02:07 PM
RE: Zelda64 Models - by josh98 - 03-15-2013, 02:42 PM
RE: Zelda64 Models - by Friedslick6 - 03-15-2013, 03:30 PM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 03:58 PM
RE: Zelda64 Models - by Friedslick6 - 03-15-2013, 04:11 PM
RE: Zelda64 Models - by SoulofDeity - 03-15-2013, 05:46 PM
RE: Zelda64 Models - by TGE - 03-18-2013, 08:12 AM
RE: Zelda64 Models - by SoulofDeity - 03-21-2013, 10:54 PM
RE: Zelda64 Models - by SoulofDeity - 04-07-2013, 07:52 PM
RE: Zelda64 Models - by Txikimorin - 04-30-2013, 06:44 PM
RE: Zelda64 Models - by SoulofDeity - 06-03-2013, 03:19 AM
RE: Zelda64 Models - by RodLima - 06-06-2013, 12:12 PM
RE: Zelda64 Models - by Tiberious - 06-15-2013, 01:35 PM
RE: Zelda64 Models - by SoulofDeity - 06-18-2013, 08:48 PM
RE: Zelda64 Models - by RodLima - 06-18-2013, 09:31 PM
RE: Zelda64 Models - by SoulofDeity - 06-19-2013, 06:35 AM
RE: Zelda64 Models - by RodLima - 06-19-2013, 12:53 PM
RE: Zelda64 Models - by Previous - 04-30-2013, 06:59 PM
RE: Zelda64 Models - by SoulofDeity - 06-11-2013, 04:39 PM
RE: Zelda64 Models - by RodLima - 06-11-2013, 05:07 PM
RE: Zelda64 Models - by Leo22 - 06-13-2013, 09:04 AM
RE: Zelda64 Models - by RodLima - 06-13-2013, 09:34 AM
RE: Zelda64 Models - by SoulofDeity - 06-19-2013, 09:36 PM
RE: Zelda64 Models - by RodLima - 06-19-2013, 10:07 PM
RE: Zelda64 Models - by SoulofDeity - 08-25-2013, 02:27 AM

Forum Jump: