Forum

Missing textures on Jason export

25 March 2017 12:31
Hi everyone,
I hope you can help. I've tried to use the custom archers snippet and created a new project from this. I have replaced the original blend file with my own and placed all textures in the asset folder that was created.

This all works beautifully when I preview it via the project manager but as soon as I build the app and then deploy, I get all the files including the new compressed textures but when I upload the source files and link to the HTML page, I get the screen and functionality but none of the textures display.
I have tried everything I can think of to make it work but no luck.
Can anyone help please, it is so frustrating.
Many thanks for any guidance provided
25 March 2017 23:08
Hi,

The textures are out of reach for some reason. Can you check the output of the console? (F12 when you are in browser). There have to be lots of 404 errors. If so, please provide the console screenshot here.

Does your blend-file really references the textures inside the project folder? All resources placed outside SDK won't work on the actual server.
Blend4Web developer
27 March 2017 12:30
Thanks evgeny for the reply.
I looked at the app in the browser and yes there are a lot of 404 for the textures. I will go back through my textures and make sure I link these to the images in the assets folders.
Hopefully that will solve the issue.
Many thanks
28 March 2017 14:36
Hi Evgeny,
I have gone through all my textures and placed and linked them into the assets folder within the projects folder.
I am still getting no textures and lots of 404 errors.
Also my local preview now seems to not show the textures either.

I am trying to use the custom anchor code snippet and I noticed this bit of code

var APP_ASSETS_PATH = m_cfg.get_assets_path("CSAapp-anchors");

followed by this:-

m_data.load(APP_ASSETS_PATH + "custom_anchors.json", load_cb);

is this where the problem is because this seems to relate to the assets and on the turorial I followed (https://www.youtube.com/watch?v=GtrsMEh5VNI) this didnt seem to be used.

Any thoughts or guidance would be gratefully received
simblen
28 March 2017 14:40
here is a small snapshot of the error code.
I dont know where these strange number png assets are being created as these are not the names I have given them
28 March 2017 19:27
hmmm,
ive managed to make it run on the local preview again and none of the links to my textures are a problem but as soon as I build and deploy this it show a load error.
See attached file for local correct load of assets

Im getting very frustrated with this

kindest regards
simblen
28 March 2017 19:43
H everyone,
Looking at the local and the uploaded console for this file.
Somewhere it is adding in .dds between the file name and the "?v=28032017160938" see below

CSAapp-anchors/assets/close.png.dds?v=28032017160938

If I try the error link and remove the ".ddr" on the web browser it then loads the file correctly, but where is this coming from I have no idea.

Any help appreciated
29 March 2017 10:41
Having something like this "v=28032017160938" at the end of the filename is fine. Blend4Web protects from unnecessary browser resource caching this way.

The application tries to download dds textures because there is the "assets_dds_available" in the app.init method.

You have two options:
1) Remove this flag from the init method.
2) Create dds-textures with the conversion tool. You can read about it here.
Blend4Web developer
29 March 2017 11:57
Morning Evgeny,
I cannot thank you enough, that worked perfectly by switching off the dds_available flag.
This is a great relief and many many …..many thanks
You amazing man
Simblen
29 March 2017 12:17
Glad it helped
Good luck with your project!
Blend4Web developer
 
Please register or log in to leave a reply.