Monitoring the libraries and scripts utilized by a website

Whenever I upload my STL files onto the platform known as Thingiverse.com, it automatically generates a preview of my 3D design files. My curiosity lies in discovering which specific libraries this website employs for this purpose. For example, when I examine a particular page like , and delve into its source code, I observe that it utilizes the following scripts:

<script src="/thingiview/js/three.min.js?v=2"></script>
<script src="/thingiview/js/Thingiview.js?v=2"></script>
<script src="/thingiview/js/NormalControls.js?v=2"></script>
<script src="/thingiview/js/Detector.js?v=2"></script>
<script>
        var target_dom_element = $('.thingiview').get(0);

        // parse opts
        var argv = {};
        var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
            argv[key] = value;
        });

        var thingiview = new Thingiview( target_dom_element, 628, 472 );
        if ( parseInt(argv['width']) && parseInt(argv['height']) )
            thingiview.resize( parseInt(argv['width']), parseInt(argv['height']) );

        var animate = function() {
            requestAnimationFrame( animate );
            thingiview.render();
        }
        animate();

        // handle resizes
        window.addEventListener('resize', function() {
            if ( thingiview.fullscreen )
                thingiview.resize(window.innerWidth, 608);
        });

    </script>

Yet, upon clicking on the Thingview feature, I notice a change in the visual perspective of the image along with the disappearance of shadows and lighting effects within the scene. I am specifically intrigued by identifying the script responsible for generating these shadows and lights in the displayed STL file. Is there a method to uncover how Thingiverse produces previews of various design files? I intend to capture snapshots of my designs from identical angles and with matching effects.

Answer №1

three.js is a powerful tool for displaying 3D objects in web browsers, allowing for the direct loading of STL files. An example showcasing this functionality can be found on their github repository here. It is likely that when a file is uploaded, it is passed to three.js for display, with all shadows and visual effects being handled by the library.

Answer №2

The process involves uploading STL files to the cloud for preview creation, but visibility into the current progress is uncertain. Your thoughts on this, @pailhead?

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Adjusting Javascript code to convert numerical values in HTML table cells from thousands to millions

Does anyone know how to create a Javascript function for a web report that converts table values to thousands or millions by dividing or multiplying by 1000? The issue is that each value is clickable, meaning it is wrapped in an anchor tag. Is there a wa ...

Why are my functions still being called asynchronously? I must be missing something

My task involves downloading 5 files exported from our school's database and running a query based on the first export. There will be queries for the other four files, and since there are three schools, my functions need to be scalable. I have two fu ...

Angular Material Design auto-complete textbox with assertive selection

Presently, I am utilizing Angular Material Design and everything is functioning as expected. However, I am now looking to implement autocomplete (Angular Material Design) in a way that forces the user to always choose an option without the ability to manua ...

Using wp_register_script to add multiple JavaScript files in WordPress

I'm trying to include multiple JavaScript files in WordPress using wp_register_script. I know how to add a single file like this: function custom_scripts() { wp_register_script( 'custom-script', get_template_directory_uri() . '/js/ ...

Searching for the perfect jQuery regex to validate date formats

In my application, there is an input box that allows users to enter a string date like "today" or "tomorrow". However, I am facing a new challenge now - dates such as "3 march" or "8 january." The input box includes a dropdown menu feature where users can ...

Exploring network connectivity using Node.js

As someone who is just starting out with the node super framework, I'm curious to find out if there's a library or sub framework in Node.js that allows users to ping a server from the frontend of a web app. Ideally, this tool would provide variou ...

Running Functions Out of Order in JavaScript - An exploration of Asynchronous Execution

I've been working on understanding how to manage the execution order of my script using asynchronous functions and promises. Despite going through numerous resources, I'm still struggling with getting it to work as expected: My approach involves ...

Is there a way to determine when a Telegram web app specifically designed for bots has been shut down?

I have created a Telegram bot that opens a web app, whether through an inline button, keyboard, or link. Once the user completes the tasks in the web app, they can close it using the "close" button instead of any button within the web app that I can track. ...

Do we need to employ strict mode when utilizing specific ES6 functions in Node.js?

There has been a debate circulating at my workplace regarding whether or not it is necessary to include 'use strict' when using ES6 in Node.js without Babel. Some argue that certain ES6 methods may not function correctly without it, but I haven&a ...

The proper method to retrieve the parent function parameter within an inner JavaScript callback function

Consider the code snippet below. var exec = require('child_process').exec; var extraInfo = {'test':1,'passing':'test'}; runWithData(extraInfo); function runWithData(passedData) { exec('/Users/test/Deskto ...

Issues with Tailwind functionality within a monorepo setup

I have set up a monorepo architecture using yarn workspaces, with Tailwind CSS being at the root of the project. I have integrated Tailwind utilities into the styles of one of the workspaces that uses React. While Tailwind is functioning properly in the pr ...

Execution of Javascript code does not provide the expected output when run via VS Code

I've attempted numerous times, but the desired output doesn't appear when I run it through VS Code. However, this code runs smoothly and produces the desired output when executed in Replit's online code editor. Can anyone offer assistance? l ...

Integration of PHP and MySQL with PayPal can be challenging, especially when the PayPal button fails to function unless the amount is

When I initially set the amount value, clicking the "Pay with PayPal" button does not trigger any action. However, if I manually adjust the amount, the PayPal button starts functioning properly. This is how the input field appears: <input name="am ...

faulty lineup in jquery picture switching feature

I've been working on a website that features a jumbotron with images that transition. I've searched online for solutions, but have come up empty. I know the answer is probably simple, but I just can't seem to figure it out right now. The is ...

Retrieving URL from AJAX Request in Express JS

Currently, I am in the process of developing an Express App and encountering a challenge regarding the storage of the user's URL from which their AJAX request originated. In simpler terms, when a website, such as www.example.com, sends an HTTP request ...

What is the best way to merge two tables together using the server-side JQuery Datatable plugin?

I recently came across an amazing example of a server-side ColdFusion jQuery datatable on this website: Check it out here However, I am facing an issue with adding a second table in the lookup. Specifically, while the primary table lists location_id, I al ...

Having trouble navigating through filtering in JavaScript using Node and Express?

After experimenting with different methods, I noticed that when using (age => age.Book === book && age.Chapter === 1) as my filter criteria, everything works perfectly. However, when I try using (age => age.Book === book && age.Chapt ...

conversion of text to number using JavaScript

After pulling values from an XML file using JavaScript, I face the challenge of converting a string to an integer in order to perform calculations. To extract data from the XML file, I use the following snippet: var pop = JSON.stringify(feature.attribute ...

The relationship between Three.js camera and object movement intertwined

As a beginner, I have implemented THREE pointer lock controls and perspective camera for my object. However, when adding both of them to the object, only one gets added based on which one was added first. I'm also facing difficulty in moving the objec ...

form for submitting multiple data via Ajax

I am working with two forms (request and feedback) where I need to use jQuery Ajax to send the data. When a user submits a request, the subject line will display "Request". If they submit feedback, the subject line will display "Feedback". Here is my cur ...