Does anyone have a good ModelMarkerSymbol example with a 3ds model?

3304
10
08-07-2015 04:52 AM
PhilipCollier
New Contributor II

Hi,

I have been trying to use the ModelMarkerSymbol in the new 10.2.6.  So far I have not been able to get anything to display.  This is the link to the model I have been trying,

http://tf3dm.com/3d-model/mq-9-predator-7547.html

Does anyone have a good example of how to use this type of symbol with a 3ds model.  There doesn't seem to be one included in the samples.

Thanks,

Phil.

0 Kudos
10 Replies
AnttiKajanus1
Regular Contributor II

Hi,

I try to write one tomorrow if you still have issues with 3d symbols.

cheers,

Antti

0 Kudos
AnttiKajanus1
Regular Contributor II

Hi,

You should be able to create it more or less like this:

Create renderer with ModelMarkerSymbol

<esri:SimpleRenderer x:Key="RedArrowModelRenderer">   

    <esri:SimpleRenderer.Symbol>

         <esri:ModelMarkerSymbol Scale="1000" SourceUri=".\\Data\\RedArrow.dae"/>

    </esri:SimpleRenderer.Symbol>

    <esri:SimpleRenderer.SceneProperties>

        <esri:RendererSceneProperties HeadingExpression = "[heading]" PitchExpression="[pitch]" RollExpression="[roll]"/>

    </esri:SimpleRenderer.SceneProperties>

</esri:SimpleRenderer>

Then just define your layer to use that renderer.

0 Kudos
PhilipCollier
New Contributor II

Annti,

Thanks for your example.  Unfortunately I am still having issues.  I have applied the renderer to a graphics overlay and tried adding a graphic.  Nothing displays.  I have replaced the modelmarkersymbol for a straight marker symbol and that displays fine.  Both 3ds and dae models have been tried.  I have a feeling its something to do with the path.  Have you tested the above example with success?

Regards

Phil.

0 Kudos
AnttiKajanus1
Regular Contributor II

Just make sure that the path is correct to the dae file. If you include that to the project, make sure that it ends to the bin folder too. If that doesn't help,could you provide me a simple reproducer from your issue?

0 Kudos
PhilipCollier
New Contributor II

Annti,

I will post my example to you when I get home from work, its on my other laptop.

Many thanks,

Phil.

0 Kudos
PhilipCollier
New Contributor II

Annti,

Did you manage to have a look at the example I uploaded?  I have had a little success with some models I downloaded, by ensuring the textures where in the same level as the 3ds file.  Some models, however just do not work regardless.

0 Kudos
AnttiKajanus1
Regular Contributor II

I had finally time to check it today and I can see what you are seeing. I sent it to my colleague that knows more about 3d than I do. Hopefully he can figure it out.

0 Kudos
PhilipCollier
New Contributor II

Excellent, thanks for your assistance.

Phil.

0 Kudos
ApurvaGoyal
New Contributor III

Hello,

My colleague Antti forwarded me your question. To display textures, you need following steps-

1) Create a folder name DHCChipmunk inside Data/Models/Chips3ds (same location where your .3DS file exists).

2) Move all jpegs to DHCChipmunk folder

3) Rename your .3ds file to same name as folder (DHCChipmunk.3ds)

You should now see the textures. The idea is that the JPEGs should reside in a folder named same as the .3ds or .dae file.

Please let me know if you have any questions.

Thanks

Apurva

0 Kudos