Sorry, I'm using FP10 from trunk. On Mar 18, 11:46 pm, charglerode <[email protected]> wrote: > When loading as OBJ I didn't have access to the material library. As > per your suggestion I tried using AWD instead but once I use the > bitmap data from the material to try and reapply as a > WhiteShadingBitmapMaterial it doesn't work and all I get is the white > color material. A few posts up you'll see exactly how I am grabbing > the bitmap data. Thanks again, I know your time is limited, but I do > sincerely appreciate the help. > > On Mar 18, 2:55 pm, Fabrice3D <[email protected]> wrote: > > > > > I've just searched in this group and found back loads of doc on obj, even > > saw you're got several answers. > > So what is exactly not working now, or is it still the same white default > > material? (--> often means mtl is wrong or missing) > > You are using Flash 9 version from svn trunk right? > > > Fabrice > > > On Mar 18, 2010, at 5:51 PM, charglerode wrote: > > > > Please help me guys. This is becoming a deal breaker for me. If Away > > > can't support an OBJ pipeline with access to materials then I will > > > have to abandon it. > > > > On Mar 14, 10:19 pm, charglerode <[email protected]> wrote: > > >> Bump > > > >> On Mar 11, 2:33 pm, charglerode <[email protected]> wrote: > > > >>> Ok, so I was able to retrieve the mesh from the object container, but > > >>> the I still need access to the bitmapmaterial'sbitmap data. I tried > > >>> grabbing it from the meshmaterial, but all I get is a solid white > > >>> material. Any ideas? > > > >>> _mesh = e.loader.handle as ObjectContainer3D; > > >>> var mat:WhiteShadingBitmapMaterial = new > > >>> WhiteShadingBitmapMaterial( _mesh.children[1].material.bitmap ); > > >>> _mesh.children[1].material= mat; > > > >>> On Mar 11, 12:50 pm, Fabrice3D <[email protected]> wrote: > > > >>>> again, the Object3d returned from .awd data, id either a Mesh (when > > >>>> there is only a single mesh) or > > >>>> an ObjectContainer3D with more object3d's in it > > > >>>> ObjectContainer3Ds do not have propertymaterial, you need to parse > > >>>> your loader.handle to find meshes. > > >>>> look in geom package at methods of recursive parsing. > > > >>>> Fabrice > > > >>>> On Mar 11, 2010, at 9:36 PM, charglerode wrote: > > > >>>>> I'm retrieving the object from the Loader3DEvent handle as an > > >>>>> Object3D. The Object3D has nomaterialproperty and I cant cast it as > > >>>>> Mesh. > > > >>>>> On Mar 11, 11:55 am, Fabrice3D <[email protected]> wrote: > > >>>>>> lol, sorry, forgot say awd has nolibrary! :) > > >>>>>> you can access the mesh.materialas you please > > > >>>>>> Fabrice > > > >>>>>> On Mar 11, 2010, at 8:49 PM, charglerode wrote: > > > >>>>>>> Fabrice, I took your advice and switched to the AWD format. The > > >>>>>>> materiallibraryis stillnull. I need access to themateriallibrary > > >>>>>>> so that I can swap the bitmapmaterialapplied to a white shading > > >>>>>>> bitmapmaterial. > > > >>>>>>> On Mar 11, 7:33 am, Fabrice3D <[email protected]> wrote: > > >>>>>>>> awd data format runs in all away engines. > > > >>>>>>>> yes AWData parsers are in the f9, f10 and f10 lite trunk > > > >>>>>>>> exporters to awd format are available in F10 branch (no embeds) > > >>>>>>>> and in AwayAir branch (with embeds). > > >>>>>>>> Prefab exports to this format. > > > >>>>>>>>> Never heard of this thing, and its not in the API Refrence. > > > >>>>>>>> doc will be updated... team is kinda super busy atm. > > > >>>>>>>> awd = away data > > >>>>>>>> This is a dedicated format, holds only the data away3d needs. > > > >>>>>>>> the 1.1 version of the format holding a new kind of data will even > > >>>>>>>> make this format the only way to use a new feature > > >>>>>>>> that will be introduced soon. > > > >>>>>>>> Fabrice > > > >>>>>>>> On Mar 11, 2010, at 4:16 PM, Reinorvak wrote: > > > >>>>>>>>> Is this AWData something that was created with Away3D Lite? Never > > >>>>>>>>> heard of this thing, and its not in the API Refrence. Currently > > >>>>>>>>> running Away3D 2.3. > > > >>>>>>>>> If its on the SVN, where can I get access to it? > > > >>>>>>>>> On Mar 11, 9:50 am, Fabrice3D <[email protected]> wrote: > > >>>>>>>>>> its loading fine in Prefab, because I do not use the lib. > > >>>>>>>>>> so why not load as obj in Prefab and export as awd? > > > >>>>>>>>>> only change in your code would be change Obj.load by AWData.load > > > >>>>>>>>>> Fabrice > > > >>>>>>>>>> On Mar 11, 2010, at 3:12 PM, Reinorvak wrote: > > > >>>>>>>>>>> Hmm, fun stuff there. I don't think the OBJ loader actually > > >>>>>>>>>>> creates a > > >>>>>>>>>>> materialLibrary when loading the obj file. Rather it applies the > > >>>>>>>>>>> texture to all faces. So if you want to do it dynamically > > >>>>>>>>>>> you'll have > > >>>>>>>>>>> to go down to the faces each time and change all of their > > >>>>>>>>>>> texture's if > > >>>>>>>>>>> you want to change it. > > > >>>>>>>>>>> Interesting enough, I can load the obj file through prefab just > > >>>>>>>>>>> fine, > > >>>>>>>>>>> and I exported it back out thinking it may have some vodo-magi, > > >>>>>>>>>>> but to > > >>>>>>>>>>> no avail. The model still loads fine but the texture is still > > >>>>>>>>>>> in no > > >>>>>>>>>>> man's land. > > > >>>>>>>>>>> On Mar 10, 6:58 pm, charglerode <[email protected]> wrote: > > >>>>>>>>>>>> Surprisingly, in my case, the texture does show up on the > > >>>>>>>>>>>> model. > > >>>>>>>>>>>> Everything appears to be working absolutely perfectly until I > > >>>>>>>>>>>> try to > > >>>>>>>>>>>> access themateriallibrary. It appears to me that the obj > > >>>>>>>>>>>> loader is > > >>>>>>>>>>>> loading and applying the texture properly, but it doesn't > > >>>>>>>>>>>> place it > > >>>>>>>>>>>> into themateriallibraryfor us to access. Which means, I can't > > >>>>>>>>>>>> replace materials dynamically which is exactly what I'm trying > > >>>>>>>>>>>> to do. > > >>>>>>>>>>>> I've been trying to work around this for the better part of a > > >>>>>>>>>>>> month > > >>>>>>>>>>>> with no luck. > > > >>>>>>>>>>>> On Mar 10, 2:55 pm, Reinorvak <[email protected]> > > >>>>>>>>>>>> wrote: > > > >>>>>>>>>>>>> Hello there, I'm have the same problem I believe. The model > > >>>>>>>>>>>>> can appear > > >>>>>>>>>>>>> on the view and shows up with the basic color materials on > > >>>>>>>>>>>>> it. The > > >>>>>>>>>>>>> modelLibrary isnullwithin the object but otherwise its there. > > > >>>>>>>>>>>>> The accessing ofnullmight be from a different object maybe? > > > >>>>>>>>>>>>> Now I've been banging my head against the wall at this away3D > > >>>>>>>>>>>>> OBJ > > >>>>>>>>>>>>> loader, but to no avail can I figure out why model has no > > >>>>>>>>>>>>> materials. I > > >>>>>>>>>>>>> believe the OBJ loader doesn't actually set up a > > >>>>>>>>>>>>> materialLibrary, but > > >>>>>>>>>>>>> actually just applies thematerialto all faces within the mesh. > > > >>>>>>>>>>>>> I've stepped through everything I could on the away3D side > > >>>>>>>>>>>>> and found > > >>>>>>>>>>>>> that the image is loading correctly, the mtl is loading > > >>>>>>>>>>>>> correctly, and > > >>>>>>>>>>>>> the obj is loading correctly, the texture just fails to make > > >>>>>>>>>>>>> it back > > >>>>>>>>>>>>> to the model on screen. Instead, it assigns it to this > > >>>>>>>>>>>>> container > > >>>>>>>>>>>>> object in the OBJ loader who doesn't belong to anyone. > > > >>>>>>>>>>>>> Not quite sure whats going on here, help us out mates! > > > >>>>>>>>>>>>> Rein > > > >>>>>>>>>>>>> On Mar 9, 12:49 pm, charglerode <[email protected]> wrote: > > > >>>>>>>>>>>>>> I load an OBJ file using the Loader3D, object loads and is > > >>>>>>>>>>>>>> displayed > > >>>>>>>>>>>>>> correctly. However, when I try to access thematerialdata > > >>>>>>>>>>>>>> from the > > >>>>>>>>>>>>>> loaded Object3D it'snull. In fact, any property I try to > > >>>>>>>>>>>>>> trace comes > > >>>>>>>>>>>>>> backnull. Any Ideas?
To unsubscribe from this group, send email to away3d-dev+unsubscribegooglegroups.com or reply to this email with the words "REMOVE ME" as the subject.
