Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by crowley91t · Sep 11, 2013 at 03:28 PM · androidtextureterrainterraintexture

Terrain Texture Android And OpenGL ES 1.x

Hi all. I m looking to solve my problem.

I m making a simple game to android and the terrain have a big problem.

The terrain texture have a big pixels and blurry.

I m using OpenGL ES 1.x Texture: Grass Hill size 512X512. I have no chance to solve this problem alone, Can you help me?

alt text

terrain.jpg (171.2 kB)
Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by cod · Sep 11, 2013 at 03:46 PM

what shader are u using? the built-in or an other? go to edit->graphic emulation and tell me the avaiable emulation(shader model 3, 2, 1, dx7)

for what I can see, it seems that your shader can't run on this machine, so it just switch to the diffuse shader using the global colormap

How many textures are u using on this terrain?

Just write a comment with all the infos and I'll find a solution :)

Comment
Add comment · Show 10 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image crowley91t · Sep 11, 2013 at 04:05 PM 0
Share

hi man. I have only two avaiable emulation OpenGL 1.x and 2.0. i have only one texture in this terrain.

what shader are u using? For this question, where can i see shader?

avatar image cod · Sep 11, 2013 at 04:33 PM 0
Share

try this simple shader

 Shader "Hidden/TerrainEngine/Splatmap/Realtime-FirstPass" {
 Properties {
     _Control ("Control (RGBA)", 2D) = "red" {}
     _Splat0 ("Layer 0 (A)", 2D) = "white" {}
     _Splat1 ("Layer 1 (B)", 2D) = "white" {}
     // used in fallback on old cards
     _$$anonymous$$ainTex ("Base$$anonymous$$ap (RGB)", 2D) = "white" {}
     _Color ("$$anonymous$$ain Color", Color) = (1,1,1,1)
 }
     
 SubShader {
     Tags {
         "SplatCount" = "4"
         "Queue" = "Geometry-100"
         "RenderType" = "Opaque"
     }
 CGPROGRA$$anonymous$$
 #pragma surface surf Lambert
 struct Input {
     fixed2 uv_Control : TEXCOORD0;
     fixed2 uv_Splat0 : TEXCOORD1;
 };
 
 sampler2D _Control;
 sampler2D _Splat0,_Splat1;
 
 void surf (Input IN, inout SurfaceOutput o) {
     fixed4 splat_control = tex2D (_Control, IN.uv_Control);
     fixed3 col;
     col  = splat_control.r * tex2D (_Splat0, IN.uv_Splat0).rgb;
     col += splat_control.g * tex2D (_Splat1, IN.uv_Splat0).rgb;
     o.Albedo = col;
     o.Alpha = 0.0;
 }
 ENDCG  
 }
 
 // Fallback to Diffuse
 Fallback "Diffuse"
 }


it should work, let me know

EDIT: I made some mistake, now it is fixed :)

avatar image crowley91t · Sep 11, 2013 at 04:47 PM 0
Share

ok. i have create this shader but, where put this? sorry for my noob answare :'(

avatar image cod · Sep 11, 2013 at 08:06 PM 0
Share

I edited the code, now is correct

It basically replaces the builtin terrain shader and should work

if it doesn't try to modify the texture tiling values

avatar image crowley91t · Sep 11, 2013 at 08:25 PM 0
Share

hi. now i have your code edited, into shader file. but if i drag and drop shader into terrain inspector this this not attach. How to replaces the terrain shader?

hi. now i have your code edited, into shader file. but if i drag and drop shader into terrain inspector this this not attach. How to replaces the terrain shader?

terrain1.jpg (73.9 kB)
Show more comments

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

17 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Texture problem android 0 Answers

Odd Ground ( terrain ) texture appearance 0 Answers

Change terrain texture colour 1 Answer

Can't find the paint / raise / lower terrain setting in unity 2018.3 1 Answer

TriPlanar Textures Not Working Properly 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges