mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-11 00:26:35 +02:00
Merge branch 'master' into fix/domain-threading-defaults
This commit is contained in:
commit
ba67cc8254
242 changed files with 151196 additions and 5769 deletions
|
@ -9,7 +9,7 @@ import java.net.URISyntaxException;
|
|||
|
||||
public class HifiUtils {
|
||||
|
||||
public static final String METAVERSE_BASE_URL = "https://metaverse.highfidelity.com";
|
||||
public static final String METAVERSE_BASE_URL = "https://metaverse.vircadia.com/live";
|
||||
|
||||
private static HifiUtils instance;
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ public class LoginFragment extends Fragment
|
|||
|
||||
private final String OAUTH_CLIENT_ID = BuildConfig.OAUTH_CLIENT_ID;
|
||||
private final String OAUTH_REDIRECT_URI = BuildConfig.OAUTH_REDIRECT_URI;
|
||||
private final String OAUTH_AUTHORIZE_BASE_URL = "https://highfidelity.com/oauth/authorize";
|
||||
private final String OAUTH_AUTHORIZE_BASE_URL = "https://metaverse.vircadia.com/live/oauth/authorize";
|
||||
private static final int OAUTH_AUTHORIZE_REQUEST = 1;
|
||||
|
||||
private EditText mUsername;
|
||||
|
@ -222,7 +222,7 @@ public class LoginFragment extends Fragment
|
|||
}
|
||||
|
||||
private void onForgotPasswordClicked() {
|
||||
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://highfidelity.com/users/password/new"));
|
||||
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://metaverse.vircadia.com/live/users/password/new"));
|
||||
startActivity(intent);
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ import retrofit2.http.Query;
|
|||
|
||||
public class EndpointUsersProvider implements UsersProvider {
|
||||
|
||||
public static final String BASE_URL = "https://metaverse.highfidelity.com/";
|
||||
public static final String BASE_URL = "https://metaverse.vircadia.com/live/";
|
||||
private final Retrofit mRetrofit;
|
||||
private final EndpointUsersProviderService mEndpointUsersProviderService;
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ import retrofit2.http.Query;
|
|||
|
||||
public class UserStoryDomainProvider implements DomainProvider {
|
||||
|
||||
public static final String BASE_URL = "https://metaverse.highfidelity.com/";
|
||||
public static final String BASE_URL = "https://metaverse.vircadia.com/live/";
|
||||
|
||||
private static final String INCLUDE_ACTIONS_FOR_PLACES = "concurrency";
|
||||
private static final String INCLUDE_ACTIONS_FOR_FULL_SEARCH = "concurrency,announcements,snapshot";
|
||||
|
|
|
@ -15,8 +15,8 @@ import io.highfidelity.hifiinterface.HifiUtils;
|
|||
* available in an API
|
||||
*/
|
||||
public class DownloadProfileImageTask extends AsyncTask<String, Void, String> {
|
||||
|
||||
private static final String BASE_PROFILE_URL = "https://highfidelity.com";
|
||||
// Note: This should now be available in the API, correct?
|
||||
private static final String BASE_PROFILE_URL = "https://metaverse.vircadia.com/live";
|
||||
private static final String TAG = "Interface";
|
||||
|
||||
private final DownloadProfileImageResultProcessor mResultProcessor;
|
||||
|
|
|
@ -48,7 +48,7 @@ ext {
|
|||
|
||||
def appDir = new File(projectDir, 'apps/interface')
|
||||
def jniFolder = new File(appDir, 'src/main/jniLibs/arm64-v8a')
|
||||
def baseUrl = 'https://hifi-public.s3.amazonaws.com/dependencies/android/'
|
||||
def baseUrl = 'https://cdn-1.vircadia.com/eu-c-1/vircadia-public/dependencies/android/'
|
||||
def breakpadDumpSymsDir = new File("${appDir}/build/tmp/breakpadDumpSyms")
|
||||
|
||||
task extractGvrBinaries() {
|
||||
|
|
|
@ -11,7 +11,7 @@ buildscript {
|
|||
|
||||
|
||||
def file='gvrsdk_v1.101.0.tgz'
|
||||
def url='https://hifi-public.s3.amazonaws.com/austin/android/' + file
|
||||
def url='https://cdn-1.vircadia.com/eu-c-1/vircadia-public/austin/android/' + file
|
||||
def destFile = new File(HIFI_ANDROID_PRECOMPILED, file)
|
||||
|
||||
// FIXME find a way to only download if the file doesn't exist
|
||||
|
|
|
@ -14,7 +14,10 @@
|
|||
|
||||
#include <queue>
|
||||
|
||||
#if !defined(Q_MOC_RUN)
|
||||
// Work around https://bugreports.qt.io/browse/QTBUG-80990
|
||||
#include <tbb/concurrent_vector.h>
|
||||
#endif
|
||||
|
||||
#include <QtCore/QJsonObject>
|
||||
|
||||
|
|
|
@ -12,7 +12,10 @@
|
|||
#ifndef hifi_AudioMixerSlave_h
|
||||
#define hifi_AudioMixerSlave_h
|
||||
|
||||
#if !defined(Q_MOC_RUN)
|
||||
// Work around https://bugreports.qt.io/browse/QTBUG-80990
|
||||
#include <tbb/concurrent_vector.h>
|
||||
#endif
|
||||
|
||||
#include <AABox.h>
|
||||
#include <AudioHRTF.h>
|
||||
|
|
|
@ -636,6 +636,7 @@ Var Express
|
|||
|
||||
; figure out where to download installer slideshow images from
|
||||
StrCpy $0 "http://cdn.highfidelity.com/installer/slideshow"
|
||||
; Is this in use anymore?
|
||||
|
||||
${If} $CampaignName == ""
|
||||
StrCpy $0 "$0/default"
|
||||
|
|
|
@ -1888,7 +1888,7 @@
|
|||
"name": "provider",
|
||||
"label": "Provider",
|
||||
"help": "OAuth provider URL.",
|
||||
"default": "https://metaverse.highfidelity.com",
|
||||
"default": "https://metaverse.vircadia.com/live",
|
||||
"advanced": true,
|
||||
"backup": false
|
||||
},
|
||||
|
|
|
@ -52,7 +52,7 @@ var URLs = {
|
|||
// STABLE METAVERSE_URL: https://metaverse.highfidelity.com
|
||||
// STAGING METAVERSE_URL: https://staging.highfidelity.com
|
||||
DEFAULT_METAVERSE_URL: "https://metaverse.vircadia.com/live",
|
||||
CDN_URL: 'https://content.vircadia.com/eu-c-1',
|
||||
CDN_URL: 'https://cdn-1.vircadia.com/eu-c-1',
|
||||
PLACE_URL: 'https://xr.place'
|
||||
};
|
||||
|
||||
|
@ -228,7 +228,7 @@ function getDomainFromAPI(callback) {
|
|||
return pendingDomainRequest;
|
||||
}
|
||||
|
||||
function chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAdded) {
|
||||
function chooseFromMetaversePlaces(accessToken, forcePathTo, onSuccessfullyAdded) {
|
||||
if (accessToken) {
|
||||
getMetaverseUrl(function(metaverse_url) {
|
||||
|
||||
|
@ -429,7 +429,7 @@ function chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAd
|
|||
loadingDialog.modal('hide');
|
||||
bootbox.confirm("We were not able to load your domain information from the Metaverse. Would you like to retry?", function(response) {
|
||||
if (response) {
|
||||
chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAdded);
|
||||
chooseFromMetaversePlaces(accessToken, forcePathTo, onSuccessfullyAdded);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
|
@ -387,7 +387,7 @@ $(document).ready(function(){
|
|||
|
||||
$.post("/api/domains", domainJSON, function(data){
|
||||
// we successfully created a domain ID, set it on that field
|
||||
var domainID = data.domain.id;
|
||||
var domainID = data.domain.domainId;
|
||||
console.log("Setting domain id to ", data, domainID);
|
||||
$(Settings.DOMAIN_ID_SELECTOR).val(domainID).change();
|
||||
|
||||
|
@ -853,7 +853,7 @@ $(document).ready(function(){
|
|||
}
|
||||
// Update label
|
||||
if (showOrHideLabel()) {
|
||||
var label = data.domain.label;
|
||||
var label = data.domain.name;
|
||||
label = label === null ? '' : label;
|
||||
$('#network-label').val(label);
|
||||
}
|
||||
|
@ -959,7 +959,7 @@ $(document).ready(function(){
|
|||
var addRow = $("<tr> <td></td> <td></td> <td class='buttons'><a href='#' class='place-add glyphicon glyphicon-plus'></a></td> </tr>");
|
||||
addRow.find(".place-add").click(function(ev) {
|
||||
ev.preventDefault();
|
||||
chooseFromHighFidelityPlaces(Settings.initialValues.metaverse.access_token, null, function(placeName, newDomainID) {
|
||||
chooseFromMetaversePlaces(Settings.initialValues.metaverse.access_token, null, function(placeName, newDomainID) {
|
||||
if (newDomainID) {
|
||||
Settings.data.values.metaverse.id = newDomainID;
|
||||
var domainIDEl = $("[data-keypath='metaverse.id']");
|
||||
|
@ -1002,13 +1002,13 @@ $(document).ready(function(){
|
|||
_.each(data.data.domains, function(domain){
|
||||
var domainString = "";
|
||||
|
||||
if (domain.label) {
|
||||
domainString += '"' + domain.label+ '" - ';
|
||||
if (domain.name) {
|
||||
domainString += '"' + domain.name+ '" - ';
|
||||
}
|
||||
|
||||
domainString += domain.id;
|
||||
domainString += domain.domainId;
|
||||
|
||||
domain_select.append("<option value='" + domain.id + "'>" + domainString + "</option>");
|
||||
domain_select.append("<option value='" + domain.domainId + "'>" + domainString + "</option>");
|
||||
})
|
||||
modal_body += "<label for='domain-name-select'>Domains</label>" + domain_select[0].outerHTML
|
||||
modal_buttons["success"] = {
|
||||
|
|
|
@ -74,7 +74,7 @@ $(document).ready(function(){
|
|||
});
|
||||
|
||||
$('body').on('click', '#change-place-name', function() {
|
||||
chooseFromHighFidelityPlaces(Settings.data.values.metaverse.access_token, "/0,-10,0", function(placeName) {
|
||||
chooseFromMetaversePlaces(Settings.data.values.metaverse.access_token, "/0,-10,0", function(placeName) {
|
||||
updatePlaceNameLink(placeName);
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1196,7 +1196,7 @@ Node::LocalID DomainGatekeeper::findOrCreateLocalID(const QUuid& uuid) {
|
|||
return existingLocalIDIt->second;
|
||||
}
|
||||
|
||||
assert(_localIDs.size() < std::numeric_limits<LocalIDs::value_type>::max() - 2);
|
||||
assert(_localIDs.size() < (size_t)(std::numeric_limits<LocalIDs::value_type>::max() - 2));
|
||||
|
||||
Node::LocalID newLocalID;
|
||||
do {
|
||||
|
|
|
@ -230,7 +230,7 @@ void DomainMetadata::maybeUpdateUsers() {
|
|||
}
|
||||
|
||||
void DomainMetadata::sendDescriptors() {
|
||||
QString domainUpdateJSON = QString("{\"domain\":{\"meta\":%1}").arg(QString(QJsonDocument(get(DESCRIPTORS)).toJson(QJsonDocument::Compact)));
|
||||
QString domainUpdateJSON = QString("{\"domain\":{\"meta\":%1}}").arg(QString(QJsonDocument(get(DESCRIPTORS)).toJson(QJsonDocument::Compact)));
|
||||
const QUuid& domainID = DependencyManager::get<LimitedNodeList>()->getSessionUUID();
|
||||
if (!domainID.isNull()) {
|
||||
static const QString DOMAIN_UPDATE = "/api/v1/domains/%1";
|
||||
|
|
|
@ -10,7 +10,7 @@ import zipfile
|
|||
|
||||
print = functools.partial(print, flush=True)
|
||||
|
||||
ANDROID_PACKAGE_URL = 'https://content.vircadia.com/eu-c-1/vircadia-public/dependencies/android/'
|
||||
ANDROID_PACKAGE_URL = 'https://cdn-1.vircadia.com/eu-c-1/vircadia-public/dependencies/android/'
|
||||
|
||||
ANDROID_PACKAGES = {
|
||||
'qt' : {
|
||||
|
@ -68,7 +68,7 @@ ANDROID_PACKAGES = {
|
|||
'includeLibs': ['libtbb.so', 'libtbbmalloc.so'],
|
||||
},
|
||||
'hifiAC': {
|
||||
'baseUrl': 'https://content.vircadia.com/eu-c-1/vircadia-public/dependencies/',
|
||||
'baseUrl': 'https://cdn-1.vircadia.com/eu-c-1/vircadia-public/dependencies/',
|
||||
'file': 'codecSDK-android_armv8-2.0.zip',
|
||||
'checksum': '1cbef929675818fc64c4101b72f84a6a'
|
||||
},
|
||||
|
|
|
@ -1,861 +1,71 @@
|
|||
{
|
||||
"Anime boy": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
{
|
||||
"properties": {
|
||||
"acceleration": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"actionData": "",
|
||||
"age": 6.915350914001465,
|
||||
"ageAsText": "0 hours 0 minutes 6 seconds",
|
||||
"angularDamping": 0.39346998929977417,
|
||||
"angularVelocity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"animation": {
|
||||
"allowTranslation": true,
|
||||
"currentFrame": 0,
|
||||
"firstFrame": 0,
|
||||
"fps": 30,
|
||||
"hold": false,
|
||||
"lastFrame": 100000,
|
||||
"loop": true,
|
||||
"running": false,
|
||||
"url": ""
|
||||
},
|
||||
"boundingBox": {
|
||||
"brn": {
|
||||
"x": -0.10961885005235672,
|
||||
"y": -0.19444090127944946,
|
||||
"z": -0.15760529041290283
|
||||
},
|
||||
"center": {
|
||||
"x": 2.6226043701171875e-06,
|
||||
"y": -0.13999652862548828,
|
||||
"z": -0.04999971389770508
|
||||
},
|
||||
"dimensions": {
|
||||
"x": 0.21924294531345367,
|
||||
"y": 0.10888873785734177,
|
||||
"z": 0.2152111530303955
|
||||
},
|
||||
"tfl": {
|
||||
"x": 0.10962409526109695,
|
||||
"y": -0.0855521634221077,
|
||||
"z": 0.057605862617492676
|
||||
}
|
||||
},
|
||||
"canCastShadow": true,
|
||||
"certificateID": "",
|
||||
"clientOnly": true,
|
||||
"cloneAvatarEntity": false,
|
||||
"cloneDynamic": false,
|
||||
"cloneLifetime": 300,
|
||||
"cloneLimit": 0,
|
||||
"cloneOriginID": "{00000000-0000-0000-0000-000000000000}",
|
||||
"cloneable": false,
|
||||
"collidesWith": "",
|
||||
"collisionMask": 0,
|
||||
"collisionSoundURL": "",
|
||||
"collisionless": false,
|
||||
"collisionsWillMove": false,
|
||||
"compoundShapeURL": "",
|
||||
"created": "2018-06-06T17:27:53Z",
|
||||
"damping": 0.39346998929977417,
|
||||
"density": 1000,
|
||||
"description": "",
|
||||
"dimensions": {
|
||||
"x": 0.21924294531345367,
|
||||
"y": 0.07768379896879196,
|
||||
"z": 0.2055898904800415
|
||||
},
|
||||
"dynamic": false,
|
||||
"editionNumber": 15,
|
||||
"entityInstanceNumber": 0,
|
||||
"friction": 0.5,
|
||||
"gravity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"href": "",
|
||||
"id": "{5d20c775-a0d7-4163-b158-4e0a784a4625}",
|
||||
"ignoreForCollisions": false,
|
||||
"itemArtist": "jyoum",
|
||||
"itemCategories": "Wearables",
|
||||
"itemDescription": "Wear these, and others will respect your authoritah.",
|
||||
"itemLicense": "",
|
||||
"itemName": "Aviators",
|
||||
"jointRotations": [
|
||||
],
|
||||
"jointRotationsSet": [
|
||||
],
|
||||
"jointTranslations": [
|
||||
],
|
||||
"jointTranslationsSet": [
|
||||
],
|
||||
"lastEdited": 1528306178314655,
|
||||
"lastEditedBy": "{439a2669-4626-487f-9dcf-2d15e77c69a2}",
|
||||
"lifetime": -1,
|
||||
"limitedRun": 4294967295,
|
||||
"localPosition": {
|
||||
"x": 2.6226043701171875e-06,
|
||||
"y": -0.13999652862548828,
|
||||
"z": -0.04999971389770508
|
||||
},
|
||||
"localRotation": {
|
||||
"w": 0.9969173073768616,
|
||||
"x": -0.07845909893512726,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"locked": false,
|
||||
"marketplaceID": "40d879ec-93f0-4b4a-8c58-dd6349bdb058",
|
||||
"modelURL": "http://mpassets.highfidelity.com/40d879ec-93f0-4b4a-8c58-dd6349bdb058-v1/Aviator.fbx",
|
||||
"name": "",
|
||||
"naturalDimensions": {
|
||||
"x": 0.1660931408405304,
|
||||
"y": 0.05885136127471924,
|
||||
"z": 0.15574991703033447
|
||||
},
|
||||
"naturalPosition": {
|
||||
"x": 0,
|
||||
"y": 1.6633577346801758,
|
||||
"z": 0.048884183168411255
|
||||
},
|
||||
"originalTextures": "{\n \"aviator:Eyewear2F\": \"http://mpassets.highfidelity.com/40d879ec-93f0-4b4a-8c58-dd6349bdb058-v1/Aviator.fbx/Aviator.fbm/aviator_Eyewear_Diffuse.png\",\n \"aviator:Eyewear2F1\": \"http://mpassets.highfidelity.com/40d879ec-93f0-4b4a-8c58-dd6349bdb058-v1/Aviator.fbx/Aviator.fbm/aviator_Eyewear_Specular.png\"\n}\n",
|
||||
"owningAvatarID": "{439a2669-4626-487f-9dcf-2d15e77c69a2}",
|
||||
"parentID": "{439a2669-4626-487f-9dcf-2d15e77c69a2}",
|
||||
"parentJointIndex": 66,
|
||||
"position": {
|
||||
"x": 2.6226043701171875e-06,
|
||||
"y": -0.13999652862548828,
|
||||
"z": -0.04999971389770508
|
||||
},
|
||||
"queryAACube": {
|
||||
"scale": 0.9313028454780579,
|
||||
"x": -1.4091639518737793,
|
||||
"y": -10.133878707885742,
|
||||
"z": 1.9983724355697632
|
||||
},
|
||||
"registrationPoint": {
|
||||
"x": 0.5,
|
||||
"y": 0.5,
|
||||
"z": 0.5
|
||||
},
|
||||
"relayParentJoints": false,
|
||||
"renderInfo": {
|
||||
"drawCalls": 1,
|
||||
"hasTransparent": false,
|
||||
"texturesCount": 2,
|
||||
"texturesSize": 1310720,
|
||||
"verticesCount": 982
|
||||
},
|
||||
"restitution": 0.5,
|
||||
"rotation": {
|
||||
"w": 0.9969173073768616,
|
||||
"x": -0.07845909893512726,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"script": "",
|
||||
"scriptTimestamp": 0,
|
||||
"serverScripts": "",
|
||||
"shapeType": "box",
|
||||
"staticCertificateVersion": 0,
|
||||
"textures": "",
|
||||
"type": "Model",
|
||||
"userData": "{\"Attachment\":{\"action\":\"attach\",\"joint\":\"HeadTop_End\",\"attached\":false,\"options\":{\"translation\":{\"x\":0,\"y\":0,\"z\":0},\"scale\":1}},\"grabbableKey\":{\"cloneable\":false,\"grabbable\":true}}",
|
||||
"velocity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"visible": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/46e0fd52-3cff-462f-ba97-927338d88295-v1/AnimeBoy2.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Anime girl": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
{
|
||||
"properties": {
|
||||
"acceleration": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"actionData": "",
|
||||
"age": 19.66267967224121,
|
||||
"ageAsText": "0 hours 0 minutes 19 seconds",
|
||||
"angularDamping": 0.39346998929977417,
|
||||
"angularVelocity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"animation": {
|
||||
"allowTranslation": true,
|
||||
"currentFrame": 0,
|
||||
"firstFrame": 0,
|
||||
"fps": 30,
|
||||
"hold": false,
|
||||
"lastFrame": 100000,
|
||||
"loop": true,
|
||||
"running": false,
|
||||
"url": ""
|
||||
},
|
||||
"boundingBox": {
|
||||
"brn": {
|
||||
"x": -0.10536206513643265,
|
||||
"y": -0.16647332906723022,
|
||||
"z": -0.12632352113723755
|
||||
},
|
||||
"center": {
|
||||
"x": 0,
|
||||
"y": -0.12999999523162842,
|
||||
"z": -0.030000001192092896
|
||||
},
|
||||
"dimensions": {
|
||||
"x": 0.2107241302728653,
|
||||
"y": 0.07294666767120361,
|
||||
"z": 0.1926470398902893
|
||||
},
|
||||
"tfl": {
|
||||
"x": 0.10536206513643265,
|
||||
"y": -0.09352666139602661,
|
||||
"z": 0.06632351875305176
|
||||
}
|
||||
},
|
||||
"canCastShadow": true,
|
||||
"certificateID": "",
|
||||
"clientOnly": true,
|
||||
"cloneAvatarEntity": false,
|
||||
"cloneDynamic": false,
|
||||
"cloneLifetime": 300,
|
||||
"cloneLimit": 0,
|
||||
"cloneOriginID": "{00000000-0000-0000-0000-000000000000}",
|
||||
"cloneable": false,
|
||||
"collidesWith": "",
|
||||
"collisionMask": 0,
|
||||
"collisionSoundURL": "",
|
||||
"collisionless": false,
|
||||
"collisionsWillMove": false,
|
||||
"compoundShapeURL": "",
|
||||
"created": "2018-06-05T00:10:37Z",
|
||||
"damping": 0.39346998929977417,
|
||||
"density": 1000,
|
||||
"description": "",
|
||||
"dimensions": {
|
||||
"x": 0.2107241302728653,
|
||||
"y": 0.07294666767120361,
|
||||
"z": 0.1926470398902893
|
||||
},
|
||||
"dynamic": false,
|
||||
"editionNumber": 5,
|
||||
"entityInstanceNumber": 0,
|
||||
"friction": 0.5,
|
||||
"gravity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"href": "",
|
||||
"id": "{1586b83a-2af7-4532-9bfb-82fe3f5d5ce9}",
|
||||
"ignoreForCollisions": false,
|
||||
"itemArtist": "moam_00",
|
||||
"itemCategories": "Wearables",
|
||||
"itemDescription": "Perfect for side-glancin'.",
|
||||
"itemLicense": "",
|
||||
"itemName": "Blacker Fem Glasses",
|
||||
"jointRotations": [
|
||||
],
|
||||
"jointRotationsSet": [
|
||||
],
|
||||
"jointTranslations": [
|
||||
],
|
||||
"jointTranslationsSet": [
|
||||
],
|
||||
"lastEdited": 1528157470041658,
|
||||
"lastEditedBy": "{425df1a8-289b-42fc-819c-c3b2a12d7165}",
|
||||
"lifetime": -1,
|
||||
"limitedRun": 4294967295,
|
||||
"localPosition": {
|
||||
"x": 0,
|
||||
"y": -0.12999999523162842,
|
||||
"z": -0.029999999329447746
|
||||
},
|
||||
"localRotation": {
|
||||
"w": 1,
|
||||
"x": -2.2351741790771484e-08,
|
||||
"y": 3.4924596548080444e-10,
|
||||
"z": 3.725290298461914e-09
|
||||
},
|
||||
"locked": false,
|
||||
"marketplaceID": "06781d12-9139-48f4-ac2a-417dde090981",
|
||||
"modelURL": "http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx",
|
||||
"name": "Female Glasses 3 by Mario Andrade",
|
||||
"naturalDimensions": {
|
||||
"x": 0.16209548711776733,
|
||||
"y": 0.05611282214522362,
|
||||
"z": 0.14819003641605377
|
||||
},
|
||||
"naturalPosition": {
|
||||
"x": 0,
|
||||
"y": -7.636845111846924e-08,
|
||||
"z": 0
|
||||
},
|
||||
"originalTextures": "{\n \"file49\": \"http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx/FemGlasses03.fbm/FemGlasses03Mat_Mixed_AO.jpg\",\n \"file81\": \"http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx/FemGlasses03.fbm/FemGlasses03Mat_Metallic.jpg\",\n \"file84\": \"http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx/FemGlasses03.fbm/FemGlasses03Mat_Roughness.jpg\",\n \"file86\": \"http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx/FemGlasses03.fbm/FemGlasses03Mat_Base_Color.jpg\",\n \"file87\": \"http://mpassets.highfidelity.com/06781d12-9139-48f4-ac2a-417dde090981-v1/FemGlasses03.fbx/FemGlasses03.fbm/FemGlasses03Mat_Normal_DirectX.jpg\"\n}\n",
|
||||
"owningAvatarID": "{1277f725-fbb4-478b-ae79-1241fd90e508}",
|
||||
"parentID": "{1277f725-fbb4-478b-ae79-1241fd90e508}",
|
||||
"parentJointIndex": 66,
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": -0.12999999523162842,
|
||||
"z": -0.029999999329447746
|
||||
},
|
||||
"queryAACube": {
|
||||
"scale": 0.8840523958206177,
|
||||
"x": -2.6587564945220947,
|
||||
"y": -10.162277221679688,
|
||||
"z": -0.9548344016075134
|
||||
},
|
||||
"registrationPoint": {
|
||||
"x": 0.5,
|
||||
"y": 0.5,
|
||||
"z": 0.5
|
||||
},
|
||||
"relayParentJoints": false,
|
||||
"renderInfo": {
|
||||
"drawCalls": 1,
|
||||
"hasTransparent": false,
|
||||
"texturesCount": 5,
|
||||
"texturesSize": 0,
|
||||
"verticesCount": 1156
|
||||
},
|
||||
"restitution": 0.5,
|
||||
"rotation": {
|
||||
"w": 1,
|
||||
"x": -2.2351741790771484e-08,
|
||||
"y": 3.4924596548080444e-10,
|
||||
"z": 3.725290298461914e-09
|
||||
},
|
||||
"script": "",
|
||||
"scriptTimestamp": 0,
|
||||
"serverScripts": "",
|
||||
"shapeType": "box",
|
||||
"staticCertificateVersion": 0,
|
||||
"textures": "",
|
||||
"type": "Model",
|
||||
"userData": "{\"Attachment\":{\"action\":\"attach\",\"joint\":\"HeadTop_End\",\"attached\":false,\"options\":{\"translation\":{\"x\":0,\"y\":0,\"z\":0},\"scale\":1}},\"grabbableKey\":{\"cloneable\":false,\"grabbable\":true}}",
|
||||
"velocity": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"visible": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/0dce3426-55c8-4641-8dd5-d76eb575b64a-v1/Anime_F_Outfit.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Last Legends: Male": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
{
|
||||
"properties": {
|
||||
"acceleration": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"actionData": "",
|
||||
"age": 321.8835144042969,
|
||||
"ageAsText": "0 hours 5 minutes 21 seconds",
|
||||
"angularDamping": 0.39346998929977417,
|
||||
"angularVelocity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"animation": {
|
||||
"allowTranslation": true,
|
||||
"currentFrame": 0,
|
||||
"firstFrame": 0,
|
||||
"fps": 30,
|
||||
"hold": false,
|
||||
"lastFrame": 100000,
|
||||
"loop": true,
|
||||
"running": false,
|
||||
"url": ""
|
||||
},
|
||||
"boundingBox": {
|
||||
"brn": {
|
||||
"blue": -0.03950843587517738,
|
||||
"green": 0.20785385370254517,
|
||||
"red": -0.04381325840950012,
|
||||
"x": -0.04381325840950012,
|
||||
"y": 0.20785385370254517,
|
||||
"z": -0.03950843587517738
|
||||
},
|
||||
"center": {
|
||||
"blue": 0,
|
||||
"green": 0.23000000417232513,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0.23000000417232513,
|
||||
"z": 0
|
||||
},
|
||||
"dimensions": {
|
||||
"blue": 0.07901687175035477,
|
||||
"green": 0.044292300939559937,
|
||||
"red": 0.08762651681900024,
|
||||
"x": 0.08762651681900024,
|
||||
"y": 0.044292300939559937,
|
||||
"z": 0.07901687175035477
|
||||
},
|
||||
"tfl": {
|
||||
"blue": 0.03950843587517738,
|
||||
"green": 0.2521461546421051,
|
||||
"red": 0.04381325840950012,
|
||||
"x": 0.04381325840950012,
|
||||
"y": 0.2521461546421051,
|
||||
"z": 0.03950843587517738
|
||||
}
|
||||
},
|
||||
"canCastShadow": true,
|
||||
"certificateID": "",
|
||||
"clientOnly": true,
|
||||
"cloneAvatarEntity": false,
|
||||
"cloneDynamic": false,
|
||||
"cloneLifetime": 300,
|
||||
"cloneLimit": 0,
|
||||
"cloneOriginID": "{00000000-0000-0000-0000-000000000000}",
|
||||
"cloneable": false,
|
||||
"collidesWith": "",
|
||||
"collisionMask": 0,
|
||||
"collisionSoundURL": "",
|
||||
"collisionless": false,
|
||||
"collisionsWillMove": false,
|
||||
"compoundShapeURL": "",
|
||||
"created": "2018-07-26T23:56:46Z",
|
||||
"damping": 0.39346998929977417,
|
||||
"density": 1000,
|
||||
"description": "",
|
||||
"dimensions": {
|
||||
"blue": 0.07229919731616974,
|
||||
"green": 0.06644226610660553,
|
||||
"red": 0.03022606298327446,
|
||||
"x": 0.03022606298327446,
|
||||
"y": 0.06644226610660553,
|
||||
"z": 0.07229919731616974
|
||||
},
|
||||
"dynamic": false,
|
||||
"editionNumber": 58,
|
||||
"entityInstanceNumber": 0,
|
||||
"friction": 0.5,
|
||||
"gravity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"href": "",
|
||||
"id": "{03053239-bb37-4c51-a013-a1772baaeed5}",
|
||||
"ignoreForCollisions": false,
|
||||
"itemArtist": "jyoum",
|
||||
"itemCategories": "Wearables",
|
||||
"itemDescription": "A cool scifi watch for your avatar!",
|
||||
"itemLicense": "",
|
||||
"itemName": "Scifi Watch",
|
||||
"jointRotations": [
|
||||
],
|
||||
"jointRotationsSet": [
|
||||
],
|
||||
"jointTranslations": [
|
||||
],
|
||||
"jointTranslationsSet": [
|
||||
],
|
||||
"lastEdited": 1532649569894305,
|
||||
"lastEditedBy": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"lifetime": -1,
|
||||
"limitedRun": 4294967295,
|
||||
"localPosition": {
|
||||
"blue": 0,
|
||||
"green": 0.23000000417232513,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0.23000000417232513,
|
||||
"z": 0
|
||||
},
|
||||
"localRotation": {
|
||||
"w": 0.5910986065864563,
|
||||
"x": -0.48726415634155273,
|
||||
"y": -0.4088630974292755,
|
||||
"z": 0.49599072337150574
|
||||
},
|
||||
"locked": false,
|
||||
"marketplaceID": "0685794d-fddb-4bad-a608-6d7789ceda90",
|
||||
"modelURL": "http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx",
|
||||
"name": "Scifi Watch by Jimi",
|
||||
"naturalDimensions": {
|
||||
"blue": 0.055614765733480453,
|
||||
"green": 0.0511094331741333,
|
||||
"red": 0.023250818252563477,
|
||||
"x": 0.023250818252563477,
|
||||
"y": 0.0511094331741333,
|
||||
"z": 0.055614765733480453
|
||||
},
|
||||
"naturalPosition": {
|
||||
"blue": -0.06031447649002075,
|
||||
"green": 1.4500460624694824,
|
||||
"red": 0.6493338942527771,
|
||||
"x": 0.6493338942527771,
|
||||
"y": 1.4500460624694824,
|
||||
"z": -0.06031447649002075
|
||||
},
|
||||
"originalTextures": "{\n \"file4\": \"http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx/ScifiWatch/texture/lambert1_Base_Color.png\",\n \"file5\": \"http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx/ScifiWatch/texture/lambert1_Normal_OpenGL.png\",\n \"file6\": \"http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx/ScifiWatch/texture/lambert1_Metallic.png\",\n \"file7\": \"http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx/ScifiWatch/texture/lambert1_Roughness.png\",\n \"file8\": \"http://mpassets.highfidelity.com/0685794d-fddb-4bad-a608-6d7789ceda90-v1/ScifiWatch.fbx/ScifiWatch/texture/lambert1_Emissive.png\"\n}\n",
|
||||
"owningAvatarID": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"parentID": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"parentJointIndex": 16,
|
||||
"position": {
|
||||
"blue": 0,
|
||||
"green": 0.23000000417232513,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0.23000000417232513,
|
||||
"z": 0
|
||||
},
|
||||
"queryAACube": {
|
||||
"scale": 0.3082179129123688,
|
||||
"x": 495.7716979980469,
|
||||
"y": 498.345703125,
|
||||
"z": 498.52044677734375
|
||||
},
|
||||
"registrationPoint": {
|
||||
"blue": 0.5,
|
||||
"green": 0.5,
|
||||
"red": 0.5,
|
||||
"x": 0.5,
|
||||
"y": 0.5,
|
||||
"z": 0.5
|
||||
},
|
||||
"relayParentJoints": false,
|
||||
"renderInfo": {
|
||||
"drawCalls": 1,
|
||||
"hasTransparent": false,
|
||||
"texturesCount": 5,
|
||||
"texturesSize": 786432,
|
||||
"verticesCount": 273
|
||||
},
|
||||
"restitution": 0.5,
|
||||
"rotation": {
|
||||
"w": 0.5910986065864563,
|
||||
"x": -0.48726415634155273,
|
||||
"y": -0.4088630974292755,
|
||||
"z": 0.49599072337150574
|
||||
},
|
||||
"script": "",
|
||||
"scriptTimestamp": 0,
|
||||
"serverScripts": "",
|
||||
"shapeType": "box",
|
||||
"staticCertificateVersion": 0,
|
||||
"textures": "",
|
||||
"type": "Model",
|
||||
"userData": "{\"Attachment\":{\"action\":\"attach\",\"joint\":\"[LR]ForeArm\",\"attached\":false,\"options\":{\"translation\":{\"x\":0,\"y\":0,\"z\":0},\"scale\":1}},\"grabbableKey\":{\"cloneable\":false,\"grabbable\":true}}",
|
||||
"velocity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"visible": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"acceleration": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"actionData": "",
|
||||
"age": 308.8044128417969,
|
||||
"ageAsText": "0 hours 5 minutes 8 seconds",
|
||||
"angularDamping": 0.39346998929977417,
|
||||
"angularVelocity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"animation": {
|
||||
"allowTranslation": true,
|
||||
"currentFrame": 0,
|
||||
"firstFrame": 0,
|
||||
"fps": 30,
|
||||
"hold": false,
|
||||
"lastFrame": 100000,
|
||||
"loop": true,
|
||||
"running": false,
|
||||
"url": ""
|
||||
},
|
||||
"boundingBox": {
|
||||
"brn": {
|
||||
"blue": -0.2340194433927536,
|
||||
"green": -0.07067721337080002,
|
||||
"red": -0.17002610862255096,
|
||||
"x": -0.17002610862255096,
|
||||
"y": -0.07067721337080002,
|
||||
"z": -0.2340194433927536
|
||||
},
|
||||
"center": {
|
||||
"blue": -0.039825439453125,
|
||||
"green": 0.02001953125,
|
||||
"red": 0.0001678466796875,
|
||||
"x": 0.0001678466796875,
|
||||
"y": 0.02001953125,
|
||||
"z": -0.039825439453125
|
||||
},
|
||||
"dimensions": {
|
||||
"blue": 0.3883880078792572,
|
||||
"green": 0.18139348924160004,
|
||||
"red": 0.34038791060447693,
|
||||
"x": 0.34038791060447693,
|
||||
"y": 0.18139348924160004,
|
||||
"z": 0.3883880078792572
|
||||
},
|
||||
"tfl": {
|
||||
"blue": 0.1543685644865036,
|
||||
"green": 0.11071627587080002,
|
||||
"red": 0.17036180198192596,
|
||||
"x": 0.17036180198192596,
|
||||
"y": 0.11071627587080002,
|
||||
"z": 0.1543685644865036
|
||||
}
|
||||
},
|
||||
"canCastShadow": true,
|
||||
"certificateID": "",
|
||||
"clientOnly": true,
|
||||
"cloneAvatarEntity": false,
|
||||
"cloneDynamic": false,
|
||||
"cloneLifetime": 300,
|
||||
"cloneLimit": 0,
|
||||
"cloneOriginID": "{00000000-0000-0000-0000-000000000000}",
|
||||
"cloneable": false,
|
||||
"collidesWith": "",
|
||||
"collisionMask": 0,
|
||||
"collisionSoundURL": "",
|
||||
"collisionless": false,
|
||||
"collisionsWillMove": false,
|
||||
"compoundShapeURL": "",
|
||||
"created": "2018-07-26T23:56:46Z",
|
||||
"damping": 0.39346998929977417,
|
||||
"density": 1000,
|
||||
"description": "",
|
||||
"dimensions": {
|
||||
"blue": 0.38838762044906616,
|
||||
"green": 0.16981728374958038,
|
||||
"red": 0.33466479182243347,
|
||||
"x": 0.33466479182243347,
|
||||
"y": 0.16981728374958038,
|
||||
"z": 0.38838762044906616
|
||||
},
|
||||
"dynamic": false,
|
||||
"editionNumber": 18,
|
||||
"entityInstanceNumber": 0,
|
||||
"friction": 0.5,
|
||||
"gravity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"href": "",
|
||||
"id": "{1bf231ce-3913-4c53-be3c-b1f4094dac51}",
|
||||
"ignoreForCollisions": false,
|
||||
"itemArtist": "jyoum",
|
||||
"itemCategories": "Wearables",
|
||||
"itemDescription": "A stylish and classic piece of headwear for your avatar.",
|
||||
"itemLicense": "",
|
||||
"itemName": "Fedora",
|
||||
"jointRotations": [
|
||||
],
|
||||
"jointRotationsSet": [
|
||||
],
|
||||
"jointTranslations": [
|
||||
],
|
||||
"jointTranslationsSet": [
|
||||
],
|
||||
"lastEdited": 1532649698129709,
|
||||
"lastEditedBy": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"lifetime": -1,
|
||||
"limitedRun": 4294967295,
|
||||
"localPosition": {
|
||||
"blue": -0.039825439453125,
|
||||
"green": 0.02001953125,
|
||||
"red": 0.0001678466796875,
|
||||
"x": 0.0001678466796875,
|
||||
"y": 0.02001953125,
|
||||
"z": -0.039825439453125
|
||||
},
|
||||
"localRotation": {
|
||||
"w": 0.9998477101325989,
|
||||
"x": -9.898545982878204e-09,
|
||||
"y": 5.670873406415922e-07,
|
||||
"z": 0.017452405765652657
|
||||
},
|
||||
"locked": false,
|
||||
"marketplaceID": "11c4208d-15d7-4449-9758-a08da6dbd3dc",
|
||||
"modelURL": "http://mpassets.highfidelity.com/11c4208d-15d7-4449-9758-a08da6dbd3dc-v1/Fedora.fbx",
|
||||
"name": "",
|
||||
"naturalDimensions": {
|
||||
"blue": 0.320981502532959,
|
||||
"green": 0.14034485816955566,
|
||||
"red": 0.2765824794769287,
|
||||
"x": 0.2765824794769287,
|
||||
"y": 0.14034485816955566,
|
||||
"z": 0.320981502532959
|
||||
},
|
||||
"naturalPosition": {
|
||||
"blue": 0.022502630949020386,
|
||||
"green": 1.7460365295410156,
|
||||
"red": 0.000143393874168396,
|
||||
"x": 0.000143393874168396,
|
||||
"y": 1.7460365295410156,
|
||||
"z": 0.022502630949020386
|
||||
},
|
||||
"originalTextures": "{\n \"file5\": \"http://mpassets.highfidelity.com/11c4208d-15d7-4449-9758-a08da6dbd3dc-v1/Fedora.fbx/Texture/Fedora_Hat1_Base_Color.png\",\n \"file7\": \"http://mpassets.highfidelity.com/11c4208d-15d7-4449-9758-a08da6dbd3dc-v1/Fedora.fbx/Texture/Fedora_Hat1_Roughness.png\"\n}\n",
|
||||
"owningAvatarID": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"parentID": "{042ac463-7879-40f0-8126-e2e56c4345ca}",
|
||||
"parentJointIndex": 66,
|
||||
"position": {
|
||||
"blue": -0.039825439453125,
|
||||
"green": 0.02001953125,
|
||||
"red": 0.0001678466796875,
|
||||
"x": 0.0001678466796875,
|
||||
"y": 0.02001953125,
|
||||
"z": -0.039825439453125
|
||||
},
|
||||
"queryAACube": {
|
||||
"scale": 1.6202316284179688,
|
||||
"x": 495.21051025390625,
|
||||
"y": 498.5577697753906,
|
||||
"z": 497.6370849609375
|
||||
},
|
||||
"registrationPoint": {
|
||||
"blue": 0.5,
|
||||
"green": 0.5,
|
||||
"red": 0.5,
|
||||
"x": 0.5,
|
||||
"y": 0.5,
|
||||
"z": 0.5
|
||||
},
|
||||
"relayParentJoints": false,
|
||||
"renderInfo": {
|
||||
"drawCalls": 1,
|
||||
"hasTransparent": false,
|
||||
"texturesCount": 2,
|
||||
"texturesSize": 327680,
|
||||
"verticesCount": 719
|
||||
},
|
||||
"restitution": 0.5,
|
||||
"rotation": {
|
||||
"w": 0.9998477101325989,
|
||||
"x": -9.898545982878204e-09,
|
||||
"y": 5.670873406415922e-07,
|
||||
"z": 0.017452405765652657
|
||||
},
|
||||
"script": "",
|
||||
"scriptTimestamp": 0,
|
||||
"serverScripts": "",
|
||||
"shapeType": "box",
|
||||
"staticCertificateVersion": 0,
|
||||
"textures": "",
|
||||
"type": "Model",
|
||||
"userData": "{\"Attachment\":{\"action\":\"attach\",\"joint\":\"HeadTop_End\",\"attached\":false,\"options\":{\"translation\":{\"x\":0,\"y\":0,\"z\":0},\"scale\":1}},\"grabbableKey\":{\"cloneable\":false,\"grabbable\":true}}",
|
||||
"velocity": {
|
||||
"blue": 0,
|
||||
"green": 0,
|
||||
"red": 0,
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
"visible": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/28569047-6f1a-4100-af67-8054ec397cc3-v1/LLMale2.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Last legends Female": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/8d823be5-6197-4418-b984-eb94160ed956-v1/LLFemale_Clothes.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Matthew": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/b652081b-a199-425e-ae5c-7815721bdc09-v1/matthew.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Priscilla": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/e7565f93-8bc5-47c2-b6eb-b3b31d4a1339-v1/priscilla.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Woody": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "http://mpassets.highfidelity.com/ad348528-de38-420c-82bb-054cb22163f5-v1/mannequin.fst",
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Woody/mannequin.fst",
|
||||
"version": 3
|
||||
},
|
||||
"Kim": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Kim/fbx/Kim.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Kim/img/icon.png",
|
||||
"version": 3
|
||||
},
|
||||
"Mason": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Mason/fbx/Mason.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Mason/img/icon.png",
|
||||
"version": 3
|
||||
},
|
||||
"Mike": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Mike/fbx/Mike.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Mike/img/icon.png",
|
||||
"version": 3
|
||||
},
|
||||
"Sean": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Sean/fbx/Sean.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Sean/img/icon.png",
|
||||
"version": 3
|
||||
},
|
||||
"Summer": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Summer/fbx/Summer.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Summer/img/icon.png",
|
||||
"version": 3
|
||||
},
|
||||
"Tanya": {
|
||||
"attachments": [
|
||||
],
|
||||
"avatarEntites": [
|
||||
],
|
||||
"avatarScale": 1,
|
||||
"avatarUrl": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Tanya/fbx/Tanya.fst",
|
||||
"avatarIcon": "https://cdn-1.vircadia.com/us-e-1/Bazaar/Avatars/Tanya/img/icon.png",
|
||||
"version": 3
|
||||
}
|
||||
}
|
||||
}
|
|
@ -8,7 +8,6 @@ WebView {
|
|||
id: webview
|
||||
url: "https://vircadia.com/"
|
||||
profile: FileTypeProfile;
|
||||
|
||||
property var parentRoot: null
|
||||
|
||||
// Create a global EventBridge object for raiseAndLowerKeyboard.
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
//
|
||||
// Created by David Rowe on 16 Dec 2016.
|
||||
// Copyright 2016 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -17,22 +18,31 @@ Item {
|
|||
anchors.fill: parent
|
||||
property string url: ""
|
||||
property string scriptUrl: null
|
||||
property bool useBackground: true
|
||||
|
||||
onUrlChanged: {
|
||||
load(root.url, root.scriptUrl);
|
||||
load(root.url, root.scriptUrl, root.useBackground);
|
||||
}
|
||||
|
||||
onScriptUrlChanged: {
|
||||
if (root.item) {
|
||||
root.item.scriptUrl = root.scriptUrl;
|
||||
} else {
|
||||
load(root.url, root.scriptUrl);
|
||||
load(root.url, root.scriptUrl, root.useBackground);
|
||||
}
|
||||
}
|
||||
|
||||
onUseBackgroundChanged: {
|
||||
if (root.item) {
|
||||
root.item.useBackground = root.useBackground;
|
||||
} else {
|
||||
load(root.url, root.scriptUrl, root.useBackground);
|
||||
}
|
||||
}
|
||||
|
||||
property var item: null
|
||||
|
||||
function load(url, scriptUrl) {
|
||||
function load(url, scriptUrl, useBackground) {
|
||||
// Ensure we reset any existing item to "about:blank" to ensure web audio stops: DEV-2375
|
||||
if (root.item != null) {
|
||||
root.item.url = "about:blank"
|
||||
|
@ -43,11 +53,12 @@ Item {
|
|||
root.item = newItem
|
||||
root.item.url = url
|
||||
root.item.scriptUrl = scriptUrl
|
||||
root.item.useBackground = useBackground
|
||||
})
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
load(root.url, root.scriptUrl);
|
||||
load(root.url, root.scriptUrl, root.useBackground);
|
||||
}
|
||||
|
||||
signal sendToScript(var message);
|
||||
|
|
|
@ -16,6 +16,7 @@ Item {
|
|||
property alias webViewCoreProfile: webViewCore.profile
|
||||
property string webViewCoreUserAgent
|
||||
|
||||
property bool useBackground: webViewCore.useBackground
|
||||
property string userScriptUrl: ""
|
||||
property string urlTag: "noDownload=false";
|
||||
|
||||
|
@ -98,6 +99,7 @@ Item {
|
|||
|
||||
width: parent.width
|
||||
height: parent.height
|
||||
backgroundColor: (flick.useBackground) ? "white" : "transparent"
|
||||
|
||||
profile: HFWebEngineProfile;
|
||||
settings.pluginsEnabled: true
|
||||
|
|
|
@ -14,6 +14,7 @@ Item {
|
|||
property alias webViewCoreProfile: webViewCore.profile
|
||||
property string webViewCoreUserAgent
|
||||
|
||||
property bool useBackground: webViewCore.useBackground
|
||||
property string userScriptUrl: ""
|
||||
property string urlTag: "noDownload=false";
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ Item {
|
|||
property bool passwordField: false
|
||||
property alias flickable: webroot.interactive
|
||||
property alias blurOnCtrlShift: webroot.blurOnCtrlShift
|
||||
property alias useBackground: webroot.useBackground
|
||||
|
||||
function stop() {
|
||||
webroot.stop();
|
||||
|
|
|
@ -49,7 +49,13 @@ ListModel {
|
|||
}
|
||||
|
||||
function makeAvatarObject(avatar, avatarName) {
|
||||
var avatarThumbnailUrl = makeThumbnailUrl(avatar.avatarUrl);
|
||||
var avatarThumbnailUrl;
|
||||
|
||||
if (!avatar.avatarIcon) {
|
||||
avatarThumbnailUrl = makeThumbnailUrl(avatar.avatarUrl);
|
||||
} else {
|
||||
avatarThumbnailUrl = avatar.avatarIcon;
|
||||
}
|
||||
|
||||
return {
|
||||
'name' : avatarName,
|
||||
|
|
|
@ -456,7 +456,7 @@ Rectangle {
|
|||
id: avatarCollisionSoundUrlInputText
|
||||
font.pixelSize: 17
|
||||
Layout.fillWidth: true
|
||||
placeholderText: 'https://hifi-public.s3.amazonaws.com/sounds/Collisions-'
|
||||
placeholderText: "https://cdn-1.vircadia.com/eu-c-1/vircadia-public/sounds/Collisions-"
|
||||
|
||||
onFocusChanged: {
|
||||
keyboardRaised = (avatarAnimationUrlInputText.focus || avatarCollisionSoundUrlInputText.focus);
|
||||
|
|
|
@ -25,7 +25,7 @@ XmlListModel {
|
|||
readonly property string realPrefix: prefix.match('.*/$') ? prefix : (prefix + "/")
|
||||
readonly property string nameRegex: realPrefix + (filter ? (".*" + filter) : "") + ".*\." + extension
|
||||
readonly property string nameQuery: "Key/substring-before(substring-after(string(), '" + prefix + "'), '." + extension + "')"
|
||||
readonly property string baseUrl: "http://s3.amazonaws.com/hifi-public"
|
||||
readonly property string baseUrl: "https://cdn-1.vircadia.com/eu-c-1/vircadia-public"
|
||||
|
||||
// FIXME need to urlencode prefix?
|
||||
source: baseUrl + "?prefix=" + realPrefix
|
||||
|
|
|
@ -296,7 +296,7 @@
|
|||
"lastEdited": 1537901430334966,
|
||||
"lastEditedBy": "{69540019-db48-4375-86c8-ac1a4a90d043}",
|
||||
"locked": true,
|
||||
"modelURL": "http://hifi-content.s3.amazonaws.com/alexia/LoadingScreens/floor.fbx",
|
||||
"modelURL": "https://cdn-1.vircadia.com/eu-c-1/vircadia-content/alexia/LoadingScreens/floor.fbx",
|
||||
"name": "floorModel",
|
||||
"owningAvatarID": "{00000000-0000-0000-0000-000000000000}",
|
||||
"position": {
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -253,6 +253,7 @@
|
|||
#include <DesktopPreviewProvider.h>
|
||||
|
||||
#include "AboutUtil.h"
|
||||
#include "ExternalResource.h"
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
#include <VersionHelpers.h>
|
||||
|
@ -3515,6 +3516,7 @@ void Application::onDesktopRootContextCreated(QQmlContext* surfaceContext) {
|
|||
surfaceContext->setContextProperty("About", AboutUtil::getInstance());
|
||||
surfaceContext->setContextProperty("HiFiAbout", AboutUtil::getInstance()); // Deprecated
|
||||
surfaceContext->setContextProperty("ResourceRequestObserver", DependencyManager::get<ResourceRequestObserver>().data());
|
||||
surfaceContext->setContextProperty("ExternalResource", ExternalResource::getInstance());
|
||||
|
||||
if (auto steamClient = PluginManager::getInstance()->getSteamClientPlugin()) {
|
||||
surfaceContext->setContextProperty("Steam", new SteamScriptingInterface(engine, steamClient.get()));
|
||||
|
@ -3629,6 +3631,8 @@ void Application::setupQmlSurface(QQmlContext* surfaceContext, bool setAdditiona
|
|||
surfaceContext->setContextProperty("WalletScriptingInterface", DependencyManager::get<WalletScriptingInterface>().data());
|
||||
surfaceContext->setContextProperty("ResourceRequestObserver", DependencyManager::get<ResourceRequestObserver>().data());
|
||||
surfaceContext->setContextProperty("PlatformInfo", PlatformInfoScriptingInterface::getInstance());
|
||||
surfaceContext->setContextProperty("ExternalResource", ExternalResource::getInstance());
|
||||
|
||||
// This `module` context property is blank for the QML scripting interface so that we don't get log errors when importing
|
||||
// certain JS files from both scripts (in the JS context) and QML (in the QML context).
|
||||
surfaceContext->setContextProperty("module", "");
|
||||
|
@ -5539,6 +5543,19 @@ void Application::loadSettings() {
|
|||
}
|
||||
|
||||
getMyAvatar()->loadData();
|
||||
|
||||
auto bucketEnum = QMetaEnum::fromType<ExternalResource::Bucket>();
|
||||
auto externalResource = ExternalResource::getInstance();
|
||||
|
||||
for (int i = 0; i < bucketEnum.keyCount(); i++) {
|
||||
const char* keyName = bucketEnum.key(i);
|
||||
QString setting("ExternalResource/");
|
||||
setting += keyName;
|
||||
auto bucket = static_cast<ExternalResource::Bucket>(bucketEnum.keyToValue(keyName));
|
||||
Setting::Handle<QString> url(setting, externalResource->getBase(bucket));
|
||||
externalResource->setBase(bucket, url.get());
|
||||
}
|
||||
|
||||
_settingsLoaded = true;
|
||||
}
|
||||
|
||||
|
@ -5555,6 +5572,22 @@ void Application::saveSettings() const {
|
|||
Menu::getInstance()->saveSettings();
|
||||
getMyAvatar()->saveData();
|
||||
PluginManager::getInstance()->saveSettings();
|
||||
|
||||
// Don't save external resource paths until such time as there's UI to select or set alternatives. Otherwise new default
|
||||
// values won't be used unless Interface.json entries are manually remove or Interface.json is deleted.
|
||||
/*
|
||||
auto bucketEnum = QMetaEnum::fromType<ExternalResource::Bucket>();
|
||||
auto externalResource = ExternalResource::getInstance();
|
||||
|
||||
for (int i = 0; i < bucketEnum.keyCount(); i++) {
|
||||
const char* keyName = bucketEnum.key(i);
|
||||
QString setting("ExternalResource/");
|
||||
setting += keyName;
|
||||
auto bucket = static_cast<ExternalResource::Bucket>(bucketEnum.keyToValue(keyName));
|
||||
Setting::Handle<QString> url(setting, externalResource->getBase(bucket));
|
||||
url.set(externalResource->getBase(bucket));
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
bool Application::importEntities(const QString& urlOrFilename, const bool isObservable, const qint64 callerId) {
|
||||
|
@ -7669,7 +7702,7 @@ bool Application::askToLoadScript(const QString& scriptFilenameOrURL) {
|
|||
|
||||
QUrl scriptURL { scriptFilenameOrURL };
|
||||
|
||||
if (scriptURL.host().endsWith(NetworkingConstants::MARKETPLACE_CDN_HOSTNAME)) {
|
||||
if (scriptURL.host().endsWith(NetworkingConstants::HF_MARKETPLACE_CDN_HOSTNAME)) {
|
||||
int startIndex = shortName.lastIndexOf('/') + 1;
|
||||
int endIndex = shortName.lastIndexOf('?');
|
||||
shortName = shortName.mid(startIndex, endIndex - startIndex);
|
||||
|
@ -7792,7 +7825,7 @@ bool Application::askToReplaceDomainContent(const QString& url) {
|
|||
const int MAX_CHARACTERS_PER_LINE = 90;
|
||||
if (DependencyManager::get<NodeList>()->getThisNodeCanReplaceContent()) {
|
||||
QUrl originURL { url };
|
||||
if (originURL.host().endsWith(NetworkingConstants::MARKETPLACE_CDN_HOSTNAME)) {
|
||||
if (originURL.host().endsWith(NetworkingConstants::HF_MARKETPLACE_CDN_HOSTNAME)) {
|
||||
// Create a confirmation dialog when this call is made
|
||||
static const QString infoText = simpleWordWrap("Your domain's content will be replaced with a new content set. "
|
||||
"If you want to save what you have now, create a backup before proceeding. For more information about backing up "
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Triplelexx on 23/03/17.
|
||||
// Copyright 2017 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -282,12 +283,14 @@ QVariantMap AvatarBookmarks::getAvatarDataToBookmark() {
|
|||
auto myAvatar = DependencyManager::get<AvatarManager>()->getMyAvatar();
|
||||
|
||||
const QString& avatarUrl = myAvatar->getSkeletonModelURL().toString();
|
||||
const QString& avatarIcon = QString("");
|
||||
const QVariant& avatarScale = myAvatar->getAvatarScale();
|
||||
|
||||
// If Avatar attachments ever change, this is where to update them, when saving remember to also append to AVATAR_BOOKMARK_VERSION
|
||||
QVariantMap bookmark;
|
||||
bookmark.insert(ENTRY_VERSION, AVATAR_BOOKMARK_VERSION);
|
||||
bookmark.insert(ENTRY_AVATAR_URL, avatarUrl);
|
||||
bookmark.insert(ENTRY_AVATAR_ICON, avatarIcon);
|
||||
bookmark.insert(ENTRY_AVATAR_SCALE, avatarScale);
|
||||
|
||||
QVariantList wearableEntities;
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Triplelexx on 23/03/17.
|
||||
// Copyright 2017 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -148,6 +149,7 @@ protected slots:
|
|||
private:
|
||||
const QString AVATARBOOKMARKS_FILENAME = "avatarbookmarks.json";
|
||||
const QString ENTRY_AVATAR_URL = "avatarUrl";
|
||||
const QString ENTRY_AVATAR_ICON = "avatarIcon";
|
||||
const QString ENTRY_AVATAR_ATTACHMENTS = "attachments";
|
||||
const QString ENTRY_AVATAR_ENTITIES = "avatarEntites";
|
||||
const QString ENTRY_AVATAR_SCALE = "avatarScale";
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Mark Peng on 8/16/13.
|
||||
// Copyright 2012 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -25,31 +26,33 @@
|
|||
#include <scripting/HMDScriptingInterface.h>
|
||||
#include <AccountManager.h>
|
||||
#include <AddressManager.h>
|
||||
#include <AnimDebugDraw.h>
|
||||
#include <AnimClip.h>
|
||||
#include <AnimInverseKinematics.h>
|
||||
#include <AudioClient.h>
|
||||
#include <ClientTraitsHandler.h>
|
||||
#include <recording/Clip.h>
|
||||
#include <recording/Deck.h>
|
||||
#include <display-plugins/DisplayPlugin.h>
|
||||
#include <recording/Frame.h>
|
||||
#include <FSTReader.h>
|
||||
#include <GeometryUtil.h>
|
||||
#include <GLMHelpers.h>
|
||||
#include <NodeList.h>
|
||||
#include <NetworkingConstants.h>
|
||||
#include <udt/PacketHeaders.h>
|
||||
#include <PathUtils.h>
|
||||
#include <PerfStat.h>
|
||||
#include <SharedUtil.h>
|
||||
#include <SoundCache.h>
|
||||
#include <ModelEntityItem.h>
|
||||
#include <GLMHelpers.h>
|
||||
#include <TextRenderer3D.h>
|
||||
#include <UserActivityLogger.h>
|
||||
#include <AnimDebugDraw.h>
|
||||
#include <AnimClip.h>
|
||||
#include <AnimInverseKinematics.h>
|
||||
#include <recording/Deck.h>
|
||||
#include <recording/Recorder.h>
|
||||
#include <recording/Clip.h>
|
||||
#include <recording/Frame.h>
|
||||
#include <RecordingScriptingInterface.h>
|
||||
#include <RenderableModelEntityItem.h>
|
||||
#include <VariantMapToScriptValue.h>
|
||||
#include <NetworkingConstants.h>
|
||||
|
||||
#include "MyHead.h"
|
||||
#include "MySkeletonModel.h"
|
||||
|
@ -82,7 +85,7 @@ const int SCRIPTED_MOTOR_AVATAR_FRAME = 1;
|
|||
const int SCRIPTED_MOTOR_WORLD_FRAME = 2;
|
||||
const int SCRIPTED_MOTOR_SIMPLE_MODE = 0;
|
||||
const int SCRIPTED_MOTOR_DYNAMIC_MODE = 1;
|
||||
const QString& DEFAULT_AVATAR_COLLISION_SOUND_URL = "https://hifi-public.s3.amazonaws.com/sounds/Collisions-otherorganic/Body_Hits_Impact.wav";
|
||||
const QString& DEFAULT_AVATAR_COLLISION_SOUND_URL = NetworkingConstants::HF_PUBLIC_CDN_URL + "sounds/Collisions-otherorganic/Body_Hits_Impact.wav";
|
||||
|
||||
const float MyAvatar::ZOOM_MIN = 0.5f;
|
||||
const float MyAvatar::ZOOM_MAX = 25.0f;
|
||||
|
|
|
@ -168,6 +168,7 @@ const btCollisionShape* OtherAvatar::createCollisionShape(int32_t jointIndex, bo
|
|||
}
|
||||
// Note: MultiSphereLow case really means: "skip fingers and use spheres for hands,
|
||||
// else fall through to MultiSphereHigh case"
|
||||
/* fall-thru */
|
||||
case BodyLOD::MultiSphereHigh:
|
||||
computeDetailedShapeInfo(shapeInfo, jointIndex);
|
||||
break;
|
||||
|
|
|
@ -18,11 +18,13 @@
|
|||
#include <AccountManager.h>
|
||||
#include <AddressManager.h>
|
||||
#include <DependencyManager.h>
|
||||
#include <NetworkingConstants.h>
|
||||
#include <NodeList.h>
|
||||
#include <UUID.h>
|
||||
|
||||
#include "EntityScriptingInterface.h"
|
||||
#include "ScreenshareScriptingInterface.h"
|
||||
#include "ExternalResource.h"
|
||||
|
||||
static const int SCREENSHARE_INFO_REQUEST_RETRY_TIMEOUT_MS = 300;
|
||||
ScreenshareScriptingInterface::ScreenshareScriptingInterface() {
|
||||
|
@ -128,8 +130,9 @@ static const uint8_t LOCAL_SCREENSHARE_WEB_ENTITY_FPS = 30;
|
|||
// The `z` value here is dynamic.
|
||||
static const glm::vec3 LOCAL_SCREENSHARE_WEB_ENTITY_LOCAL_POSITION(0.0128f, -0.0918f, 0.0f);
|
||||
static const glm::vec3 LOCAL_SCREENSHARE_WEB_ENTITY_DIMENSIONS(3.6790f, 2.0990f, 0.0100f);
|
||||
static const QString LOCAL_SCREENSHARE_WEB_ENTITY_URL =
|
||||
"https://content.highfidelity.com/Experiences/Releases/usefulUtilities/smartBoard/screenshareViewer/screenshareClient.html";
|
||||
static const ExternalResource::Bucket LOCAL_SCREENSHARE_WEB_ENTITY_BUCKET = ExternalResource::Bucket::HF_Content;
|
||||
static const QString LOCAL_SCREENSHARE_WEB_ENTITY_PATH =
|
||||
"Experiences/Releases/usefulUtilities/smartBoard/screenshareViewer/screenshareClient.html";
|
||||
static const QString LOCAL_SCREENSHARE_WEB_ENTITY_HOST_TYPE = "local";
|
||||
void ScreenshareScriptingInterface::startScreenshare(const QUuid& screenshareZoneID,
|
||||
const QUuid& smartboardEntityID,
|
||||
|
@ -281,6 +284,8 @@ void ScreenshareScriptingInterface::handleSuccessfulScreenshareInfoGet(QNetworkR
|
|||
glm::vec3 localPosition(LOCAL_SCREENSHARE_WEB_ENTITY_LOCAL_POSITION);
|
||||
localPosition.z = _localWebEntityZOffset;
|
||||
localScreenshareWebEntityProps.setLocalPosition(localPosition);
|
||||
auto LOCAL_SCREENSHARE_WEB_ENTITY_URL = ExternalResource::getInstance()->getUrl(LOCAL_SCREENSHARE_WEB_ENTITY_BUCKET,
|
||||
LOCAL_SCREENSHARE_WEB_ENTITY_PATH);
|
||||
localScreenshareWebEntityProps.setSourceUrl(LOCAL_SCREENSHARE_WEB_ENTITY_URL);
|
||||
localScreenshareWebEntityProps.setParentID(_smartboardEntityID);
|
||||
localScreenshareWebEntityProps.setDimensions(LOCAL_SCREENSHARE_WEB_ENTITY_DIMENSIONS);
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include <Trace.h>
|
||||
|
||||
#include "Application.h"
|
||||
#include "NetworkingConstants.h"
|
||||
|
||||
Q_LOGGING_CATEGORY(trace_test, "trace.test")
|
||||
|
||||
|
@ -66,8 +67,8 @@ bool TestScriptingInterface::loadTestScene(QString scene) {
|
|||
return result;
|
||||
}
|
||||
|
||||
static const QString TEST_ROOT = "https://raw.githubusercontent.com/highfidelity/hifi_tests/master/";
|
||||
static const QString TEST_BINARY_ROOT = "https://hifi-public.s3.amazonaws.com/test_scene_data/";
|
||||
static const QString TEST_ROOT = "https://raw.githubusercontent.com/hifi-archive/hifi_tests/master/";
|
||||
static const QString TEST_BINARY_ROOT = NetworkingConstants::HF_CONTENT_CDN_URL + "test_scene_data/";
|
||||
static const QString TEST_SCRIPTS_ROOT = TEST_ROOT + "scripts/";
|
||||
static const QString TEST_SCENES_ROOT = TEST_ROOT + "scenes/";
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Clement on 3/17/14.
|
||||
// Copyright 2014 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -32,8 +33,8 @@
|
|||
|
||||
const char* MODEL_TYPE_NAMES[] = { "entities", "heads", "skeletons", "skeletons", "attachments" };
|
||||
|
||||
static const QString S3_URL = "http://s3.amazonaws.com/hifi-public";
|
||||
static const QString PUBLIC_URL = "http://public.highfidelity.io";
|
||||
static const QString S3_URL = NetworkingConstants::HF_PUBLIC_CDN_URL;
|
||||
static const QString PUBLIC_URL = "http://public.vircadia.com"; // Changed to Vircadia but not entirely sure what to do with this yet.
|
||||
static const QString MODELS_LOCATION = "models/";
|
||||
|
||||
static const QString PREFIX_PARAMETER_NAME = "prefix";
|
||||
|
|
|
@ -424,6 +424,7 @@ void OctreeStatsDialog::showOctreeServersOfType(NodeType_t serverType) {
|
|||
extraDetails << "<br/>" << itemInfo.caption << " " << stats.getItemValue(item);
|
||||
}
|
||||
} // fall through... since MOST has all of MORE
|
||||
/* fall-thru */
|
||||
case MORE: {
|
||||
QString totalString = locale.toString((uint)stats.getTotalElements());
|
||||
QString internalString = locale.toString((uint)stats.getTotalInternal());
|
||||
|
|
|
@ -455,7 +455,7 @@ public slots:
|
|||
* @example <caption>Create an image overlay and report whether its image is loaded after 1s.</caption>
|
||||
* var overlay = Overlays.addOverlay("image", {
|
||||
* bounds: { x: 100, y: 100, width: 200, height: 200 },
|
||||
* imageURL: "https://content.highfidelity.com/DomainContent/production/Particles/wispy-smoke.png"
|
||||
* imageURL: "https://content.vircadia.com/eu-c-1/vircadia-assets/interface/default/default_particle.png"
|
||||
* });
|
||||
* Script.setTimeout(function () {
|
||||
* var isLoaded = Overlays.isLoaded(overlay);
|
||||
|
|
|
@ -154,7 +154,6 @@ protected:
|
|||
std::mutex _materialsLock;
|
||||
|
||||
quint64 _created;
|
||||
QUuid _entityID;
|
||||
|
||||
// The base class relies on comparing the model transform to the entity transform in order
|
||||
// to trigger an update, so the member must not be visible to derived classes as a modifiable
|
||||
|
@ -164,6 +163,8 @@ protected:
|
|||
// i.e. to see if the rendering code needs to update because of a change in state of the
|
||||
// entity. This forces all the rendering code itself to be independent of the entity
|
||||
const EntityItemPointer _entity;
|
||||
|
||||
QUuid _entityID;
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
|
|
|
@ -166,7 +166,7 @@ void ParticleEffectEntityRenderer::doRenderUpdateAsynchronousTyped(const TypedEn
|
|||
particleUniforms.rotateWithEntity = _particleProperties.rotateWithEntity ? 1 : 0;
|
||||
});
|
||||
// Update particle uniforms
|
||||
memcpy(&_uniformBuffer.edit<ParticleUniforms>(), &particleUniforms, sizeof(ParticleUniforms));
|
||||
_uniformBuffer.edit<ParticleUniforms>() = particleUniforms;
|
||||
}
|
||||
|
||||
ItemKey ParticleEffectEntityRenderer::getKey() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//
|
||||
// Created by Bradley Austin Davis on 2015/05/12
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -35,6 +36,9 @@ using namespace render::entities;
|
|||
|
||||
const QString WebEntityRenderer::QML = "Web3DSurface.qml";
|
||||
const char* WebEntityRenderer::URL_PROPERTY = "url";
|
||||
const char* WebEntityRenderer::SCRIPT_URL_PROPERTY = "scriptURL";
|
||||
const char* WebEntityRenderer::GLOBAL_POSITION_PROPERTY = "globalPosition";
|
||||
const char* WebEntityRenderer::USE_BACKGROUND_PROPERTY = "useBackground";
|
||||
|
||||
std::function<void(QString, bool, QSharedPointer<OffscreenQmlSurface>&, bool&)> WebEntityRenderer::_acquireWebSurfaceOperator = nullptr;
|
||||
std::function<void(QSharedPointer<OffscreenQmlSurface>&, bool&, std::vector<QMetaObject::Connection>&)> WebEntityRenderer::_releaseWebSurfaceOperator = nullptr;
|
||||
|
@ -100,7 +104,7 @@ WebEntityRenderer::~WebEntityRenderer() {
|
|||
|
||||
bool WebEntityRenderer::isTransparent() const {
|
||||
float fadeRatio = _isFading ? Interpolate::calculateFadeRatio(_fadeStartTime) : 1.0f;
|
||||
return fadeRatio < OPAQUE_ALPHA_THRESHOLD || _alpha < 1.0f || _pulseProperties.getAlphaMode() != PulseMode::NONE;
|
||||
return fadeRatio < OPAQUE_ALPHA_THRESHOLD || _alpha < 1.0f || _pulseProperties.getAlphaMode() != PulseMode::NONE || !_useBackground;
|
||||
}
|
||||
|
||||
bool WebEntityRenderer::needsRenderUpdateFromTypedEntity(const TypedEntityPointer& entity) const {
|
||||
|
@ -193,11 +197,15 @@ void WebEntityRenderer::doRenderUpdateSynchronousTyped(const ScenePointer& scene
|
|||
|
||||
if (_webSurface) {
|
||||
if (_webSurface->getRootItem()) {
|
||||
if (_contentType == ContentType::HtmlContent && _sourceURL != newSourceURL) {
|
||||
if (_contentType == ContentType::HtmlContent && _sourceURL != newSourceURL) {
|
||||
if (localSafeContext) {
|
||||
::hifi::scripting::setLocalAccessSafeThread(true);
|
||||
}
|
||||
_webSurface->getRootItem()->setProperty(URL_PROPERTY, newSourceURL);
|
||||
_webSurface->getRootItem()->setProperty(SCRIPT_URL_PROPERTY, _scriptURL);
|
||||
_webSurface->getRootItem()->setProperty(USE_BACKGROUND_PROPERTY, _useBackground);
|
||||
_webSurface->getSurfaceContext()->setContextProperty(GLOBAL_POSITION_PROPERTY, vec3toVariant(_contextPosition));
|
||||
_webSurface->setMaxFps((QUrl(newSourceURL).host().endsWith("youtube.com", Qt::CaseInsensitive)) ? YOUTUBE_MAX_FPS : _maxFPS);
|
||||
::hifi::scripting::setLocalAccessSafeThread(false);
|
||||
_sourceURL = newSourceURL;
|
||||
} else if (_contentType != ContentType::HtmlContent) {
|
||||
|
@ -207,7 +215,7 @@ void WebEntityRenderer::doRenderUpdateSynchronousTyped(const ScenePointer& scene
|
|||
{
|
||||
auto scriptURL = entity->getScriptURL();
|
||||
if (_scriptURL != scriptURL) {
|
||||
_webSurface->getRootItem()->setProperty("scriptURL", _scriptURL);
|
||||
_webSurface->getRootItem()->setProperty(SCRIPT_URL_PROPERTY, scriptURL);
|
||||
_scriptURL = scriptURL;
|
||||
}
|
||||
}
|
||||
|
@ -226,10 +234,18 @@ void WebEntityRenderer::doRenderUpdateSynchronousTyped(const ScenePointer& scene
|
|||
}
|
||||
}
|
||||
|
||||
{
|
||||
auto useBackground = entity->getUseBackground();
|
||||
if (_useBackground != useBackground) {
|
||||
_webSurface->getRootItem()->setProperty(USE_BACKGROUND_PROPERTY, useBackground);
|
||||
_useBackground = useBackground;
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
auto contextPosition = entity->getWorldPosition();
|
||||
if (_contextPosition != contextPosition) {
|
||||
_webSurface->getSurfaceContext()->setContextProperty("globalPosition", vec3toVariant(contextPosition));
|
||||
_webSurface->getSurfaceContext()->setContextProperty(GLOBAL_POSITION_PROPERTY, vec3toVariant(contextPosition));
|
||||
_contextPosition = contextPosition;
|
||||
}
|
||||
}
|
||||
|
@ -290,12 +306,14 @@ void WebEntityRenderer::doRender(RenderArgs* args) {
|
|||
glm::vec4 color;
|
||||
Transform transform;
|
||||
bool forward;
|
||||
bool transparent;
|
||||
withReadLock([&] {
|
||||
float fadeRatio = _isFading ? Interpolate::calculateFadeRatio(_fadeStartTime) : 1.0f;
|
||||
color = glm::vec4(toGlm(_color), _alpha * fadeRatio);
|
||||
color = EntityRenderer::calculatePulseColor(color, _pulseProperties, _created);
|
||||
transform = _renderTransform;
|
||||
forward = _renderLayer != RenderLayer::WORLD || args->_renderMethod == render::Args::FORWARD;
|
||||
transparent = isTransparent();
|
||||
});
|
||||
|
||||
if (color.a == 0.0f) {
|
||||
|
@ -309,7 +327,7 @@ void WebEntityRenderer::doRender(RenderArgs* args) {
|
|||
|
||||
// Turn off jitter for these entities
|
||||
batch.pushProjectionJitter();
|
||||
DependencyManager::get<GeometryCache>()->bindWebBrowserProgram(batch, color.a < OPAQUE_ALPHA_THRESHOLD, forward);
|
||||
DependencyManager::get<GeometryCache>()->bindWebBrowserProgram(batch, transparent, forward);
|
||||
DependencyManager::get<GeometryCache>()->renderQuad(batch, topLeft, bottomRight, texMin, texMax, color, _geometryId);
|
||||
batch.popProjectionJitter();
|
||||
batch.setResourceTexture(0, nullptr);
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//
|
||||
// Created by Bradley Austin Davis on 2015/05/12
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -32,6 +33,9 @@ public:
|
|||
|
||||
static const QString QML;
|
||||
static const char* URL_PROPERTY;
|
||||
static const char* SCRIPT_URL_PROPERTY;
|
||||
static const char* GLOBAL_POSITION_PROPERTY;
|
||||
static const char* USE_BACKGROUND_PROPERTY;
|
||||
|
||||
static void setAcquireWebSurfaceOperator(std::function<void(const QString&, bool, QSharedPointer<OffscreenQmlSurface>&, bool&)> acquireWebSurfaceOperator) { _acquireWebSurfaceOperator = acquireWebSurfaceOperator; }
|
||||
static void acquireWebSurface(const QString& url, bool htmlContent, QSharedPointer<OffscreenQmlSurface>& webSurface, bool& cachedWebSurface) {
|
||||
|
@ -93,6 +97,7 @@ private:
|
|||
uint16_t _dpi;
|
||||
QString _scriptURL;
|
||||
uint8_t _maxFPS;
|
||||
bool _useBackground;
|
||||
WebInputMode _inputMode;
|
||||
|
||||
glm::vec3 _contextPosition;
|
||||
|
|
|
@ -602,6 +602,7 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const {
|
|||
CHECK_PROPERTY_CHANGE(PROP_MAX_FPS, maxFPS);
|
||||
CHECK_PROPERTY_CHANGE(PROP_INPUT_MODE, inputMode);
|
||||
CHECK_PROPERTY_CHANGE(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, showKeyboardFocusHighlight);
|
||||
CHECK_PROPERTY_CHANGE(PROP_WEB_USE_BACKGROUND, useBackground);
|
||||
|
||||
// Polyline
|
||||
CHECK_PROPERTY_CHANGE(PROP_LINE_POINTS, linePoints);
|
||||
|
@ -1161,7 +1162,7 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const {
|
|||
* speedSpread: 0.01,
|
||||
* emitAcceleration: { x: 0, y: 0.02, z: 0 },
|
||||
* polarFinish: Math.PI,
|
||||
* textures: "https://content.highfidelity.com/DomainContent/production/Particles/wispy-smoke.png",
|
||||
* textures: "https://content.vircadia.com/eu-c-1/vircadia-assets/interface/default/default_particle.png",
|
||||
* particleRadius: 0.1,
|
||||
* color: { red: 0, green: 255, blue: 0 },
|
||||
* alphaFinish: 0,
|
||||
|
@ -1383,6 +1384,9 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const {
|
|||
* @property {WebInputMode} inputMode="touch" - The user input mode to use.
|
||||
* @property {boolean} showKeyboardFocusHighlight=true - <code>true</code> if the entity is highlighted when it has keyboard
|
||||
* focus, <code>false</code> if it isn't.
|
||||
* @property {boolean} useBackground=true - <code>true</code> if the web entity should have a background,
|
||||
* <code>false</code> if the web entity's background should be transparent. The webpage must have CSS properties for transparency set
|
||||
* on the <code>background-color</code> for this property to have an effect.
|
||||
* @example <caption>Create a Web entity displaying at 1920 x 1080 resolution.</caption>
|
||||
* var METERS_TO_INCHES = 39.3701;
|
||||
* var entity = Entities.addEntity({
|
||||
|
@ -1820,6 +1824,7 @@ QScriptValue EntityItemProperties::copyToScriptValue(QScriptEngine* engine, bool
|
|||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_MAX_FPS, maxFPS);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE_GETTER(PROP_INPUT_MODE, inputMode, getInputModeAsString());
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, showKeyboardFocusHighlight);
|
||||
COPY_PROPERTY_TO_QSCRIPTVALUE(PROP_WEB_USE_BACKGROUND, useBackground);
|
||||
}
|
||||
|
||||
// PolyVoxel only
|
||||
|
@ -2201,6 +2206,7 @@ void EntityItemProperties::copyFromScriptValue(const QScriptValue& object, bool
|
|||
COPY_PROPERTY_FROM_QSCRIPTVALUE(maxFPS, uint8_t, setMaxFPS);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE_ENUM(inputMode, InputMode);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(showKeyboardFocusHighlight, bool, setShowKeyboardFocusHighlight);
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(useBackground, bool, setUseBackground);
|
||||
|
||||
// Polyline
|
||||
COPY_PROPERTY_FROM_QSCRIPTVALUE(linePoints, qVectorVec3, setLinePoints);
|
||||
|
@ -2492,6 +2498,7 @@ void EntityItemProperties::merge(const EntityItemProperties& other) {
|
|||
COPY_PROPERTY_IF_CHANGED(maxFPS);
|
||||
COPY_PROPERTY_IF_CHANGED(inputMode);
|
||||
COPY_PROPERTY_IF_CHANGED(showKeyboardFocusHighlight);
|
||||
COPY_PROPERTY_IF_CHANGED(useBackground);
|
||||
|
||||
// Polyline
|
||||
COPY_PROPERTY_IF_CHANGED(linePoints);
|
||||
|
@ -2891,6 +2898,7 @@ bool EntityItemProperties::getPropertyInfo(const QString& propertyName, EntityPr
|
|||
ADD_PROPERTY_TO_MAP(PROP_MAX_FPS, MaxFPS, maxFPS, uint8_t);
|
||||
ADD_PROPERTY_TO_MAP(PROP_INPUT_MODE, InputMode, inputMode, WebInputMode);
|
||||
ADD_PROPERTY_TO_MAP(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, ShowKeyboardFocusHighlight, showKeyboardFocusHighlight, bool);
|
||||
ADD_PROPERTY_TO_MAP(PROP_WEB_USE_BACKGROUND, useBackground, useBackground, bool);
|
||||
|
||||
// Polyline
|
||||
ADD_PROPERTY_TO_MAP(PROP_LINE_POINTS, LinePoints, linePoints, QVector<vec3>);
|
||||
|
@ -3321,6 +3329,7 @@ OctreeElement::AppendState EntityItemProperties::encodeEntityEditPacket(PacketTy
|
|||
APPEND_ENTITY_PROPERTY(PROP_MAX_FPS, properties.getMaxFPS());
|
||||
APPEND_ENTITY_PROPERTY(PROP_INPUT_MODE, (uint32_t)properties.getInputMode());
|
||||
APPEND_ENTITY_PROPERTY(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, properties.getShowKeyboardFocusHighlight());
|
||||
APPEND_ENTITY_PROPERTY(PROP_WEB_USE_BACKGROUND, properties.getUseBackground());
|
||||
}
|
||||
|
||||
if (properties.getType() == EntityTypes::Line) {
|
||||
|
@ -3796,6 +3805,7 @@ bool EntityItemProperties::decodeEntityEditPacket(const unsigned char* data, int
|
|||
READ_ENTITY_PROPERTY_TO_PROPERTIES(PROP_MAX_FPS, uint8_t, setMaxFPS);
|
||||
READ_ENTITY_PROPERTY_TO_PROPERTIES(PROP_INPUT_MODE, WebInputMode, setInputMode);
|
||||
READ_ENTITY_PROPERTY_TO_PROPERTIES(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, bool, setShowKeyboardFocusHighlight);
|
||||
READ_ENTITY_PROPERTY_TO_PROPERTIES(PROP_WEB_USE_BACKGROUND, bool, setUseBackground);
|
||||
}
|
||||
|
||||
if (properties.getType() == EntityTypes::Line) {
|
||||
|
@ -4183,6 +4193,7 @@ void EntityItemProperties::markAllChanged() {
|
|||
_maxFPSChanged = true;
|
||||
_inputModeChanged = true;
|
||||
_showKeyboardFocusHighlightChanged = true;
|
||||
_useBackgroundChanged = true;
|
||||
|
||||
// Polyline
|
||||
_linePointsChanged = true;
|
||||
|
@ -4873,6 +4884,9 @@ QList<QString> EntityItemProperties::listChangedProperties() {
|
|||
if (showKeyboardFocusHighlightChanged()) {
|
||||
out += "showKeyboardFocusHighlight";
|
||||
}
|
||||
if (useBackgroundChanged()) {
|
||||
out += "useBackground";
|
||||
}
|
||||
|
||||
// Shape
|
||||
if (shapeChanged()) {
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Brad Hefta-Gaub on 12/4/13.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -365,6 +366,7 @@ public:
|
|||
DEFINE_PROPERTY_REF(PROP_MAX_FPS, MaxFPS, maxFPS, uint8_t, WebEntityItem::DEFAULT_MAX_FPS);
|
||||
DEFINE_PROPERTY_REF_ENUM(PROP_INPUT_MODE, InputMode, inputMode, WebInputMode, WebInputMode::TOUCH);
|
||||
DEFINE_PROPERTY_REF(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, ShowKeyboardFocusHighlight, showKeyboardFocusHighlight, bool, true);
|
||||
DEFINE_PROPERTY_REF(PROP_WEB_USE_BACKGROUND, UseBackground, useBackground, bool, true);
|
||||
|
||||
// Polyline
|
||||
DEFINE_PROPERTY_REF(PROP_LINE_POINTS, LinePoints, linePoints, QVector<glm::vec3>, ENTITY_ITEM_DEFAULT_EMPTY_VEC3_QVEC);
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Brad Hefta-Gaub on 12/4/13.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -317,6 +318,7 @@ enum EntityPropertyList {
|
|||
PROP_MAX_FPS = PROP_DERIVED_3,
|
||||
PROP_INPUT_MODE = PROP_DERIVED_4,
|
||||
PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT = PROP_DERIVED_5,
|
||||
PROP_WEB_USE_BACKGROUND = PROP_DERIVED_6,
|
||||
|
||||
// Polyline
|
||||
PROP_LINE_POINTS = PROP_DERIVED_0,
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//
|
||||
// Created by Bradley Austin Davis on 2015/05/12
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -16,13 +17,14 @@
|
|||
#include <ByteCountCoding.h>
|
||||
#include <GeometryUtil.h>
|
||||
#include <shared/LocalFileAccessGate.h>
|
||||
#include <NetworkingConstants.h>
|
||||
|
||||
#include "EntitiesLogging.h"
|
||||
#include "EntityItemProperties.h"
|
||||
#include "EntityTree.h"
|
||||
#include "EntityTreeElement.h"
|
||||
|
||||
const QString WebEntityItem::DEFAULT_SOURCE_URL = "http://www.google.com";
|
||||
const QString WebEntityItem::DEFAULT_SOURCE_URL = NetworkingConstants::WEB_ENTITY_DEFAULT_SOURCE_URL;
|
||||
const uint8_t WebEntityItem::DEFAULT_MAX_FPS = 10;
|
||||
|
||||
EntityItemPointer WebEntityItem::factory(const EntityItemID& entityID, const EntityItemProperties& properties) {
|
||||
|
@ -60,6 +62,7 @@ EntityItemProperties WebEntityItem::getProperties(const EntityPropertyFlags& des
|
|||
COPY_ENTITY_PROPERTY_TO_PROPERTIES(maxFPS, getMaxFPS);
|
||||
COPY_ENTITY_PROPERTY_TO_PROPERTIES(inputMode, getInputMode);
|
||||
COPY_ENTITY_PROPERTY_TO_PROPERTIES(showKeyboardFocusHighlight, getShowKeyboardFocusHighlight);
|
||||
COPY_ENTITY_PROPERTY_TO_PROPERTIES(useBackground, getUseBackground);
|
||||
return properties;
|
||||
}
|
||||
|
||||
|
@ -81,6 +84,7 @@ bool WebEntityItem::setSubClassProperties(const EntityItemProperties& properties
|
|||
SET_ENTITY_PROPERTY_FROM_PROPERTIES(maxFPS, setMaxFPS);
|
||||
SET_ENTITY_PROPERTY_FROM_PROPERTIES(inputMode, setInputMode);
|
||||
SET_ENTITY_PROPERTY_FROM_PROPERTIES(showKeyboardFocusHighlight, setShowKeyboardFocusHighlight);
|
||||
SET_ENTITY_PROPERTY_FROM_PROPERTIES(useBackground, setUseBackground);
|
||||
|
||||
return somethingChanged;
|
||||
}
|
||||
|
@ -110,6 +114,7 @@ int WebEntityItem::readEntitySubclassDataFromBuffer(const unsigned char* data, i
|
|||
READ_ENTITY_PROPERTY(PROP_MAX_FPS, uint8_t, setMaxFPS);
|
||||
READ_ENTITY_PROPERTY(PROP_INPUT_MODE, WebInputMode, setInputMode);
|
||||
READ_ENTITY_PROPERTY(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, bool, setShowKeyboardFocusHighlight);
|
||||
READ_ENTITY_PROPERTY(PROP_WEB_USE_BACKGROUND, bool, setUseBackground);
|
||||
|
||||
return bytesRead;
|
||||
}
|
||||
|
@ -127,6 +132,7 @@ EntityPropertyFlags WebEntityItem::getEntityProperties(EncodeBitstreamParams& pa
|
|||
requestedProperties += PROP_MAX_FPS;
|
||||
requestedProperties += PROP_INPUT_MODE;
|
||||
requestedProperties += PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT;
|
||||
requestedProperties += PROP_WEB_USE_BACKGROUND;
|
||||
return requestedProperties;
|
||||
}
|
||||
|
||||
|
@ -153,6 +159,7 @@ void WebEntityItem::appendSubclassData(OctreePacketData* packetData, EncodeBitst
|
|||
APPEND_ENTITY_PROPERTY(PROP_MAX_FPS, getMaxFPS());
|
||||
APPEND_ENTITY_PROPERTY(PROP_INPUT_MODE, (uint32_t)getInputMode());
|
||||
APPEND_ENTITY_PROPERTY(PROP_SHOW_KEYBOARD_FOCUS_HIGHLIGHT, getShowKeyboardFocusHighlight());
|
||||
APPEND_ENTITY_PROPERTY(PROP_WEB_USE_BACKGROUND, getUseBackground());
|
||||
}
|
||||
|
||||
glm::vec3 WebEntityItem::getRaycastDimensions() const {
|
||||
|
@ -295,7 +302,7 @@ void WebEntityItem::setScriptURL(const QString& value) {
|
|||
auto newURL = QUrl::fromUserInput(value);
|
||||
|
||||
if (!newURL.isValid()) {
|
||||
qCDebug(entities) << "Not setting web entity script URL since" << value << "cannot be parsed to a valid URL.";
|
||||
qCDebug(entities) << "Not setting web entity script URL since" << value << "cannot be parsed to a valid URL.";
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -347,6 +354,17 @@ bool WebEntityItem::getShowKeyboardFocusHighlight() const {
|
|||
return _showKeyboardFocusHighlight;
|
||||
}
|
||||
|
||||
void WebEntityItem::setUseBackground(bool value) {
|
||||
withWriteLock([&] {
|
||||
_needsRenderUpdate |= _useBackground != value;
|
||||
_useBackground = value;
|
||||
});
|
||||
}
|
||||
|
||||
bool WebEntityItem::getUseBackground() const {
|
||||
return resultWithReadLock<bool>([&] { return _useBackground; });
|
||||
}
|
||||
|
||||
PulsePropertyGroup WebEntityItem::getPulseProperties() const {
|
||||
return resultWithReadLock<PulsePropertyGroup>([&] {
|
||||
return _pulseProperties;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//
|
||||
// Created by Bradley Austin Davis on 2015/05/12
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -85,6 +86,9 @@ public:
|
|||
|
||||
bool getShowKeyboardFocusHighlight() const;
|
||||
void setShowKeyboardFocusHighlight(bool value);
|
||||
|
||||
bool getUseBackground() const;
|
||||
void setUseBackground(bool value);
|
||||
|
||||
PulsePropertyGroup getPulseProperties() const;
|
||||
|
||||
|
@ -100,6 +104,7 @@ protected:
|
|||
uint8_t _maxFPS;
|
||||
WebInputMode _inputMode;
|
||||
bool _showKeyboardFocusHighlight;
|
||||
bool _useBackground;
|
||||
bool _localSafeContext { false };
|
||||
};
|
||||
|
||||
|
|
|
@ -378,10 +378,10 @@ protected:
|
|||
TransformCamera _cams[2];
|
||||
|
||||
Cameras(){};
|
||||
Cameras(const TransformCamera& cam) { memcpy(_cams, &cam, sizeof(TransformCamera)); };
|
||||
Cameras(const TransformCamera& cam) { _cams[0] = cam; };
|
||||
Cameras(const TransformCamera& camL, const TransformCamera& camR) {
|
||||
memcpy(_cams, &camL, sizeof(TransformCamera));
|
||||
memcpy(_cams + 1, &camR, sizeof(TransformCamera));
|
||||
_cams[0] = camL;
|
||||
_cams[1] = camR;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -331,8 +331,7 @@ void GLBackend::do_setStateBlendFactor(const Batch& batch, size_t paramOffset) {
|
|||
|
||||
void GLBackend::do_setStateScissorRect(const Batch& batch, size_t paramOffset) {
|
||||
Vec4i rect;
|
||||
memcpy(&rect, batch.readData(batch._params[paramOffset]._uint), sizeof(Vec4i));
|
||||
|
||||
memcpy(glm::value_ptr(rect), batch.readData(batch._params[paramOffset]._uint), sizeof(Vec4i));
|
||||
if (_stereo.isStereo()) {
|
||||
rect.z /= 2;
|
||||
if (_stereo._pass) {
|
||||
|
|
|
@ -24,7 +24,7 @@ void GLBackend::do_setViewTransform(const Batch& batch, size_t paramOffset) {
|
|||
}
|
||||
|
||||
void GLBackend::do_setProjectionTransform(const Batch& batch, size_t paramOffset) {
|
||||
memcpy(&_transform._projection, batch.readData(batch._params[paramOffset]._uint), sizeof(Mat4));
|
||||
memcpy(glm::value_ptr(_transform._projection), batch.readData(batch._params[paramOffset]._uint), sizeof(Mat4));
|
||||
_transform._invalidProj = true;
|
||||
}
|
||||
|
||||
|
@ -35,7 +35,7 @@ void GLBackend::do_setProjectionJitter(const Batch& batch, size_t paramOffset) {
|
|||
}
|
||||
|
||||
void GLBackend::do_setViewportTransform(const Batch& batch, size_t paramOffset) {
|
||||
memcpy(&_transform._viewport, batch.readData(batch._params[paramOffset]._uint), sizeof(Vec4i));
|
||||
memcpy(glm::value_ptr(_transform._viewport), batch.readData(batch._params[paramOffset]._uint), sizeof(Vec4i));
|
||||
|
||||
#ifdef GPU_STEREO_DRAWCALL_INSTANCED
|
||||
{
|
||||
|
|
|
@ -440,6 +440,7 @@ QVector<glm::uint32> scriptable::ScriptableMeshPart::getFace(glm::uint32 faceInd
|
|||
if (faceIndex < getNumFaces()) {
|
||||
return getIndices().mid(faceIndex * getTopologyLength(), getTopologyLength());
|
||||
}
|
||||
/* fall-thru */
|
||||
default: return QVector<glm::uint32>();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -99,10 +99,10 @@ public:
|
|||
const size_t offsetHL = hiCoords.x + loCoords.y * _lineStride;
|
||||
const size_t offsetLH = loCoords.x + hiCoords.y * _lineStride;
|
||||
const size_t offsetHH = hiCoords.x + hiCoords.y * _lineStride;
|
||||
assert(offsetLL >= 0 && offsetLL < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetHL >= 0 && offsetHL < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetLH >= 0 && offsetLH < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetHH >= 0 && offsetHH < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetLL < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetHL < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetLH < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
assert(offsetHH < _lineStride * (_dims.y + 2 * EDGE_WIDTH));
|
||||
glm::vec4 colorLL = pixels[offsetLL];
|
||||
glm::vec4 colorHL = pixels[offsetHL];
|
||||
glm::vec4 colorLH = pixels[offsetLH];
|
||||
|
|
|
@ -15,7 +15,12 @@
|
|||
#include <controllers/InputDevice.h>
|
||||
#include "InputPlugin.h"
|
||||
#include <QtGui/qtouchdevice.h>
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(5, 14, 0))
|
||||
#include <QtGui/QList>
|
||||
#else
|
||||
#include <QTouchEvent>
|
||||
#include <QtCore/QList>
|
||||
#endif
|
||||
#include "VirtualPadManager.h"
|
||||
|
||||
class QTouchEvent;
|
||||
|
|
|
@ -223,12 +223,14 @@ public:
|
|||
};
|
||||
|
||||
namespace std {
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(5, 14, 0))
|
||||
template <>
|
||||
struct hash<QByteArray> {
|
||||
size_t operator()(const QByteArray& byteArray) const {
|
||||
return qHash(byteArray);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
||||
template <>
|
||||
struct hash<TextureExtra> {
|
||||
|
|
112
libraries/networking/src/ExternalResource.cpp
Normal file
112
libraries/networking/src/ExternalResource.cpp
Normal file
|
@ -0,0 +1,112 @@
|
|||
//
|
||||
// ExternalResource.h
|
||||
//
|
||||
// Created by Dale Glass on 6 Sep 2020
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Flexible management for external resources (e.g., on S3).
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
||||
#include "ExternalResource.h"
|
||||
#include <QDebug>
|
||||
#include <QLoggingCategory>
|
||||
|
||||
Q_LOGGING_CATEGORY(external_resource, "vircadia.networking.external_resource")
|
||||
|
||||
ExternalResource::ExternalResource(QObject* parent) : QObject(parent) {
|
||||
}
|
||||
|
||||
ExternalResource* ExternalResource::getInstance() {
|
||||
static ExternalResource instance;
|
||||
return &instance;
|
||||
}
|
||||
|
||||
QUrl ExternalResource::getQUrl(Bucket bucket, QString path) {
|
||||
qCDebug(external_resource) << "Requested URL for bucket " << bucket << ", path " << path;
|
||||
|
||||
// Whitespace could interfere with the next step
|
||||
path = path.trimmed();
|
||||
|
||||
// Remove all initial slashes. This is because if QUrl is fed //foo/bar,
|
||||
// it will treat //foo as a domain name. This also ensures the URL is always treated as
|
||||
// relative to any path specified in the bucket.
|
||||
while (path.startsWith('/')) {
|
||||
path = path.remove(0, 1);
|
||||
}
|
||||
|
||||
// De-duplicate URL separators, since S3 doesn't actually have subdirectories, and treats a '/' as a part
|
||||
// of the filename. This means that "/dir/file.txt" and "/dir//file.txt" are not equivalent on S3.
|
||||
//
|
||||
// We feed it through a QUrl to ensure we're only working on the path component.
|
||||
QUrl pathQUrl(path);
|
||||
|
||||
QString tempPath = pathQUrl.path();
|
||||
while (tempPath.contains("//")) {
|
||||
tempPath = tempPath.replace("//", "/");
|
||||
}
|
||||
pathQUrl.setPath(tempPath);
|
||||
|
||||
if (!pathQUrl.isValid()) {
|
||||
qCCritical(external_resource) << "External resource " << pathQUrl << " was requested from bucket " << bucket
|
||||
<< " with an invalid path. Error: " << pathQUrl.errorString();
|
||||
return QUrl();
|
||||
}
|
||||
|
||||
if (!pathQUrl.isRelative()) {
|
||||
qCWarning(external_resource) << "External resource " << pathQUrl << " was requested from bucket " << bucket
|
||||
<< " without using a relative path, returning as-is.";
|
||||
return pathQUrl;
|
||||
}
|
||||
|
||||
QUrl base;
|
||||
{
|
||||
std::lock_guard<std::mutex> guard(_bucketMutex);
|
||||
|
||||
if (!_bucketBases.contains(bucket)) {
|
||||
qCCritical(external_resource) << "External resource " << path << " was requested from unrecognized bucket "
|
||||
<< bucket;
|
||||
return QUrl();
|
||||
}
|
||||
|
||||
base = _bucketBases[bucket];
|
||||
}
|
||||
|
||||
QUrl merged = base.resolved(pathQUrl).adjusted(QUrl::NormalizePathSegments);
|
||||
|
||||
if (merged.isValid()) {
|
||||
qCDebug(external_resource) << "External resource resolved to " << merged;
|
||||
} else {
|
||||
qCCritical(external_resource) << "External resource resolved to invalid URL " << merged << "; Error "
|
||||
<< merged.errorString() << "; base = " << base << "; path = " << path
|
||||
<< "; filtered path = " << pathQUrl;
|
||||
}
|
||||
|
||||
return merged;
|
||||
}
|
||||
|
||||
QString ExternalResource::getBase(Bucket bucket) {
|
||||
std::lock_guard<std::mutex> guard(_bucketMutex);
|
||||
return _bucketBases.value(bucket).toString();
|
||||
};
|
||||
|
||||
bool ExternalResource::setBase(Bucket bucket, const QString& url) {
|
||||
QUrl newURL(url);
|
||||
|
||||
if (!newURL.isValid() || newURL.isRelative()) {
|
||||
qCCritical(external_resource) << "Attempted to set bucket " << bucket << " to invalid URL " << url;
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!_bucketBases.contains(bucket)) {
|
||||
qCritical(external_resource) << "Invalid bucket " << bucket;
|
||||
return false;
|
||||
}
|
||||
|
||||
qCDebug(external_resource) << "Setting base URL for " << bucket << " to " << newURL;
|
||||
|
||||
std::lock_guard<std::mutex> guard(_bucketMutex);
|
||||
_bucketBases[bucket] = newURL;
|
||||
return true;
|
||||
}
|
140
libraries/networking/src/ExternalResource.h
Normal file
140
libraries/networking/src/ExternalResource.h
Normal file
|
@ -0,0 +1,140 @@
|
|||
//
|
||||
// ExternalResource.h
|
||||
//
|
||||
// Created by Dale Glass on 6 Sep 2020
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Flexible management for external resources (e.g., on S3).
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
||||
#ifndef vircadia_ExternalResource_h
|
||||
#define vircadia_ExternalResource_h
|
||||
|
||||
#include <QObject>
|
||||
#include <QUrl>
|
||||
#include <QMap>
|
||||
|
||||
#include <mutex>
|
||||
|
||||
#include "NetworkingConstants.h"
|
||||
|
||||
/**
|
||||
* Flexible management for external resources
|
||||
*
|
||||
* With the death of the original High Fidelity and the transition of the project to a community-managed
|
||||
* one, it became necessary to deal with that the various assets that used to be located under the
|
||||
* highfidelity.com domain, and there won't be a fixed place for them afterwards. Data
|
||||
* hosted by community members may not remain forever, reorganization may be necessary, people may want
|
||||
* to run mirrors, and some might want to run without external Internet access at all.
|
||||
*
|
||||
* This class makes it possible to deal with this in a more flexible manner: rather than hard-coding URLs
|
||||
* all over the codebase, now it's possible to easily change where all those things are downloaded from.
|
||||
*
|
||||
* The term 'bucket' refers to the buckets used on Amazon S3, but there's no requirement for S3 or anything
|
||||
* similar to be used. The term should just be taken as referring to the name of a data set.
|
||||
*/
|
||||
class ExternalResource : public QObject {
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
static ExternalResource* getInstance();
|
||||
~ExternalResource(){};
|
||||
|
||||
/**jsdoc
|
||||
* <p>An external resource bucket.</p>
|
||||
* <p>The original High Fidelity used "Public", "Content", and "MPAssets" Amazon S3 buckets. The intention is that the
|
||||
* community-run versions of these will keep the original data and structure, and any new additions will be made to
|
||||
* Vircadia's "Assets" bucket. This should ease the transition from High Fidelity and ensure a clean separation.</p>
|
||||
* @typedef {object} Script.ResourceBuckets
|
||||
* @property {Script.ResourceBucket} Assets - Vircadia assets.
|
||||
* @property {Script.ResourceBucket} HF_Public - Assets that used to be in High Fidelity's <code>hifi-public</code> Amazon
|
||||
* S3 bucket.
|
||||
* @property {Script.ResourceBucket} HF_Content - Assets that used to be in High Fidelity's <code>hifi-content</code> Amazon
|
||||
* S3 bucket.
|
||||
* @property {Script.ResourceBucket} HF_Marketplace - Assets that used to be in the High Fidelity's <code>mpassets</code>
|
||||
* Amazon S3 bucket. (High Fidelity marketplace.)
|
||||
*/
|
||||
/**jsdoc
|
||||
* <p>An external resource bucket.</p>
|
||||
* <table>
|
||||
* <thead>
|
||||
* <tr><th>Value</th><th>Name</th><th>Description</th>
|
||||
* </thead>
|
||||
* <tbody>
|
||||
* <tr><td><code>0</code></td><td>HF_Public</td><td>Assets that used to be in High Fidelity's <code>hifi-public</code>
|
||||
* Amazon S3 bucket.</td></tr>
|
||||
* <tr><td><code>1</code></td><td>HF_Content</td><td>Assets that used to be in High Fidelity's <code>hifi-content</code>
|
||||
* Amazon S3 bucket.</td></tr>
|
||||
* <tr><td><code>2</code></td><td>HF_Marketplace</td><td>Assets that used to be in the High Fidelity's
|
||||
* <code>mpassets</code> Amazon S3 bucket. (High Fidelity marketplace.)</td></tr>
|
||||
* <tr><td><code>3</code></td><td>Assets</td><td>Vircadia assets.</td></tr>
|
||||
* </tbody>
|
||||
* </table>
|
||||
* @typedef {number} Script.ResourceBucket
|
||||
*/
|
||||
enum class Bucket {
|
||||
HF_Public,
|
||||
HF_Content,
|
||||
HF_Marketplace,
|
||||
Assets
|
||||
};
|
||||
Q_ENUM(Bucket)
|
||||
|
||||
/**
|
||||
* Returns the location of a resource as a QUrl
|
||||
*
|
||||
* Returns the location of the resource \p path in bucket \p bucket
|
||||
*
|
||||
* @note The resulting path will be sanitized by condensing multiple instances of '/' to one.
|
||||
* This is done for easier usage with Amazon S3 and compatible systems.
|
||||
*
|
||||
* @par It will also convert all paths into relative ones respect to the bucket.
|
||||
*
|
||||
* @warning This function should only be given paths with a domain name. If given a complete path,
|
||||
* it will emit a warning into the log and return the unmodified path it was given.
|
||||
*
|
||||
* @param bucket The bucket in which the resource is found
|
||||
* @param relative_path The path of the resource within the bucket
|
||||
* @returns The resulting URL as a QUrl
|
||||
*/
|
||||
QUrl getQUrl(Bucket bucket, QString path);
|
||||
|
||||
QString getUrl(Bucket bucket, QString path) {
|
||||
return ExternalResource::getQUrl(bucket, path).toString();
|
||||
};
|
||||
|
||||
/**
|
||||
* Returns the base path for a bucket
|
||||
*
|
||||
* @param bucket Bucket whose path to return
|
||||
*/
|
||||
QString getBase(Bucket bucket);
|
||||
|
||||
/**
|
||||
* Sets the base path for a bucket
|
||||
*
|
||||
* The \p url parameter will be validated, and the action will not be performed
|
||||
* if the URL isn't a valid one, or if the bucket wasn't valid.
|
||||
*
|
||||
* @param bucket Bucket whose path to set
|
||||
* @param url Base URL for the bucket.
|
||||
* @returns Whether the base was set.
|
||||
*/
|
||||
bool setBase(Bucket bucket, const QString& url);
|
||||
|
||||
private:
|
||||
ExternalResource(QObject* parent = nullptr);
|
||||
|
||||
std::mutex _bucketMutex;
|
||||
|
||||
QMap<Bucket, QUrl> _bucketBases {
|
||||
{ Bucket::HF_Public, QUrl(NetworkingConstants::HF_PUBLIC_CDN_URL) },
|
||||
{ Bucket::HF_Content, QUrl(NetworkingConstants::HF_CONTENT_CDN_URL) },
|
||||
{ Bucket::HF_Marketplace, QUrl(NetworkingConstants::HF_MPASSETS_CDN_URL) },
|
||||
{ Bucket::Assets, QUrl(NetworkingConstants::VIRCADIA_CONTENT_CDN_URL) }
|
||||
};
|
||||
};
|
||||
|
||||
#endif
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Stephen Birarda on 2/15/13.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -37,6 +38,7 @@
|
|||
#include <SharedUtil.h>
|
||||
|
||||
#include "DomainHandler.h"
|
||||
#include "NetworkingConstants.h"
|
||||
#include "Node.h"
|
||||
#include "NLPacket.h"
|
||||
#include "NLPacketList.h"
|
||||
|
@ -55,8 +57,8 @@ static const size_t DEFAULT_MAX_CONNECTION_RATE { std::numeric_limits<size_t>::m
|
|||
|
||||
const char DEFAULT_ASSIGNMENT_SERVER_HOSTNAME[] = "localhost";
|
||||
|
||||
const char STUN_SERVER_HOSTNAME[] = "stun.highfidelity.io";
|
||||
const unsigned short STUN_SERVER_PORT = 3478;
|
||||
const char STUN_SERVER_HOSTNAME[] = "stun1.l.google.com";
|
||||
const unsigned short STUN_SERVER_PORT = NetworkingConstants::STUN_SERVER_DEFAULT_PORT;
|
||||
|
||||
const QString DOMAIN_SERVER_LOCAL_PORT_SMEM_KEY = "domain-server.local-port";
|
||||
const QString DOMAIN_SERVER_LOCAL_HTTP_PORT_SMEM_KEY = "domain-server.local-http-port";
|
||||
|
|
|
@ -31,8 +31,8 @@ namespace NetworkingConstants {
|
|||
const QUrl METAVERSE_SERVER_URL_STAGING { "https://metaverse.vircadia.com/live" };
|
||||
|
||||
// Web Engine requests to this parent domain have an account authorization header added
|
||||
const QString AUTH_HOSTNAME_BASE = "highfidelity.com";
|
||||
const QStringList IS_AUTHABLE_HOSTNAME = { "highfidelity.com", "highfidelity.io" };
|
||||
const QString AUTH_HOSTNAME_BASE = "vircadia.com";
|
||||
const QStringList IS_AUTHABLE_HOSTNAME = { "vircadia.com", "vircadia.io" };
|
||||
|
||||
// Use a custom User-Agent to avoid ModSecurity filtering, e.g. by hosting providers.
|
||||
const QByteArray VIRCADIA_USER_AGENT = "Mozilla/5.0 (VircadiaInterface)";
|
||||
|
@ -43,15 +43,30 @@ namespace NetworkingConstants {
|
|||
|
||||
const QUrl BUILDS_XML_URL("https://highfidelity.com/builds.xml");
|
||||
const QUrl MASTER_BUILDS_XML_URL("https://highfidelity.com/dev-builds.xml");
|
||||
|
||||
// WebEntity Defaults
|
||||
const QString WEB_ENTITY_DEFAULT_SOURCE_URL = "https://vircadia.com/";
|
||||
|
||||
const QString DEFAULT_AVATAR_COLLISION_SOUND_URL = "https://hifi-public.s3.amazonaws.com/sounds/Collisions-otherorganic/Body_Hits_Impact.wav";
|
||||
|
||||
// CDN URLs
|
||||
const QString HF_CONTENT_CDN_URL = "https://cdn-1.vircadia.com/eu-c-1/vircadia-content/";
|
||||
const QString HF_MPASSETS_CDN_URL = "https://cdn-1.vircadia.com/eu-c-1/vircadia-mpassets/";
|
||||
const QString HF_PUBLIC_CDN_URL = "https://cdn-1.vircadia.com/eu-c-1/vircadia-public/";
|
||||
const QString HF_MARKETPLACE_CDN_HOSTNAME = "mpassets.highfidelity.com";
|
||||
const QString VIRCADIA_CONTENT_CDN_URL = "https://cdn-1.vircadia.com/us-e-1/";
|
||||
|
||||
// For now we only have one ice server.
|
||||
#if USE_STABLE_GLOBAL_SERVICES
|
||||
const QString ICE_SERVER_DEFAULT_HOSTNAME = "ice.vircadia.com";
|
||||
|
||||
const QString STUN_SERVER_DEFAULT_HOSTNAME = "stun1.l.google.com";
|
||||
const unsigned short STUN_SERVER_DEFAULT_PORT = 19302;
|
||||
#else
|
||||
const QString ICE_SERVER_DEFAULT_HOSTNAME = "ice.vircadia.com";
|
||||
#endif
|
||||
|
||||
const QString MARKETPLACE_CDN_HOSTNAME = "mpassets.highfidelity.com";
|
||||
const QString STUN_SERVER_DEFAULT_HOSTNAME = "stun2.l.google.com";
|
||||
const unsigned short STUN_SERVER_DEFAULT_PORT = 19302;
|
||||
#endif
|
||||
|
||||
const QUrl HELP_DOCS_URL { "https://docs.vircadia.dev" };
|
||||
const QUrl HELP_FORUM_URL { "https://forums.vircadia.dev" };
|
||||
|
|
|
@ -358,7 +358,7 @@ public:
|
|||
* // Replace AnimationCache with MaterialCache, ModelCache, SoundCache, or TextureCache as appropriate.
|
||||
* // TextureCache has its own version of this function.
|
||||
*
|
||||
* var resourceURL = "https://s3-us-west-1.amazonaws.com/hifi-content/clement/production/animations/sitting_idle.fbx";
|
||||
* var resourceURL = "https://cdn-1.vircadia.com/eu-c-1/vircadia-public/clement/production/animations/sitting_idle.fbx";
|
||||
* var resourceObject = AnimationCache.prefetch(resourceURL);
|
||||
*
|
||||
* function checkIfResourceLoaded(state) {
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
//
|
||||
// Created by Stephen Birarda on 4/8/13.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
// Copyright 2020 Vircadia contributors.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
@ -281,6 +282,7 @@ enum class EntityVersion : PacketVersion {
|
|||
ScreenshareZone,
|
||||
ZoneOcclusion,
|
||||
ModelBlendshapes,
|
||||
TransparentWeb,
|
||||
|
||||
// Add new versions above here
|
||||
NUM_PACKET_TYPE,
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
#include "OctreeLogging.h"
|
||||
#include "NumericalConstants.h"
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
|
||||
bool OctreePacketData::_debug = false;
|
||||
AtomicUIntStat OctreePacketData::_totalBytesOfOctalCodes { 0 };
|
||||
|
@ -702,17 +703,17 @@ void OctreePacketData::debugBytes() {
|
|||
}
|
||||
|
||||
int OctreePacketData::unpackDataFromBytes(const unsigned char* dataBytes, glm::vec2& result) {
|
||||
memcpy(&result, dataBytes, sizeof(result));
|
||||
memcpy(glm::value_ptr(result), dataBytes, sizeof(result));
|
||||
return sizeof(result);
|
||||
}
|
||||
|
||||
int OctreePacketData::unpackDataFromBytes(const unsigned char* dataBytes, glm::vec3& result) {
|
||||
memcpy(&result, dataBytes, sizeof(result));
|
||||
memcpy(glm::value_ptr(result), dataBytes, sizeof(result));
|
||||
return sizeof(result);
|
||||
}
|
||||
|
||||
int OctreePacketData::unpackDataFromBytes(const unsigned char* dataBytes, glm::u8vec3& result) {
|
||||
memcpy(&result, dataBytes, sizeof(result));
|
||||
memcpy(glm::value_ptr(result), dataBytes, sizeof(result));
|
||||
return sizeof(result);
|
||||
}
|
||||
|
||||
|
@ -743,7 +744,12 @@ int OctreePacketData::unpackDataFromBytes(const unsigned char *dataBytes, QVecto
|
|||
memcpy(&length, dataBytes, sizeof(uint16_t));
|
||||
dataBytes += sizeof(length);
|
||||
result.resize(length);
|
||||
memcpy(result.data(), dataBytes, length * sizeof(glm::vec3));
|
||||
|
||||
for(int i=0;i<length;i++) {
|
||||
memcpy(glm::value_ptr(result[i]), dataBytes, sizeof(glm::vec3));
|
||||
dataBytes += sizeof(glm::vec3);
|
||||
}
|
||||
|
||||
return sizeof(uint16_t) + length * sizeof(glm::vec3);
|
||||
}
|
||||
|
||||
|
|
|
@ -691,6 +691,7 @@ void RenderPipelines::updateMultiMaterial(graphics::MultiMaterial& multiMaterial
|
|||
break;
|
||||
case graphics::Material::CULL_FACE_MODE:
|
||||
multiMaterial.setCullFaceMode(graphics::Material::DEFAULT_CULL_FACE_MODE);
|
||||
break;
|
||||
case graphics::MaterialKey::ALBEDO_MAP_BIT:
|
||||
if (schemaKey.isAlbedoMap()) {
|
||||
drawMaterialTextures->setTexture(gr::Texture::MaterialAlbedo, textureCache->getWhiteTexture());
|
||||
|
|
|
@ -169,7 +169,7 @@ protected:
|
|||
* audio file.
|
||||
* @returns {AudioInjector} The audio injector that plays the audio file.
|
||||
* @example <caption>Play a sound.</caption>
|
||||
* var sound = SoundCache.getSound("http://hifi-content.s3.amazonaws.com/ken/samples/forest_ambiX.wav");
|
||||
* var sound = SoundCache.getSound("https://cdn-1.vircadia.com/us-c-1/ken/samples/forest_ambiX.wav");
|
||||
*
|
||||
* function playSound() {
|
||||
* var injectorOptions = {
|
||||
|
|
|
@ -108,6 +108,8 @@ int functionSignatureMetaID = qRegisterMetaType<QScriptEngine::FunctionSignature
|
|||
|
||||
int scriptEnginePointerMetaID = qRegisterMetaType<ScriptEnginePointer>();
|
||||
|
||||
Q_DECLARE_METATYPE(ExternalResource::Bucket);
|
||||
|
||||
static QScriptValue debugPrint(QScriptContext* context, QScriptEngine* engine) {
|
||||
QString message = "";
|
||||
for (int i = 0; i < context->argumentCount(); i++) {
|
||||
|
@ -663,6 +665,14 @@ void avatarDataFromScriptValue(const QScriptValue& object, ScriptAvatarData*& ou
|
|||
out = nullptr;
|
||||
}
|
||||
|
||||
QScriptValue externalResourceBucketToScriptValue(QScriptEngine* engine, ExternalResource::Bucket const& in) {
|
||||
return QScriptValue((int)in);
|
||||
}
|
||||
|
||||
void externalResourceBucketFromScriptValue(const QScriptValue& object, ExternalResource::Bucket& out) {
|
||||
out = static_cast<ExternalResource::Bucket>(object.toInt32());
|
||||
}
|
||||
|
||||
void ScriptEngine::resetModuleCache(bool deleteScriptCache) {
|
||||
if (QThread::currentThread() != thread()) {
|
||||
executeOnScriptThread([=]() { resetModuleCache(deleteScriptCache); });
|
||||
|
@ -770,6 +780,9 @@ void ScriptEngine::init() {
|
|||
resetModuleCache();
|
||||
}
|
||||
|
||||
qScriptRegisterMetaType(this, externalResourceBucketToScriptValue, externalResourceBucketFromScriptValue);
|
||||
registerEnum("Script.ExternalPaths", QMetaEnum::fromType<ExternalResource::Bucket>());
|
||||
|
||||
registerGlobalObject("Audio", DependencyManager::get<AudioScriptingInterface>().data());
|
||||
|
||||
registerGlobalObject("Midi", DependencyManager::get<Midi>().data());
|
||||
|
@ -827,6 +840,19 @@ void ScriptEngine::init() {
|
|||
}));
|
||||
}
|
||||
|
||||
void ScriptEngine::registerEnum(const QString& enumName, QMetaEnum newEnum) {
|
||||
if (!newEnum.isValid()) {
|
||||
qCCritical(scriptengine) << "registerEnum called on invalid enum with name " << enumName;
|
||||
return;
|
||||
}
|
||||
|
||||
for (int i = 0; i < newEnum.keyCount(); i++) {
|
||||
const char* keyName = newEnum.key(i);
|
||||
QString fullName = enumName + "." + keyName;
|
||||
registerValue(fullName, newEnum.keyToValue(keyName));
|
||||
}
|
||||
}
|
||||
|
||||
void ScriptEngine::registerValue(const QString& valueName, QScriptValue value) {
|
||||
if (QThread::currentThread() != thread()) {
|
||||
#ifdef THREAD_DEBUGGING
|
||||
|
@ -2856,3 +2882,7 @@ void ScriptEngine::callEntityScriptMethod(const EntityItemID& entityID, const QS
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
QString ScriptEngine::getExternalPath(ExternalResource::Bucket bucket, const QString& path) {
|
||||
return ExternalResource::getInstance()->getUrl(bucket, path);
|
||||
}
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
#include <QtCore/QSet>
|
||||
#include <QtCore/QWaitCondition>
|
||||
#include <QtCore/QStringList>
|
||||
#include <QMap>
|
||||
#include <QMetaEnum>
|
||||
|
||||
#include <QtScript/QScriptEngine>
|
||||
|
||||
|
@ -37,6 +39,7 @@
|
|||
#include "AssetScriptingInterface.h"
|
||||
#include "AudioScriptingInterface.h"
|
||||
#include "BaseScriptEngine.h"
|
||||
#include "ExternalResource.h"
|
||||
#include "Quat.h"
|
||||
#include "Mat4.h"
|
||||
#include "ScriptCache.h"
|
||||
|
@ -118,6 +121,7 @@ public:
|
|||
* <li><code>"agent"</code>: An assignment client script.</li>
|
||||
* </ul>
|
||||
* <em>Read-only.</em>
|
||||
* @property {Script.ResourceBuckets} ExternalPaths - External resource buckets.
|
||||
*/
|
||||
class ScriptEngine : public BaseScriptEngine, public EntitiesScriptEngineProvider {
|
||||
Q_OBJECT
|
||||
|
@ -230,6 +234,17 @@ public:
|
|||
Q_INVOKABLE void registerFunction(const QString& parent, const QString& name, QScriptEngine::FunctionSignature fun,
|
||||
int numArguments = -1);
|
||||
|
||||
/**jsdoc
|
||||
* @function Script.registerEnum
|
||||
* @param {string} name - Name.
|
||||
* @param {object} enum - Enum.
|
||||
* @deprecated This function is deprecated and will be removed.
|
||||
*/
|
||||
// WARNING: This function must be called after a registerGlobalObject that creates the namespace this enum is located in, or
|
||||
// the globalObject won't function. E.g., if you have a Foo object and a Foo.FooType enum, Foo must be registered first.
|
||||
/// registers a global enum
|
||||
Q_INVOKABLE void registerEnum(const QString& enumName, QMetaEnum newEnum);
|
||||
|
||||
/**jsdoc
|
||||
* @function Script.registerValue
|
||||
* @param {string} name - Name.
|
||||
|
@ -670,6 +685,23 @@ public:
|
|||
|
||||
void setScriptEngines(QSharedPointer<ScriptEngines>& scriptEngines) { _scriptEngines = scriptEngines; }
|
||||
|
||||
/**jsdoc
|
||||
* Gets the URL for an asset in an external resource bucket. (The location where the bucket is hosted may change over time
|
||||
* but this method will return the asset's current URL.)
|
||||
* @function Script.getExternalPath
|
||||
* @param {Script.ResourceBucket} bucket - The external resource bucket that the asset is in.
|
||||
* @param {string} path - The path within the external resource bucket where the asset is located.
|
||||
* <p>Normally, this should start with a path or filename to be appended to the bucket URL.
|
||||
* Alternatively, it can be a relative path starting with <code>./</code> or <code>../</code>, to navigate within the
|
||||
* resource bucket's URL.</p>
|
||||
* @Returns {string} The URL of an external asset.
|
||||
* @example <caption>Report the URL of a default particle.</caption>
|
||||
* print(Script.getExternalPath(Script.ExternalPaths.Assets, "Bazaar/Assets/Textures/Defaults/Interface/default_particle.png"));
|
||||
* @example <caption>Report the root directory where the Vircadia assets are located.</caption>
|
||||
* print(Script.getExternalPath(Script.ExternalPaths.Assets, "."));
|
||||
*/
|
||||
Q_INVOKABLE QString getExternalPath(ExternalResource::Bucket bucket, const QString& path);
|
||||
|
||||
public slots:
|
||||
|
||||
/**jsdoc
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "GLMHelpers.h"
|
||||
#include "ByteCountCoding.h"
|
||||
#include "PropertyFlags.h"
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
|
||||
class BufferParser {
|
||||
public:
|
||||
|
@ -98,7 +99,10 @@ template<>
|
|||
inline void BufferParser::readValue(QVector<glm::vec3>& result) {
|
||||
uint16_t length; readValue(length);
|
||||
result.resize(length);
|
||||
memcpy(result.data(), _data + _offset, sizeof(glm::vec3) * length);
|
||||
for (int i=0; i<length; i++) {
|
||||
memcpy(glm::value_ptr(result[i]), _data + _offset + (sizeof(glm::vec3)*i), sizeof(glm::vec3) * length);
|
||||
}
|
||||
|
||||
_offset += sizeof(glm::vec3) * length;
|
||||
}
|
||||
|
||||
|
|
|
@ -620,7 +620,9 @@ void PolygonClip::clipToScreen(const glm::vec2* inputVertexArray, int inLength,
|
|||
glm::vec2* tempVertexArrayB = new glm::vec2[maxLength];
|
||||
|
||||
// set up our temporary arrays
|
||||
memcpy(tempVertexArrayA, inputVertexArray, sizeof(glm::vec2) * inLength);
|
||||
for (int i=0; i<inLength; i++) {
|
||||
tempVertexArrayA[i] = inputVertexArray[i];
|
||||
}
|
||||
|
||||
// Left edge
|
||||
LineSegment2 edge;
|
||||
|
|
|
@ -597,12 +597,14 @@ namespace std {
|
|||
}
|
||||
};
|
||||
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(5, 14, 0))
|
||||
template <>
|
||||
struct hash<QString> {
|
||||
size_t operator()(const QString& a) const {
|
||||
return qHash(a);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
}
|
||||
|
||||
/**jsdoc
|
||||
|
|
|
@ -15,12 +15,15 @@
|
|||
#pragma warning( disable : 4334 )
|
||||
#endif
|
||||
|
||||
#if !defined(Q_MOC_RUN)
|
||||
// Work around https://bugreports.qt.io/browse/QTBUG-80990
|
||||
#include <tbb/concurrent_queue.h>
|
||||
#include <tbb/concurrent_unordered_map.h>
|
||||
#include <tbb/concurrent_unordered_set.h>
|
||||
#include <tbb/concurrent_vector.h>
|
||||
#include <tbb/parallel_for.h>
|
||||
#include <tbb/blocked_range2d.h>
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#pragma warning( pop )
|
||||
|
|
|
@ -153,13 +153,13 @@ void packBlendshapeOffsets_AVX2(float (*unpacked)[9], uint32_t (*packed)[4], int
|
|||
__m256 s7 = _mm256_setzero_ps();
|
||||
|
||||
switch (rem) {
|
||||
case 7: s6 = _mm256_loadu_ps(unpacked[i+6]);
|
||||
case 6: s5 = _mm256_loadu_ps(unpacked[i+5]);
|
||||
case 5: s4 = _mm256_loadu_ps(unpacked[i+4]);
|
||||
case 4: s3 = _mm256_loadu_ps(unpacked[i+3]);
|
||||
case 3: s2 = _mm256_loadu_ps(unpacked[i+2]);
|
||||
case 2: s1 = _mm256_loadu_ps(unpacked[i+1]);
|
||||
case 1: s0 = _mm256_loadu_ps(unpacked[i+0]);
|
||||
case 7: s6 = _mm256_loadu_ps(unpacked[i+6]); /* fall-thru */
|
||||
case 6: s5 = _mm256_loadu_ps(unpacked[i+5]); /* fall-thru */
|
||||
case 5: s4 = _mm256_loadu_ps(unpacked[i+4]); /* fall-thru */
|
||||
case 4: s3 = _mm256_loadu_ps(unpacked[i+3]); /* fall-thru */
|
||||
case 3: s2 = _mm256_loadu_ps(unpacked[i+2]); /* fall-thru */
|
||||
case 2: s1 = _mm256_loadu_ps(unpacked[i+1]); /* fall-thru */
|
||||
case 1: s0 = _mm256_loadu_ps(unpacked[i+0]); /* fall-thru */
|
||||
}
|
||||
|
||||
__m256 t0 = _mm256_unpacklo_ps(s0, s1);
|
||||
|
@ -269,13 +269,13 @@ void packBlendshapeOffsets_AVX2(float (*unpacked)[9], uint32_t (*packed)[4], int
|
|||
|
||||
// store pack x 8
|
||||
switch (rem) {
|
||||
case 7: _mm_storeu_si128((__m128i*)packed[i+6], _mm256_extractf128_si256(v2, 1));
|
||||
case 6: _mm_storeu_si128((__m128i*)packed[i+5], _mm256_extractf128_si256(v1, 1));
|
||||
case 5: _mm_storeu_si128((__m128i*)packed[i+4], _mm256_extractf128_si256(v0, 1));
|
||||
case 4: _mm_storeu_si128((__m128i*)packed[i+3], _mm256_castsi256_si128(v3));
|
||||
case 3: _mm_storeu_si128((__m128i*)packed[i+2], _mm256_castsi256_si128(v2));
|
||||
case 2: _mm_storeu_si128((__m128i*)packed[i+1], _mm256_castsi256_si128(v1));
|
||||
case 1: _mm_storeu_si128((__m128i*)packed[i+0], _mm256_castsi256_si128(v0));
|
||||
case 7: _mm_storeu_si128((__m128i*)packed[i+6], _mm256_extractf128_si256(v2, 1)); /* fall-thru */
|
||||
case 6: _mm_storeu_si128((__m128i*)packed[i+5], _mm256_extractf128_si256(v1, 1)); /* fall-thru */
|
||||
case 5: _mm_storeu_si128((__m128i*)packed[i+4], _mm256_extractf128_si256(v0, 1)); /* fall-thru */
|
||||
case 4: _mm_storeu_si128((__m128i*)packed[i+3], _mm256_castsi256_si128(v3)); /* fall-thru */
|
||||
case 3: _mm_storeu_si128((__m128i*)packed[i+2], _mm256_castsi256_si128(v2)); /* fall-thru */
|
||||
case 2: _mm_storeu_si128((__m128i*)packed[i+1], _mm256_castsi256_si128(v1)); /* fall-thru */
|
||||
case 1: _mm_storeu_si128((__m128i*)packed[i+0], _mm256_castsi256_si128(v0)); /* fall-thru */
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
|
||||
#include "../NumericalConstants.h"
|
||||
#include "../ViewFrustum.h"
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
|
||||
void ConicalViewFrustum::set(const ViewFrustum& viewFrustum) {
|
||||
// The ConicalViewFrustum has two parts: a central sphere (same as ViewFrustum) and a circular cone that bounds the frustum part.
|
||||
|
@ -131,9 +132,9 @@ int ConicalViewFrustum::serialize(unsigned char* destinationBuffer) const {
|
|||
int ConicalViewFrustum::deserialize(const unsigned char* sourceBuffer) {
|
||||
const unsigned char* startPosition = sourceBuffer;
|
||||
|
||||
memcpy(&_position, sourceBuffer, sizeof(_position));
|
||||
memcpy(glm::value_ptr(_position), sourceBuffer, sizeof(_position));
|
||||
sourceBuffer += sizeof(_position);
|
||||
memcpy(&_direction, sourceBuffer, sizeof(_direction));
|
||||
memcpy(glm::value_ptr(_direction), sourceBuffer, sizeof(_direction));
|
||||
sourceBuffer += sizeof(_direction);
|
||||
sourceBuffer += unpackFloatAngleFromTwoByte((uint16_t*)sourceBuffer, &_angle);
|
||||
sourceBuffer += unpackClipValueFromTwoByte(sourceBuffer, _farClip);
|
||||
|
|
|
@ -7,7 +7,7 @@ logfile_maxbytes=0
|
|||
pidfile=/var/run/supervisord.pid
|
||||
|
||||
[program:domain-server]
|
||||
command=/opt/vircadia/domain-server
|
||||
command=/opt/vircadia/domain-server --get-temp-name
|
||||
autorestart=unexpected
|
||||
directory=/opt/vircadia
|
||||
|
||||
|
|
|
@ -105,7 +105,7 @@ private:
|
|||
static QVariantMap zipNonZeroValues(const QStringList& keys, const QVector<float>& values) {
|
||||
QVariantMap out;
|
||||
for (int i=1; i < values.size(); i++) {
|
||||
if (fabs(values[i]) > 1.0e-6) {
|
||||
if (fabs(values[i]) > 1.0e-6f) {
|
||||
out[keys.value(i)] = values[i];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# Screen Sharing within High Fidelity
|
||||
This Screen Share app, built using Electron, allows for easy desktop screen sharing when used in conjuction with various scripts in the `hifi-content` repository.
|
||||
This Screen Share app, built using Electron, allows for easy desktop screen sharing when used in conjuction with various scripts in the `vircadia-content` repository.
|
||||
|
||||
# Screen Sharing Source Files
|
||||
## `packager.js`
|
||||
|
|
|
@ -9,8 +9,6 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
// Set the following variables to the right value
|
||||
var NUM_AC = 3; // This is the number of AC. Their ID need to be unique and between 0 (included) and NUM_AC (excluded)
|
||||
var NAMES = new Array("Craig", "Clement", "Jeff"); // ACs names ordered by IDs (Default name is "ACx", x = ID + 1))
|
||||
|
@ -35,7 +33,7 @@ var LOAD = 6;
|
|||
|
||||
|
||||
var windowDimensions = Controller.getViewportDimensions();
|
||||
var TOOL_ICON_URL = HIFI_PUBLIC_BUCKET + "images/tools/";
|
||||
var TOOL_ICON_URL = Script.getExternalPath(Script.ExternalPaths.Assets, "images/tools/");
|
||||
var ALPHA_ON = 1.0;
|
||||
var ALPHA_OFF = 0.7;
|
||||
var COLOR_TOOL_BAR = { red: 0, green: 0, blue: 0 };
|
||||
|
|
|
@ -20,8 +20,7 @@
|
|||
//
|
||||
|
||||
//For procedural walk animation
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
Script.include(HIFI_PUBLIC_BUCKET + "scripts/acScripts/proceduralAnimationAPI.js");
|
||||
Script.include(Script.getExternalPath(Script.ExternalPaths.Assets, "scripts/acScripts/proceduralAnimationAPI.js");
|
||||
|
||||
var procAnimAPI = new ProcAnimAPI();
|
||||
|
||||
|
@ -121,9 +120,9 @@ var newBodyFilePrefix = "bot" + botNumber;
|
|||
|
||||
// set the face model fst using the bot number
|
||||
// there is no need to change the body model - we're using the default
|
||||
Avatar.faceModelURL = HIFI_PUBLIC_BUCKET + "meshes/" + newFaceFilePrefix + ".fst";
|
||||
Avatar.skeletonModelURL = HIFI_PUBLIC_BUCKET + "meshes/" + newBodyFilePrefix + "_a.fst";
|
||||
Avatar.billboardURL = HIFI_PUBLIC_BUCKET + "meshes/billboards/bot" + botNumber + ".png";
|
||||
Avatar.faceModelURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/" + newFaceFilePrefix + ".fst");
|
||||
Avatar.skeletonModelURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/" + newBodyFilePrefix + "_a.fst");
|
||||
Avatar.billboardURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/billboards/bot" + botNumber + ".png");
|
||||
|
||||
Agent.isAvatar = true;
|
||||
Agent.isListeningToAudioStream = true;
|
||||
|
@ -146,9 +145,9 @@ function loadSounds() {
|
|||
var footstep_filenames = ["FootstepW2Left-12db.wav", "FootstepW2Right-12db.wav", "FootstepW3Left-12db.wav", "FootstepW3Right-12db.wav",
|
||||
"FootstepW5Left-12db.wav", "FootstepW5Right-12db.wav"];
|
||||
|
||||
var SOUND_BASE_URL = HIFI_PUBLIC_BUCKET + "sounds/Cocktail+Party+Snippets/Raws/";
|
||||
var SOUND_BASE_URL = Script.getExternalPath(Script.ExternalPaths.Assets, "sounds/Cocktail+Party+Snippets/Raws/");
|
||||
|
||||
var FOOTSTEP_BASE_URL = HIFI_PUBLIC_BUCKET + "sounds/Footsteps/";
|
||||
var FOOTSTEP_BASE_URL = Script.getExternalPath(Script.ExternalPaths.Assets, "sounds/Footsteps/");
|
||||
|
||||
for (var i = 0; i < sound_filenames.length; i++) {
|
||||
sounds.push(SoundCache.getSound(SOUND_BASE_URL + sound_filenames[i]));
|
||||
|
|
|
@ -12,8 +12,6 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
function getRandomFloat(min, max) {
|
||||
return Math.random() * (max - min) + min;
|
||||
}
|
||||
|
@ -44,9 +42,9 @@ newBodyFilePrefix = "bot" + botNumber;
|
|||
|
||||
// set the face model fst using the bot number
|
||||
// there is no need to change the body model - we're using the default
|
||||
Avatar.faceModelURL = HIFI_PUBLIC_BUCKET + "meshes/" + newFaceFilePrefix + ".fst";
|
||||
Avatar.skeletonModelURL = HIFI_PUBLIC_BUCKET + "meshes/" + newBodyFilePrefix + ".fst";
|
||||
Avatar.billboardURL = HIFI_PUBLIC_BUCKET + "meshes/billboards/bot" + botNumber + ".png";
|
||||
Avatar.faceModelURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/" + newFaceFilePrefix + ".fst");
|
||||
Avatar.skeletonModelURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/" + newBodyFilePrefix + ".fst");
|
||||
Avatar.billboardURL = Script.getExternalPath(Script.ExternalPaths.Assets, "meshes/billboards/bot" + botNumber + ".png");
|
||||
|
||||
Agent.isAvatar = true;
|
||||
Agent.isListeningToAudioStream = true;
|
||||
|
|
|
@ -10,15 +10,13 @@
|
|||
//
|
||||
Script.include("./AgentPoolController.js");
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var masterController = new MasterController();
|
||||
|
||||
var input_text = null;
|
||||
|
||||
// Script. DO NOT MODIFY BEYOND THIS LINE.
|
||||
//Script.include("../libraries/toolBars.js");
|
||||
Script.include(HIFI_PUBLIC_BUCKET + "scripts/libraries/toolBars.js");
|
||||
Script.include(Script.getExternalPath(Script.ExternalPaths.Assets, "scripts/libraries/toolBars.js"));
|
||||
// We want small icons
|
||||
Tool.IMAGE_HEIGHT /= 2;
|
||||
Tool.IMAGE_WIDTH /= 2;
|
||||
|
@ -29,7 +27,7 @@ var STOP = 3;
|
|||
var LOAD = 6;
|
||||
|
||||
var windowDimensions = Controller.getViewportDimensions();
|
||||
var TOOL_ICON_URL = HIFI_PUBLIC_BUCKET + "images/tools/";
|
||||
var TOOL_ICON_URL = Script.getExternalPath(Script.ExternalPaths.Assets, "images/tools/");
|
||||
var ALPHA_ON = 1.0;
|
||||
var ALPHA_OFF = 0.7;
|
||||
var COLOR_TOOL_BAR = { red: 0, green: 0, blue: 0 };
|
||||
|
|
|
@ -9,7 +9,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
function getRandomFloat(min, max) {
|
||||
return Math.random() * (max - min) + min;
|
||||
|
|
|
@ -28,10 +28,10 @@
|
|||
lightTimer = 0,
|
||||
lightTimeoutID = undefined,
|
||||
audioInjector = null;
|
||||
|
||||
var HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
var cannonSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "philip/cannonShot.wav");
|
||||
var explosionSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "philip/explosion.wav");
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
var cannonSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "philip/cannonShot.wav");
|
||||
var explosionSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "philip/explosion.wav");
|
||||
|
||||
var NO_SHOOT_COLOR = { red: 100, green: 100, blue: 100 };
|
||||
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var panelWall = false;
|
||||
var orbShell = false;
|
||||
|
@ -47,16 +48,16 @@ var panelsCenterShift = Vec3.subtract(panelsCenter, orbCenter);
|
|||
|
||||
var ORB_SHIFT = { x: 0, y: -1.4, z: -0.8 };
|
||||
|
||||
var LOBBY_PANEL_WALL_URL = HIFI_PUBLIC_BUCKET + "models/sets/Lobby/PanelWallForInterface.fbx";
|
||||
var LOBBY_BLANK_PANEL_TEXTURE_URL = HIFI_PUBLIC_BUCKET + "models/sets/Lobby/Texture.jpg";
|
||||
var LOBBY_SHELL_URL = HIFI_PUBLIC_BUCKET + "models/sets/Lobby/LobbyShellForInterface.fbx";
|
||||
var LOBBY_PANEL_WALL_URL = VIRCADIA_PUBLIC_CDN + "models/sets/Lobby/PanelWallForInterface.fbx";
|
||||
var LOBBY_BLANK_PANEL_TEXTURE_URL = VIRCADIA_PUBLIC_CDN + "models/sets/Lobby/Texture.jpg";
|
||||
var LOBBY_SHELL_URL = VIRCADIA_PUBLIC_CDN + "models/sets/Lobby/LobbyShellForInterface.fbx";
|
||||
|
||||
var droneSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Lobby/drone.stereo.raw")
|
||||
var droneSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Lobby/drone.stereo.raw")
|
||||
var currentDrone = null;
|
||||
|
||||
var latinSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Lobby/latin.stereo.raw")
|
||||
var latinSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Lobby/latin.stereo.raw")
|
||||
var latinInjector = null;
|
||||
var elevatorSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Lobby/elevator.stereo.raw")
|
||||
var elevatorSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Lobby/elevator.stereo.raw")
|
||||
var elevatorInjector = null;
|
||||
var currentMuzakInjector = null;
|
||||
var currentSound = null;
|
||||
|
|
|
@ -19,7 +19,8 @@ var floorTiles = [];
|
|||
var blocks = [];
|
||||
var blockSpawner;
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
|
||||
var floorPos = Vec3.sum(MyAvatar.position, {
|
||||
|
@ -61,7 +62,7 @@ var offButton = Overlays.addOverlay("image", {
|
|||
y: screenSize.y - (BUTTON_SIZE + PADDING),
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/close.png",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/close.png",
|
||||
color: {
|
||||
red: 255,
|
||||
green: 255,
|
||||
|
@ -75,7 +76,7 @@ var deleteButton = Overlays.addOverlay("image", {
|
|||
y: screenSize.y - (BUTTON_SIZE + PADDING),
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/delete.png",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/delete.png",
|
||||
color: {
|
||||
red: 255,
|
||||
green: 255,
|
||||
|
|
|
@ -16,11 +16,11 @@ Script.include([
|
|||
"libraries/overlayManager.js",
|
||||
]);
|
||||
|
||||
var BG_IMAGE_URL = HIFI_PUBLIC_BUCKET + "images/card-bg.svg";
|
||||
var CLOSE_IMAGE_URL = HIFI_PUBLIC_BUCKET + "images/tools/close.svg";
|
||||
var MIC_IMAGE_URL = HIFI_PUBLIC_BUCKET + "images/tools/mic-toggle.svg";
|
||||
var FACE_IMAGE_URL = HIFI_PUBLIC_BUCKET + "images/tools/face-toggle.svg";
|
||||
var ADDRESS_BAR_IMAGE_URL = HIFI_PUBLIC_BUCKET + "images/tools/address-bar-toggle.svg";
|
||||
var BG_IMAGE_URL = VIRCADIA_PUBLIC_CDN + "images/card-bg.svg";
|
||||
var CLOSE_IMAGE_URL = VIRCADIA_PUBLIC_CDN + "images/tools/close.svg";
|
||||
var MIC_IMAGE_URL = VIRCADIA_PUBLIC_CDN + "images/tools/mic-toggle.svg";
|
||||
var FACE_IMAGE_URL = VIRCADIA_PUBLIC_CDN + "images/tools/face-toggle.svg";
|
||||
var ADDRESS_BAR_IMAGE_URL = VIRCADIA_PUBLIC_CDN + "images/tools/address-bar-toggle.svg";
|
||||
|
||||
var panel = new OverlayPanel({
|
||||
anchorPositionBinding: { avatar: "MyAvatar" },
|
||||
|
|
|
@ -10,7 +10,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
function length(v) {
|
||||
return Math.sqrt(v.x * v.x + v.y * v.y + v.z * v.z);
|
||||
|
@ -28,7 +29,7 @@ function vMinus(a, b) {
|
|||
}
|
||||
|
||||
// The model file to be used for the guitar
|
||||
var guitarModel = HIFI_PUBLIC_BUCKET + "models/attachments/guitar.fst";
|
||||
var guitarModel = VIRCADIA_PUBLIC_CDN + "models/attachments/guitar.fst";
|
||||
|
||||
// Load sounds that will be played
|
||||
|
||||
|
@ -36,22 +37,22 @@ var heyManWave = SoundCache.getSound("https://hifi-public.s3.amazonaws.com/sound
|
|||
|
||||
var chords = new Array();
|
||||
// Nylon string guitar
|
||||
chords[1] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Nylon+A.raw");
|
||||
chords[2] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Nylon+B.raw");
|
||||
chords[3] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Nylon+E.raw");
|
||||
chords[4] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Nylon+G.raw");
|
||||
chords[1] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Nylon+A.raw");
|
||||
chords[2] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Nylon+B.raw");
|
||||
chords[3] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Nylon+E.raw");
|
||||
chords[4] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Nylon+G.raw");
|
||||
|
||||
// Electric guitar
|
||||
chords[5] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Metal+A+short.raw");
|
||||
chords[6] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Metal+B+short.raw");
|
||||
chords[7] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Metal+E+short.raw");
|
||||
chords[8] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Metal+G+short.raw");
|
||||
chords[5] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Metal+A+short.raw");
|
||||
chords[6] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Metal+B+short.raw");
|
||||
chords[7] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Metal+E+short.raw");
|
||||
chords[8] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Metal+G+short.raw");
|
||||
|
||||
// Steel Guitar
|
||||
chords[9] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Steel+A.raw");
|
||||
chords[10] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Steel+B.raw");
|
||||
chords[11] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Steel+E.raw");
|
||||
chords[12] = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guitars/Guitar+-+Steel+G.raw");
|
||||
chords[9] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Steel+A.raw");
|
||||
chords[10] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Steel+B.raw");
|
||||
chords[11] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Steel+E.raw");
|
||||
chords[12] = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guitars/Guitar+-+Steel+G.raw");
|
||||
|
||||
var NUM_CHORDS = 4;
|
||||
var NUM_GUITARS = 3;
|
||||
|
|
|
@ -10,7 +10,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
function length(v) {
|
||||
return Math.sqrt(v.x * v.x + v.y * v.y + v.z * v.z);
|
||||
|
@ -28,8 +29,8 @@ function vMinus(a, b) {
|
|||
|
||||
// First, load two percussion sounds to be used on the sticks
|
||||
|
||||
var drum1 = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Drums/RackTomHi.raw");
|
||||
var drum2 = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Drums/RackTomLo.raw");
|
||||
var drum1 = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Drums/RackTomHi.raw");
|
||||
var drum2 = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Drums/RackTomLo.raw");
|
||||
|
||||
// State Machine:
|
||||
// 0 = not triggered
|
||||
|
|
|
@ -15,7 +15,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
Script.include("../../libraries/toolBars.js");
|
||||
|
||||
const LEFT_PALM = 0;
|
||||
|
@ -171,7 +172,7 @@ var currentMouseControl = false;
|
|||
|
||||
var newSound = SoundCache.getSound("https://dl.dropboxusercontent.com/u/1864924/hifi-sounds/throw.raw");
|
||||
var catchSound = SoundCache.getSound("https://dl.dropboxusercontent.com/u/1864924/hifi-sounds/catch.raw");
|
||||
var throwSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Switches%20and%20sliders/slider%20-%20whoosh1.raw");
|
||||
var throwSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Switches%20and%20sliders/slider%20-%20whoosh1.raw");
|
||||
|
||||
var simulatedFrisbees = [];
|
||||
|
||||
|
|
|
@ -22,7 +22,8 @@ Script.include("../../libraries/utils.js");
|
|||
Script.include("../../libraries/constants.js");
|
||||
Script.include("../../libraries/toolBars.js");
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var LASER_WIDTH = 2;
|
||||
var POSE_CONTROLS = [ Controller.Standard.LeftHand, Controller.Standard.RightHand ];
|
||||
|
@ -30,7 +31,7 @@ var TRIGGER_CONTROLS = [ Controller.Standard.LT, Controller.Standard.RT ];
|
|||
var MIN_THROWER_DELAY = 1000;
|
||||
var MAX_THROWER_DELAY = 1000;
|
||||
var RELOAD_INTERVAL = 5;
|
||||
var GUN_MODEL = HIFI_PUBLIC_BUCKET + "cozza13/gun/m1911-handgun+1.fbx?v=4";
|
||||
var GUN_MODEL = VIRCADIA_PUBLIC_CDN + "cozza13/gun/m1911-handgun+1.fbx?v=4";
|
||||
var BULLET_VELOCITY = 10.0;
|
||||
var GUN_OFFSETS = [ {
|
||||
x: -0.04,
|
||||
|
@ -84,11 +85,11 @@ function getRandomFloat(min, max) {
|
|||
|
||||
var showScore = false;
|
||||
// Load some sound to use for loading and firing
|
||||
var fireSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guns/GUN-SHOT2.raw");
|
||||
var loadSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guns/Gun_Reload_Weapon22.raw");
|
||||
var impactSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Guns/BulletImpact2.raw");
|
||||
var targetHitSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Space%20Invaders/hit.raw");
|
||||
var targetLaunchSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Space%20Invaders/shoot.raw");
|
||||
var fireSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guns/GUN-SHOT2.raw");
|
||||
var loadSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guns/Gun_Reload_Weapon22.raw");
|
||||
var impactSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Guns/BulletImpact2.raw");
|
||||
var targetHitSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Space%20Invaders/hit.raw");
|
||||
var targetLaunchSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Space%20Invaders/shoot.raw");
|
||||
|
||||
var audioOptions = {
|
||||
volume: 0.9
|
||||
|
@ -118,7 +119,7 @@ var toolBar = new ToolBar(0, 0, ToolBar.HORIZONTAL, "highfidelity.gun.toolbar",
|
|||
var offButton = toolBar.addOverlay("image", {
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/gun/close.svg",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/gun/close.svg",
|
||||
alpha: 1
|
||||
});
|
||||
|
||||
|
@ -128,7 +129,7 @@ var platformButton = toolBar.addOverlay("image", {
|
|||
y: screenSize.y - (BUTTON_SIZE + PADDING),
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/gun/platform-targets.svg",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/gun/platform-targets.svg",
|
||||
alpha: 1
|
||||
});
|
||||
|
||||
|
@ -138,7 +139,7 @@ var gridButton = toolBar.addOverlay("image", {
|
|||
y: screenSize.y - (BUTTON_SIZE + PADDING),
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/gun/floating-targets.svg",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/gun/floating-targets.svg",
|
||||
alpha: 1
|
||||
});
|
||||
|
||||
|
|
|
@ -10,11 +10,12 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
hitSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Collisions-ballhitsandcatches/billiards/collision1.wav");
|
||||
var rightHandAnimation = HIFI_PUBLIC_BUCKET + "animations/RightHandAnimPhilip.fbx";
|
||||
var leftHandAnimation = HIFI_PUBLIC_BUCKET + "animations/LeftHandAnimPhilip.fbx";
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
hitSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Collisions-ballhitsandcatches/billiards/collision1.wav");
|
||||
var rightHandAnimation = VIRCADIA_PUBLIC_CDN + "animations/RightHandAnimPhilip.fbx";
|
||||
var leftHandAnimation = VIRCADIA_PUBLIC_CDN + "animations/LeftHandAnimPhilip.fbx";
|
||||
|
||||
var BALL_SIZE = 0.08;
|
||||
var PADDLE_SIZE = 0.20;
|
||||
|
@ -43,7 +44,7 @@ var offButton = Overlays.addOverlay("image", {
|
|||
y: 96,
|
||||
width: 32,
|
||||
height: 32,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/close.png",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/close.png",
|
||||
color: { red: 255, green: 255, blue: 255},
|
||||
alpha: 1
|
||||
});
|
||||
|
|
|
@ -15,7 +15,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
// maybe we should make these constants...
|
||||
var LEFT_PALM = 0;
|
||||
|
@ -40,7 +41,7 @@ var rightHandEntity = false;
|
|||
|
||||
var newSound = SoundCache.getSound("https://dl.dropboxusercontent.com/u/1864924/hifi-sounds/throw.raw");
|
||||
var catchSound = SoundCache.getSound("https://dl.dropboxusercontent.com/u/1864924/hifi-sounds/catch.raw");
|
||||
var throwSound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Switches%20and%20sliders/slider%20-%20whoosh1.raw");
|
||||
var throwSound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Switches%20and%20sliders/slider%20-%20whoosh1.raw");
|
||||
var targetRadius = 0.25;
|
||||
|
||||
|
||||
|
|
|
@ -72,7 +72,7 @@ function Instructions(imageURL, originalWidth, originalHeight) {
|
|||
this.rescale();
|
||||
};
|
||||
|
||||
var theInstruction = new Instructions(HIFI_PUBLIC_BUCKET + "images/tutorial-goTo.svg", 457, 284.1);
|
||||
var theInstruction = new Instructions(VIRCADIA_PUBLIC_CDN + "images/tutorial-goTo.svg", 457, 284.1);
|
||||
|
||||
var firstControllerPlugged = false;
|
||||
|
||||
|
@ -86,7 +86,7 @@ var locationURL = "";
|
|||
var randomSounds = new SoundArray({}, true);
|
||||
var numberOfSounds = 7;
|
||||
for (var i = 1; i <= numberOfSounds; i++) {
|
||||
randomSounds.addSound(HIFI_PUBLIC_BUCKET + "sounds/UI/virtualKeyboard-press" + i + ".raw");
|
||||
randomSounds.addSound(VIRCADIA_PUBLIC_CDN + "sounds/UI/virtualKeyboard-press" + i + ".raw");
|
||||
}
|
||||
|
||||
function appendChar(char) {
|
||||
|
|
|
@ -38,7 +38,7 @@ var textSizeMeasureOverlay = Overlays.addOverlay("text3d", {visible: false});
|
|||
var randomSounds = new SoundArray({}, true);
|
||||
var numberOfSounds = 7;
|
||||
for (var i = 1; i <= numberOfSounds; i++) {
|
||||
randomSounds.addSound(HIFI_PUBLIC_BUCKET + "sounds/UI/virtualKeyboard-press" + i + ".raw");
|
||||
randomSounds.addSound(VIRCADIA_PUBLIC_CDN + "sounds/UI/virtualKeyboard-press" + i + ".raw");
|
||||
}
|
||||
|
||||
function appendChar(char) {
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
//
|
||||
Script.include("http://s3.amazonaws.com/hifi-public/scripts/libraries/toolBars.js");
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
|
||||
|
||||
|
@ -139,7 +140,7 @@ function createTable() {
|
|||
dimensions: TABLE_DIMENSIONS,
|
||||
rotation: MyAvatar.orientation,
|
||||
// color: { red: 102, green: 51, blue: 0 },
|
||||
modelURL: HIFI_PUBLIC_BUCKET + 'eric/models/woodFloor.fbx',
|
||||
modelURL: VIRCADIA_PUBLIC_CDN + 'eric/models/woodFloor.fbx',
|
||||
collisionSoundURL: "http://public.highfidelity.io/sounds/dice/diceCollide.wav"
|
||||
});
|
||||
|
||||
|
|
|
@ -10,15 +10,16 @@
|
|||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
Script.include(HIFI_PUBLIC_BUCKET + "scripts/libraries/toolBars.js");
|
||||
Script.include(HIFI_PUBLIC_BUCKET + "scripts/libraries/utils.js");
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
Script.include(VIRCADIA_PUBLIC_CDN + "scripts/libraries/toolBars.js");
|
||||
Script.include(VIRCADIA_PUBLIC_CDN + "scripts/libraries/utils.js");
|
||||
|
||||
var rotation = Quat.safeEulerAngles(Camera.getOrientation());
|
||||
rotation = Quat.fromPitchYawRollDegrees(0, rotation.y, 0);
|
||||
var center = Vec3.sum(MyAvatar.position, Vec3.multiply(1, Quat.getFront(rotation)));
|
||||
|
||||
var TOOL_ICON_URL = HIFI_PUBLIC_BUCKET + "images/tools/";
|
||||
var TOOL_ICON_URL = VIRCADIA_PUBLIC_CDN + "images/tools/";
|
||||
var ALPHA_ON = 1.0;
|
||||
var ALPHA_OFF = 0.7;
|
||||
var COLOR_TOOL_BAR = { red: 0, green: 0, blue: 0 };
|
||||
|
|
|
@ -13,9 +13,10 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var sound = SoundCache.getSound(HIFI_PUBLIC_BUCKET + "sounds/Animals/mexicanWhipoorwill.raw");
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var sound = SoundCache.getSound(VIRCADIA_PUBLIC_CDN + "sounds/Animals/mexicanWhipoorwill.raw");
|
||||
var CHANCE_OF_PLAYING_SOUND = 0.01;
|
||||
|
||||
var FACTOR = 0.05;
|
||||
|
|
|
@ -14,12 +14,13 @@
|
|||
|
||||
|
||||
// Declare HiFi public bucket.
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
// Declare variables and set up new WebWindow.
|
||||
var stream;
|
||||
var volume = 1;
|
||||
var streamWindow = new WebWindow('Stream', HIFI_PUBLIC_BUCKET + "examples/html/jsstreamplayer.html", 0, 0, false);
|
||||
var streamWindow = new WebWindow('Stream', VIRCADIA_PUBLIC_CDN + "examples/html/jsstreamplayer.html", 0, 0, false);
|
||||
|
||||
// Set up toggleStreamURLButton overlay.
|
||||
var toggleStreamURLButton = Overlays.addOverlay("text", {
|
||||
|
|
|
@ -9,10 +9,11 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var modelURL = HIFI_PUBLIC_BUCKET + "models/entities/radio/Speakers.fbx";
|
||||
var soundURL = HIFI_PUBLIC_BUCKET + "sounds/family.stereo.raw";
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var modelURL = VIRCADIA_PUBLIC_CDN + "models/entities/radio/Speakers.fbx";
|
||||
var soundURL = VIRCADIA_PUBLIC_CDN + "sounds/family.stereo.raw";
|
||||
|
||||
var AudioRotationOffset = Quat.fromPitchYawRollDegrees(0, -90, 0);
|
||||
var audioOptions = {
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
var HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
var SOUND_PATH = HIFI_PUBLIC_BUCKET + "sounds/Collisions-hitsandslaps/";
|
||||
var
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
var SOUND_PATH = VIRCADIA_PUBLIC_CDN + "sounds/Collisions-hitsandslaps/";
|
||||
var soundURLS = ["67LCollision01.wav", "67LCollision02.wav", "airhockey_hit1.wav"];
|
||||
var FLOOR_SIZE = 10;
|
||||
var center = Vec3.sum(MyAvatar.position, Vec3.multiply(FLOOR_SIZE * 1.5, Quat.getFront(Camera.getOrientation())));
|
||||
|
@ -43,7 +44,7 @@ var brownianButton = Overlays.addOverlay("image", {
|
|||
y: screenSize.y - (BUTTON_SIZE + PADDING),
|
||||
width: BUTTON_SIZE,
|
||||
height: BUTTON_SIZE,
|
||||
imageURL: HIFI_PUBLIC_BUCKET + "images/blocks.png",
|
||||
imageURL: VIRCADIA_PUBLIC_CDN + "images/blocks.png",
|
||||
color: buttonOffColor,
|
||||
alpha: 1
|
||||
});
|
||||
|
|
|
@ -10,8 +10,9 @@
|
|||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
Script.include(HIFI_PUBLIC_BUCKET + 'scripts/utilities.js')
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
Script.include(VIRCADIA_PUBLIC_CDN + 'scripts/utilities.js')
|
||||
|
||||
var NUM_ROWS = 10;
|
||||
var CUBE_SIZE = 1;
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var count = 0;
|
||||
var moveUntil = 2000;
|
||||
|
@ -37,7 +38,7 @@ type: "Model",
|
|||
green: 255,
|
||||
blue: 0 },
|
||||
|
||||
modelURL: HIFI_PUBLIC_BUCKET + "meshes/Feisar_Ship.FBX",
|
||||
modelURL: VIRCADIA_PUBLIC_CDN + "meshes/Feisar_Ship.FBX",
|
||||
|
||||
|
||||
rotation: rotation
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
HIFI_PUBLIC_BUCKET = "http://s3.amazonaws.com/hifi-public/";
|
||||
|
||||
var VIRCADIA_PUBLIC_CDN = networkingConstants.PUBLIC_BUCKET_CDN_URL;
|
||||
|
||||
var count = 0;
|
||||
var stopAfter = 1000;
|
||||
|
@ -26,7 +27,7 @@ var modelPropertiesA = {
|
|||
y: 3.34,
|
||||
z: 0.54
|
||||
},
|
||||
modelURL: HIFI_PUBLIC_BUCKET + "meshes/Feisar_Ship.FBX",
|
||||
modelURL: VIRCADIA_PUBLIC_CDN + "meshes/Feisar_Ship.FBX",
|
||||
lifetime: 20
|
||||
};
|
||||
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue