Needle Engine
  • README
  • Code Of Conduct
  • HOW TO
  • documentation
    • SUMMARY
    • _backlog-mermaid
    • _backlog
    • _meta-test
    • Automatic Component Generation
    • Needle Core Components
    • How To Debug
    • Deployment and Optimization
    • embedding
    • Everywhere Actions
    • Example Projects ✨
    • Exporting Assets, Animations, Prefabs, Materials, Lightmaps...
    • Questions and Answers (FAQ) 💡
    • Feature Overview
    • This page has been moved: continue here
    • getting-started
    • Frameworks, Bundlers, HTML
    • index
    • Additional Modules
    • Networking
    • Needle Engine Project Structure
    • Samples Projects
    • Scripting Examples
    • Creating and using Components
    • Live
    • Live
    • About
    • Live
    • Live
    • Live
    • Live
    • Support, Community & AI
    • Technical Overview
    • Testimonials
    • Testing on local devices
    • Using Needle Engine directly from HTML
    • vision
    • VR & AR (WebXR)
    • blender
      • Needle Engine for Blender
    • cloud
      • Needle Cloud
    • custom-integrations
      • index
    • getting-started
      • Scripting Introduction for Unity Developers
      • Getting Started & Installation
      • Scripting in Needle Engine
    • reference
      • needle.config.json
      • <needle-engine> Configuration
      • @serializable and other decorators
    • three
      • index
    • unity
      • Editor Sync
      • Needle Engine for Unity
    • lang
      • de
        • 404
        • SUMMARY
        • Automatische Komponenten-Generierung
        • Needle-Kernkomponenten
        • Debugging
        • Bereitstellung und Optimierung
        • embedding
        • Everywhere Actions
        • Beispielprojekte ✨
        • Assets, Animationen, Prefabs, Materialien, Lightmaps exportieren...
        • Fragen und Antworten (FAQ) 💡
        • Funktionsübersicht
        • Diese Seite wurde verschoben: hier fortfahren
        • getting-started
        • Frameworks, Bundler, HTML
        • index
        • Zusätzliche Module
        • Netzwerkfunktionen
        • Needle Engine Projektstruktur
        • Beispielprojekte
        • Scripting Beispiele
        • Erstellen und Verwenden von Komponenten
        • Live
        • Live
        • Über
        • Live
        • Live
        • Live
        • Live
        • Support und Community
        • Technischer Überblick
        • Erfahrungsberichte
        • Testen auf lokalen Geräten
        • Needle Engine direkt aus HTML verwenden
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine für Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Einführung in das Scripting für Unity-Entwickler
          • Erste Schritte & Installation
          • Scripting in Needle Engine
        • reference
          • needle.config.json
          • <needle-engine> Konfiguration
          • @serializable und andere Decorators
        • three
          • index
        • unity
          • Editor Synchronisierung
          • Needle Engine für Unity
      • es
        • SUMMARY
        • Generación Automática de Componentes
        • Componentes principales de Needle
        • Cómo Depurar
        • Despliegue y optimización
        • embedding
        • Acciones Everywhere
        • Proyectos de Ejemplo ✨
        • Exportación de Assets, Animaciones, Prefabs, Materiales, Lightmaps...
        • Preguntas Frecuentes (FAQ) 💡
        • Resumen de Características
        • Esta página ha sido movida: continúe aquí
        • getting-started
        • Frameworks, Bundlers, HTML
        • index
        • Módulos Adicionales
        • Redes
        • Estructura de Proyecto de Needle Engine
        • Proyectos de ejemplo
        • Ejemplos de scripting
        • Crear y usar Components
        • En vivo
        • En Vivo
        • Acerca de
        • En vivo
        • En vivo
        • En vivo
        • En vivo
        • Soporte y Comunidad
        • Resumen técnico
        • Testimonios
        • Testing on local devices
        • Usando Needle Engine directamente desde HTML
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine para Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Introducción al Scripting para Desarrolladores de Unity
          • Primeros pasos e instalación
          • Scripting in Needle Engine
        • reference
          • needle.config.json
          • Configuración de <needle-engine>
          • @serializable y otros decoradores
        • three
          • index
        • unity
          • Editor Sync
          • Needle Engine para Unity
      • fr
        • SUMMARY
        • Génération automatique de composants
        • Composants principaux de Needle
        • Comment déboguer
        • Déploiement et Optimisation
        • embedding
        • Everywhere Actions
        • Exemples de Projets ✨
        • Exporter des Assets, des Animations, des Prefabs, des Matériaux, des Lightmaps...
        • Questions et Réponses (FAQ) 💡
        • Aperçu des fonctionnalités
        • Cette page a été déplacée : continuez ici
        • getting-started
        • Frameworks, Bundlers, HTML
        • index
        • Modules supplémentaires
        • Réseau
        • Structure du projet Needle Engine
        • Projets d'exemples
        • Exemples de Scripting
        • Créer et utiliser des Components
        • showcase-bike
        • En direct
        • À propos
        • En direct
        • Jouer
        • En direct
        • En direct
        • Support et Communauté
        • Vue d'ensemble technique
        • Témoignages
        • Tester sur les appareils locaux
        • Utiliser Needle Engine directement depuis HTML
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine pour Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Introduction au Scripting pour les Développeurs Unity
          • Premiers pas et installation
          • Scripting in Needle Engine
        • reference
          • needle.config.json
          • <needle-engine> Configuration
          • @serializable et autres décorateurs
        • three
          • index
        • unity
          • Synchronisation de l'Editor (Editor Sync)
          • Needle Engine pour Unity
      • hi
        • SUMMARY
        • कंपोनेंट का स्वतः जनरेशन
        • नीडल कोर कंपोनेंट्स
        • How To Debug
        • Deployment and Optimization
        • embedding
        • Everywhere Actions
        • उदाहरण प्रोजेक्ट ✨
        • एसेट, एनिमेशन, प्रीफैब, मटेरियल, लाइटमैप्स... को एक्सपोर्ट करना
        • प्रश्न और उत्तर (FAQ) 💡
        • सुविधा अवलोकन
        • यह पृष्ठ स्थानांतरित कर दिया गया है: यहां जारी रखें
        • getting-started
        • Frameworks, Bundlers, HTML
        • index
        • अतिरिक्त मॉड्यूल
        • नेटवर्किंग
        • Needle Engine प्रोजेक्ट स्ट्रक्चर
        • samples-and-modules
        • स्क्रिप्टिंग उदाहरण
        • कंपोनेंट बनाना और उपयोग करना
        • लाइव
        • लाइव
        • परिचय
        • लाइव
        • लाइव
        • लाइव
        • लाइव
        • समर्थन और समुदाय
        • तकनीकी अवलोकन
        • प्रशंसापत्र
        • Testing on local devices
        • HTML से सीधे Needle Engine का उपयोग करना
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine for Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Unity डेवलपर्स के लिए स्क्रिप्टिंग परिचय
          • आरंभ करना और इंस्टॉलेशन
          • Needle Engine में स्क्रिप्टिंग
        • reference
          • needle.config.json
          • <needle-engine> कॉन्फ़िगरेशन
          • @serializable and other decorators
        • three
          • index
        • unity
          • Editor Sync
          • Unity के लिए Needle Engine
      • ja
        • SUMMARY
        • 自動コンポーネント生成
        • Needleコアコンポーネント
        • デバッグの方法
        • デプロイと最適化
        • embedding
        • Everywhere Actions
        • サンプルプロジェクト ✨
        • アセット、アニメーション、Prefab、マテリアル、ライトマップなどのエクスポート
        • よくある質問(FAQ)💡
        • 機能概要
        • このページは移動しました: こちらからどうぞ
        • getting-started
        • フレームワーク、バンドラー、HTML
        • index
        • 追加モジュール
        • ネットワーキング
        • Needle Engineプロジェクトの構造
        • サンプルプロジェクト
        • スクリプティング例
        • Creating and using Components
        • ライブ
        • showcase-castle
        • 概要
        • ライブ
        • ライブ
        • ライブ
        • ライブ
        • サポートとコミュニティ
        • 技術概要
        • お客様の声
        • ローカルデバイスでのテスト
        • HTMLからNeedle Engineを直接使用する
        • vision
        • VR & AR (WebXR)
        • blender
          • Blender 用 Needle Engine
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Scripting Introduction for Unity Developers
          • はじめに & インストール
          • Needle Engineでのスクリプティング
        • reference
          • needle.config.json
          • <needle-engine> 設定
          • @serializable およびその他のデコレーター
        • three
          • index
        • unity
          • Editor Sync
          • Unity用Needle Engine
      • pt
        • SUMMARY
        • Automatic Component Generation
        • Componentes Principais do Needle
        • Como Depurar
        • Implementação e Otimização
        • embedding
        • Everywhere Actions
        • Projetos de Exemplo ✨
        • Exportar Recursos, Animações, Prefabs, Materiais, Lightmaps...
        • Perguntas e Respostas (FAQ) 💡
        • Visão Geral dos Recursos
        • Esta página foi movida: continue aqui
        • getting-started
        • Frameworks, Bundlers, HTML
        • index
        • Módulos Adicionais
        • Redes
        • Estrutura do Projeto Needle Engine
        • Projetos de Exemplo
        • Exemplos de Scripting
        • Criar e usar Componentes
        • Ao Vivo
        • Ao Vivo
        • Sobre
        • Ao Vivo
        • Ao Vivo
        • Ao Vivo
        • Ao Vivo
        • Suporte e Comunidade
        • Visão Geral Técnica
        • Depoimentos
        • Testar em dispositivos locais
        • vanilla-js
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine para Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Introdução à Scripting para Developers Unity
          • Começar e Instalação
          • Scripting no Needle Engine
        • reference
          • needle.config.json
          • needle-engine-attributes
          • @serializable e outros decorators
        • three
          • index
        • unity
          • Sincronização do Editor
          • Needle Engine para Unity
      • vn
        • 404
        • SUMMARY
        • Automatic Component Generation
        • Các Component Cốt lõi của Needle
        • Cách gỡ lỗi
        • Triển khai và Tối ưu hóa
        • embedding
        • Hành động ở mọi nơi (Everywhere Actions)
        • Các Dự Án Ví Dụ ✨
        • Xuất Tài sản, Hoạt ảnh, Prefab, Vật liệu, Lightmap...
        • Câu hỏi thường gặp (FAQ) 💡
        • Tổng quan tính năng
        • Trang này đã được di chuyển: tiếp tục tại đây
        • getting-started
        • Frameworks, Bundlers, HTML
        • index
        • Các Module Bổ Sung
        • Kết nối mạng
        • Cấu trúc dự án Needle Engine
        • samples-and-modules
        • Ví dụ về Scripting
        • Tạo và sử dụng Component
        • Trực tiếp
        • Trực tiếp
        • Giới thiệu
        • Trực tiếp
        • Chơi thử
        • Trực tiếp
        • Demo trực tiếp
        • Hỗ trợ và Cộng đồng
        • Tổng quan kỹ thuật
        • Lời chứng thực
        • Testing on local devices
        • Sử dụng Needle Engine trực tiếp từ HTML
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine cho Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Giới thiệu về Scripting cho các nhà phát triển Unity
          • Getting Started & Installation
          • Scripting trong Needle Engine
        • reference
          • needle.config.json
          • Cấu hình <needle-engine>
          • @serializable và các decorator khác
        • three
          • index
        • unity
          • Editor Sync
          • Needle Engine cho Unity
      • zh
        • SUMMARY
        • 自动生成组件
        • Needle 核心组件
        • 如何调试
        • 部署与优化
        • embedding
        • Everywhere Actions
        • 示例项目 ✨
        • 导出资源、动画、预制体、材质、光照贴图...
        • 常见问题 (FAQ) 💡
        • 功能概览
        • 此页面已移动:请在此处继续
        • getting-started
        • 框架、打包器、HTML
        • index
        • 附加模块
        • 网络
        • Needle Engine 项目结构
        • 示例项目
        • Scripting Examples
        • Creating and using Components
        • 实时示例
        • 实时
        • 关于
        • 实时演示
        • 在线试玩
        • 实时演示
        • 现场演示
        • 支持与社区
        • 技术概述
        • 用户评价
        • Testing on local devices
        • 使用 Needle Engine 直接从 HTML
        • vision
        • VR & AR (WebXR)
        • blender
          • Needle Engine for Blender
        • cloud
          • Needle Cloud
        • custom-integrations
          • index
        • getting-started
          • Scripting Introduction for Unity Developers
          • 入门与安装
          • 在 Needle Engine 中编写脚本
        • reference
          • needle.config.json
          • <needle-engine> 配置
          • @serializable and other decorators
        • three
          • index
        • unity
          • 编辑器同步
          • Unity 版 Needle Engine
