Page 43 of 123

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 9:11 pm
by MrAdults
Noesis has a function to encode a float in 2 bytes as a half-float, yeah. It's noesis.encodeFloat16. (or Math_EncodeFloat16 for native plugins) This encodes the float according to the IEEE 754 binary16 standard.

Noesis breaks everything down to raw triangle lists behind the scenes, regardless of how you feed the data in, or what type of index you feed into it. Satoh, in your case, you should use the immBegin/immEnd functions as mentioned previously. These allow you to loop through any kind of data feeding 1 triangle at a time (or more, if desired) to Noesis, where each triangle can have any given set of components. Noesis will then automatically batch the triangles into mesh buckets behind the scenes when the model is constructed, and you don't have to worry about breaking things up yourself at all.

Oh, and Noesis has support for 2 sets of UV's. The second set is typically used for lightmaps, but you can use it for whatever you want really.

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 9:20 pm
by Satoh
I see, thank you, I'll try that.
Will that impact the performance of noesis at all though?

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 10:13 pm
by Privateer
MrAdults wrote:Noesis has a function to encode a float in 2 bytes as a half-float, yeah. It's noesis.encodeFloat16. (or Math_EncodeFloat16 for native plugins) This encodes the float according to the IEEE 754 binary16 standard.
So your saying I can decode the need info without the code I posted?
I can take x07 x7f and get the half-float?
I know you plan on better documentation ASAP and that's probably what I need.
In any case? Thanks for putting up with questions.

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 10:16 pm
by finale00
Ya, just pass the bytes to encodefloat16 and you should get the same output.
Maybe you can check that that is true.

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 10:21 pm
by Privateer
finale00 wrote:Ya, just pass the bytes to encodefloat16 and you should get the same output.
Maybe you can check that that is true.
Thanks for the responce.
I'll do that and respond.

Re: Señor Casaroja's Noesis

Posted: Fri Dec 23, 2011 10:37 pm
by Rolandonmilk
oh alright how do you get to view it in noesis or switch been finicing through data but nothing :(

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 4:17 am
by MrAdults
Satoh: No, performance shouldn't be impacted. The more logic you do in Python the longer your load times are going to be, naturally, but I wouldn't expect your load times should be getting upwards of 1 second unless you're looping through for hundreds of thousands of triangles.
Privateer wrote:So your saying I can decode the need info without the code I posted?
I can take x07 x7f and get the half-float?
I know you plan on better documentation ASAP and that's probably what I need.
In any case? Thanks for putting up with questions.
From what you said before, you wanted to encode a float into a half-float, but now it sounds like you want to decode a half-float from 2 bytes. You can do that as well, the function is noesis.getFloat16(yourint). (it expects an integer in the range of 0-65535)

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 3:41 pm
by Privateer
Thank You MrAdults,
That's what I was looking for and I admit I didn't understand the definition when I first looked at it.
I feel like an idiot but I learned a few things along the way.
:lol:

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 8:50 pm
by UltimateSora
Hi, is there anyway to remove parts from a model before exporting it? When I use Data Viewer, I can highlight the individual sections. But there's no way to remove them, as far as I know. :(

Image

Thanks. :)

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 9:43 pm
by finale00
You can double-click on "skip render" and it should not be rendered.
I don't know whether exporting from preview will also skip those though (I would like to think it does, since there are two ways to export o.O)

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 9:49 pm
by chrrox
why not just delete what you dont want in the program your loading it in?

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 10:09 pm
by UltimateSora
finale00 wrote:You can double-click on "skip render" and it should not be rendered.
I don't know whether exporting from preview will also skip those though (I would like to think it does, since there are two ways to export o.O)
Sadly that method doesn't work. :(
chrrox wrote:why not just delete what you dont want in the program your loading it in?
Because it's time consuming and somewhat challenging. :(

Re: Señor Casaroja's Noesis

Posted: Sat Dec 24, 2011 10:46 pm
by chrrox
what do you mean?
if they are separate mesh pieces in noesis they will be in your program also.
just click on the mesh and delete it done.
what program are you using?

Re: Señor Casaroja's Noesis

Posted: Sun Dec 25, 2011 1:32 am
by Satoh
chrrox wrote:what do you mean?
if they are separate mesh pieces in noesis they will be in your program also.
just click on the mesh and delete it done.
what program are you using?
I get the feeling, and I apologize if I'm wrong, that he doesn't know how to use a modeling program very well, or that the program he's using doesn't actually do modeling so much as pure animation or something similar.

In any case, @UltimateSora, you could try hiding the meshes you don't need, and exporting from preview. That may or may not export the hidden meshes. I've never tried it.

Re: Señor Casaroja's Noesis

Posted: Sun Dec 25, 2011 4:37 am
by MrAdults
Privateer: Ok then, no worries, glad we've got that sorted out. :)

Hiding meshes in preview doesn't actually get rid of the mesh, it just disables rendering of it. Unfortunately, most formats don't tend to support such a "hidden" feature natively (I'm certain that FBX does, but I have no idea how to reliably set whether something is hidden through Autodesk's insane SDK...not that I've actually looked, I suppose that might be handy), so that setting doesn't carry over to export. Export from preview does exist to export data as seen in the preview and as modified by the data viewer, though, just to verify that point. I personally tend to use it mostly for exporting model+anim combinations after matching the anim to the model via drag-and-drop. (though you could again accomplish more or less the same thing by using the -loadanim option on export)

It should however be trivial, as chrrox mentioned, to select objects by name to hide/delete them in your modeling program of choice. I'm assuming you must be aware of how to do this much, mainly because I can't imagine what business anyone would have importing models into another program without at least knowing how to do so much as select and hide/remove objects in that program. It's probably something you have to learn how to do anyway if you want to get anything interesting done. I also recommend FBX as your format of choice for exporting to Max and Maya, because I know they handle importing the data well and keeping mesh names intact. For Blender, I don't really know, because I've never tried any Blender FBX importers. If you're trying to use SMD or something (don't!) that's going to fuck up the preservation of meshes, because that format just pools everything into material-based triangle lists.