Powered by GitBook
On this page
  • Ngữ cảnh
  • Ánh sáng
  • Phông nền
  • Chuyển động giả của xe
  • Các yếu tố bổ sung
  • Kết thúc
  • Kết luận
Edit on GitHub
  1. documentation
  2. lang
  3. vn

Giới thiệu

PreviousTrực tiếpNextTrực tiếp

Last updated 26 days ago

Xin chào, tên tôi là Kryštof và tôi đã thực hiện một dự án nghiên cứu về Needle. Tại , chúng tôi muốn xác định xem Needle có thể giúp ích cho quy trình làm việc của chúng tôi như thế nào. Chúng tôi có một khách hàng địa phương chuyên bán lại xe hơi hạng sang. Chúng tôi đã bàn giao một ứng dụng di động và trải nghiệm VR sử dụng Unity. Chúng tôi có khoảng 30 chiếc xe độc đáo đã sẵn sàng trong engine. Chúng tôi có kế hoạch mở rộng trang web của khách hàng với các bản sao kỹ thuật số đẹp mắt có nhiều tùy chọn cấu hình hơn. Needle có thể đạt được chuyển đổi hoàn hảo 1:1 giữa hình ảnh trong Unity và web. Điều này sẽ là một lợi ích lớn cho quy trình làm việc của chúng tôi. Đó là điều đã khơi nguồn cho nghiên cứu của chúng tôi.

Ngữ cảnh

Tôi không có nhiều kinh nghiệm với javascript, typescript hoặc three.js, vì vậy quan điểm của tôi là một nhà phát triển Unity bán chuyên đang thử cách đơn giản nhất để tạo trải nghiệm web. Đối với những người đề xuất Unity WebGL, thật đáng tiếc là nó không hoạt động và không linh hoạt trên các trình duyệt di động. Needle thật tuyệt 💚

Ánh sáng

Mô hình chiếu sáng của chúng tôi dựa trên reflection probes trong Unity. Chúng tôi không cần bất kỳ directional hoặc point lights nào, chỉ cần ambient lighting.

Chúng tôi đang sử dụng skybox này:

Skybox

Trông giống thế này trên lớp sơn xe:

Sau đó, để thêm một chút chi tiết nhỏ, tôi đã thêm 2 directional lights với cường độ không đáng kể (0.04) để tạo specular highlights. Vì vậy, trước đây trông như thế này:

Nhưng với việc thêm directional lights đã tạo thêm sự sống động tốt hơn. Hiệu ứng có thể được làm sâu sắc hơn với cường độ cao hơn:

Phông nền

Cảnh hiện tại trông như thế này:

Phông nền đen không được đẹp lắm. Vì vậy, để phân biệt giữa skybox hình ảnh và skybox chiếu sáng, tôi đã thêm một inverse sphere bao phủ toàn bộ bản đồ.

Về gradient thì chuyển từ màu xám nhạt sang màu trắng..

Hiệu ứng này có thể dễ dàng tạo ra chỉ với UV mapping phù hợp và một texture cao một pixel để định nghĩa gradient.

Tôi đã tạo một unlit shader trong shader graph:

Tôi nhận thấy một vấn đề color banding, vì vậy tôi đã cố gắng triển khai dithering. Thành thật mà nói, nó không giúp ích cho artefacts nhưng tôi cá rằng có một giải pháp đơn giản cho vấn đề đó. Vì vậy, phần trên của shader lấy mẫu gradient dựa trên trục Y trong object space. Và phần dưới cố gắng triệt tiêu color banding.

Bằng cách sử dụng shaders, việc sử dụng và lặp lại gradient trở nên đơn giản hơn. Bằng cách sử dụng Shadergraph markdown asset của Needle, nó còn đơn giản hơn nữa! 🌵

Chuyển động giả của xe

Cảnh hiện tại là tĩnh vì không có gì di chuyển. Chúng ta có thể khắc phục điều đó bằng cách thêm cảm giác chuyển động giả. Hãy bắt đầu bằng cách thêm chuyển động cho bánh xe.

Với một component đơn giản gọi là Rotator, chúng tôi định nghĩa một trục và tốc độ theo trục đó.

import { Behaviour, serializable } from "@needle-tools/engine";

export enum RotationAxis {
    X, Y, Z
}

export class Rotator extends Behaviour {
    //@type RotationAxis
    @serializable()
    axis : RotationAxis = RotationAxis.X;

    @serializable()
    speed : number = 1;

    update() {
        const angle = this.speed * this.context.time.deltaTime;
        switch(this.axis) {
            case RotationAxis.X:
                this.gameObject.rotateX(angle);
                break;
            case RotationAxis.Y:
                this.gameObject.rotateY(angle);
                break;
            case RotationAxis.Z:
                this.gameObject.rotateZ(angle);
                break;
        }
    }
}

Người dùng giờ đây thấy một chiếc xe đang chạy trong hư vô sâu thẳm, màu sắc không giống bất cứ thứ gì và trải nghiệm thật nhàm chán. Chúng tôi muốn tạo nền cho mô hình và điều đó được thực hiện bằng cách thêm một grid và sau đó dịch chuyển nó để tạo cảm giác xe đang di chuyển. Đây là điều chúng tôi muốn đạt được:

Shader cho grid bao gồm hai phần. Một tiled texture đơn giản của grid được nhân với một circular gradient để làm mờ các cạnh.

Các yếu tố bổ sung

Bản demo công nghệ này có mục đích là giới thiệu các khả năng của chiếc xe.

Hãy bắt đầu bằng cách làm nổi bật bánh xe.

Thêm shader này vào một plane sẽ tạo ra một vòng tròn nét đứt xoay theo tốc độ đã định. Kết hợp với world space UI sử dụng một Text component thông thường, điều này có thể làm nổi bật một số khả năng hoặc thông số thú vị của sản phẩm.

Sau khi giới thiệu bánh xe, chúng tôi muốn kết thúc bằng thông tin chung về sản phẩm. Trong trường hợp này, đó sẽ là tên đầy đủ của xe và có thể một số cấu hình có sẵn.

Kết thúc

Bằng cách sử dụng Timeline của Unity, chúng ta có thể kiểm soát thời điểm hiển thị nét đứt bánh xe và văn bản. Điều này được bổ sung bởi hoạt ảnh camera.

Kết luận

Needle Engine có vẻ là một lựa chọn rất tốt cho chúng tôi!

Có một vài tính năng mà chúng tôi còn thiếu.

Ví dụ đó là hỗ trợ đầy đủ cho Lit Shader Graphs. Nhưng không gì ngăn cản chúng tôi tạo shaders theo cách của three.js và tạo các shaders tương tự trong Unity để đội ngũ nội dung của chúng tôi tùy chỉnh materials.

Sử dụng Needle thật tuyệt vời! 🌵

Trang được dịch tự động bằng AI

Paintjob
Specular off
Specular on
No background
With background
Evironemnt shader
Gradiant
Rotator
Motion
Grid
Wheel highlight
Wheel shader
Rear UI
công ty của chúng tôi